GNSS-SDR  0.0.19
An Open Source GNSS Software Defined Receiver
rtklib_solver_dump_reader.h
Go to the documentation of this file.
1 /*!
2  * \file rtklib_solver_dump_reader.h
3  * \brief Helper file for unit testing
4  * \author Javier Arribas, 2017. jarribas(at)cttc.es
5  *
6  * -----------------------------------------------------------------------------
7  *
8  * GNSS-SDR is a Global Navigation Satellite System software-defined receiver.
9  * This file is part of GNSS-SDR.
10  *
11  * Copyright (C) 2010-2020 (see AUTHORS file for a list of contributors)
12  * SPDX-License-Identifier: GPL-3.0-or-later
13  *
14  * -----------------------------------------------------------------------------
15  */
16 
17 #ifndef GNSS_SDR_RTKLIB_SOLVER_DUMP_READER_H
18 #define GNSS_SDR_RTKLIB_SOLVER_DUMP_READER_H
19 
20 #include <cstdint>
21 #include <fstream>
22 #include <string>
23 #include <vector>
24 
26 {
27 public:
29  bool read_binary_obs();
30  bool restart();
31  int64_t num_epochs();
32  bool open_obs_file(std::string out_file);
33 
34  // rtklib_solver dump variables
35  // TOW
36  uint32_t TOW_at_current_symbol_ms;
37  // WEEK
38  uint32_t week;
39  // PVT GPS time
40  double RX_time;
41  // User clock offset [s]
42  double clk_offset_s;
43  // ECEF POS X,Y,X [m] + ECEF VEL X,Y,X [m/s] (6 x double)
44  double rr[6];
45  // position variance/covariance (m^2) {c_xx,c_yy,c_zz,c_xy,c_yz,c_zx} (6 x double)
46  double qr[6];
47 
48  // GEO user position Latitude [deg]
49  double latitude;
50  // GEO user position Longitude [deg]
51  double longitude;
52  // GEO user position Height [m]
53  double height;
54 
55  // NUMBER OF VALID SATS
56  uint8_t ns;
57  // RTKLIB solution status
58  uint8_t status;
59  // RTKLIB solution type (0:xyz-ecef,1:enu-baseline)
60  uint8_t type;
61  // AR ratio factor for validation
62  float AR_ratio;
63  // AR ratio threshold for validation
64  float AR_thres;
65 
66  // GDOP / PDOP / HDOP / VDOP
67  double dop[4];
68 
69 private:
70  std::string d_dump_filename;
71  std::ifstream d_dump_file;
72 };
73 
74 #endif // GNSS_SDR_RTKLIB_SOLVER_DUMP_READER_H