GNSS-SDR  0.0.13
An Open Source GNSS Software Defined Receiver
observables_dump_reader.h
Go to the documentation of this file.
1 /*!
2  * \file observables_dump_reader.h
3  * \brief Helper file for unit testing
4  * \author Javier Arribas, 2017. jarribas(at)cttc.es
5  *
6  * -----------------------------------------------------------------------------
7  *
8  * Copyright (C) 2010-2020 (see AUTHORS file for a list of contributors)
9  *
10  * GNSS-SDR is a software defined Global Navigation
11  * Satellite Systems receiver
12  *
13  * This file is part of GNSS-SDR.
14  *
15  * SPDX-License-Identifier: GPL-3.0-or-later
16  *
17  * -----------------------------------------------------------------------------
18  */
19 
20 #ifndef GNSS_SDR_OBSERVABLES_DUMP_READER_H
21 #define GNSS_SDR_OBSERVABLES_DUMP_READER_H
22 
23 #include <cstdint>
24 #include <fstream>
25 #include <string>
26 #include <vector>
27 
29 {
30 public:
31  explicit Observables_Dump_Reader(int n_channels);
33  bool read_binary_obs();
34  bool restart();
35  int64_t num_epochs();
36  bool open_obs_file(std::string out_file);
37  void close_obs_file();
38 
39  // dump variables
40  std::vector<double> RX_time;
41  std::vector<double> TOW_at_current_symbol_s;
42  std::vector<double> Carrier_Doppler_hz;
43  std::vector<double> Acc_carrier_phase_hz;
44  std::vector<double> Pseudorange_m;
45  std::vector<double> PRN;
46  std::vector<double> valid;
47 
48 private:
49  int n_channels;
50  std::string d_dump_filename;
51  std::ifstream d_dump_file;
52 };
53 
54 #endif // GNSS_SDR_OBSERVABLES_DUMP_READER_H