GNSS-SDR  0.0.13
An Open Source GNSS Software Defined Receiver
tracking_dump_reader.h
Go to the documentation of this file.
1 /*!
2  * \file tracking_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_TRACKING_DUMP_READER_H
21 #define GNSS_SDR_TRACKING_DUMP_READER_H
22 
23 #include <cstdint>
24 #include <fstream>
25 #include <string>
26 #include <vector>
27 
29 {
30 public:
32  bool read_binary_obs();
33  bool restart();
34  int64_t num_epochs();
35  bool open_obs_file(std::string out_file);
36 
37  // tracking dump variables
38  // VEPLVL
39  float abs_VE;
40  float abs_E;
41  float abs_P;
42  float abs_L;
43  float abs_VL;
44  // PROMPT I and Q (to analyze navigation symbols)
45  float prompt_I;
46  float prompt_Q;
47  // PRN start sample stamp
48  uint64_t PRN_start_sample_count;
49 
50  // accumulated carrier phase
51  float acc_carrier_phase_rad;
52 
53  // carrier and code frequency
54  float carrier_doppler_hz;
55  float carrier_doppler_rate_hz_s;
56  float code_freq_chips;
57  float code_freq_rate_chips;
58 
59  // PLL commands
60  float carr_error_hz;
61  float carr_error_filt_hz;
62 
63  // DLL commands
64  float code_error_chips;
65  float code_error_filt_chips;
66 
67  // CN0 and carrier lock test
68  float CN0_SNV_dB_Hz;
69  float carrier_lock_test;
70 
71  // AUX vars (for debug purposes)
72  float aux1;
73  double aux2;
74 
75  unsigned int PRN;
76 
77 private:
78  std::string d_dump_filename;
79  std::ifstream d_dump_file;
80 };
81 
82 #endif // GNSS_SDR_TRACKING_DUMP_READER_H