1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-12-13 19:50:34 +00:00

Developing interface code for RINEX printer

This commit is contained in:
Damian Miralles 2017-07-17 21:50:36 -07:00 committed by Damian Miralles
parent fbd6b211eb
commit c445ac261b
2 changed files with 80 additions and 0 deletions

View File

@ -1181,6 +1181,7 @@ int rtklib_pvt_cc::work (int noutput_items, gr_vector_const_void_star &input_ite
}
// ####################### RTCM MESSAGES #################
//TODO Add RTCM logic for GLONASS satellites
if(b_rtcm_writing_started)
{
if(type_of_rx == 1) // GPS L1 C/A

View File

@ -61,8 +61,10 @@
#include "gps_navigation_message.h"
#include "gps_cnav_navigation_message.h"
#include "galileo_navigation_message.h"
#include "glonass_gnav_navigation_message.h"
#include "GPS_L1_CA.h"
#include "Galileo_E1.h"
#include "GLONASS_L1_CA.h"
#include "gnss_synchro.h"
class Sbas_Raw_Msg;
@ -88,6 +90,7 @@ public:
std::fstream navFile ; //<! Output file stream for RINEX navigation data file
std::fstream sbsFile ; //<! Output file stream for RINEX SBAS raw data file
std::fstream navGalFile ; //<! Output file stream for RINEX Galileo navigation data file
std::fstream navGloFile ; //<! Output file stream for RINEX GLONASS navigation data file
std::fstream navMixFile ; //<! Output file stream for RINEX Mixed navigation data file
/*!
@ -110,6 +113,26 @@ public:
*/
void rinex_nav_header(std::fstream & out, const Gps_Iono & gps_iono, const Gps_Utc_Model & gps_utc_model, const Galileo_Iono & galileo_iono, const Galileo_Utc_Model & galileo_utc_model, const Galileo_Almanac & galileo_almanac);
/*!
* \brief Generates the GLONASS L1, L2 C/A Navigation Data header
*/
void rinex_nav_header(std::fstream & out, const Glonass_Gnav_Utc_Model & utc_model, const Glonass_Gnav_Almanac & glonass_gnav_almanac);
/*!
* \brief Generates the Mixed (GLONASS/Galileo) Navigation Data header
*/
void rinex_nav_header(std::fstream & out, const Glonass_Gnav_Utc_Model & glonass_gnav_utc_model, const Glonass_Gnav_Almanac & glonass_gnav_almanac, const Galileo_Iono & galileo_iono, const Galileo_Utc_Model & galileo_utc_model, const Galileo_Almanac & galileo_almanac);
/*!
* \brief Generates the Mixed (GLONASS L1, L2/GPS L1 C/A) Navigation Data header
*/
void rinex_nav_header(std::fstream & out, const Glonass_Gnav_Utc_Model & glonass_gnav_utc_model, const Glonass_Gnav_Almanac & glonass_gnav_almanac, const Gps_Iono & gps_iono, const Gps_Utc_Model & gps_utc_model);
/*!
* \brief Generates the Mixed (GLONASS L1, L2/GPS L2C ) Navigation Data header
*/
void rinex_nav_header(std::fstream & out, const Glonass_Gnav_Utc_Model & glonass_gnav_utc_model, const Glonass_Gnav_Almanac & glonass_gnav_almanac, const Gps_CNAV_Iono & gps_CNAV_iono, const Gps_CNAV_Utc_Model & gps_CNAV_utc_model);
/*!
* \brief Generates the GPS Observation data header
*/
@ -135,6 +158,26 @@ public:
*/
void rinex_obs_header(std::fstream & out, const Gps_Ephemeris & gps_eph, const Galileo_Ephemeris & galileo_eph, const double d_TOW_first_observation, const std::string galileo_bands = "1B");
/*!
* \brief Generates the GLONASS GNAV Observation data header. Example: bands("1C"), bands("1C 2C"), bands("2C"), ... Default: "1C".
*/
void rinex_obs_header(std::fstream & out, const Glonass_Gnav_Ephemeris & eph, const double d_TOW_first_observation, const std::string bands = "1C");
/*!
* \brief Generates the Mixed (GPS L1 C/A /GLONASS) Observation data header. Example: galileo_bands("1C"), galileo_bands("1B 5X"), galileo_bands("5X"), ... Default: "1B".
*/
void rinex_obs_header(std::fstream & out, const Glonass_Gnav_Ephemeris & glonass_gnav_eph, const Gps_Ephemeris & gps_eph, const double d_TOW_first_observation, const std::string gps_bands = "1C");
/*!
* \brief Generates the Mixed (GPS L2C/GLONASS) Observation data header. Example: galileo_bands("1C"), galileo_bands("1B 5X"), galileo_bands("5X"), ... Default: "1B".
*/
void rinex_obs_header(std::fstream & out, const Glonass_Gnav_Ephemeris & glonass_gnav_eph, const Gps_Ephemeris & gps_CNAV_eph, const double d_TOW_first_observation, const std::string gps_bands = "1C");
/*!
* \brief Generates the Mixed (Galileo/GLONASS) Observation data header. Example: galileo_bands("1C"), galileo_bands("1B 5X"), galileo_bands("5X"), ... Default: "1B".
*/
void rinex_obs_header(std::fstream & out, const Glonass_Gnav_Ephemeris & glonass_gnav_eph, const Galileo_Ephemeris & galileo_eph, const double d_TOW_first_observation, const std::string gps_bands = "1B");
/*!
* \brief Generates the SBAS raw data header
*/
@ -160,6 +203,11 @@ public:
*/
boost::posix_time::ptime compute_Galileo_time(const Galileo_Ephemeris & eph, const double obs_time);
/*!
* \brief Computes the GLONASS System Time and returns a boost::posix_time::ptime object
*/
boost::posix_time::ptime compute_GLONASS_time(const Glonass_Gnav_Ephemeris & eph, const double obs_time);
/*!
* \brief Writes data from the GPS L1 C/A navigation message into the RINEX file
*/
@ -205,6 +253,26 @@ public:
*/
void log_rinex_obs(std::fstream & out, const Gps_Ephemeris & gps_eph, const Galileo_Ephemeris & galileo_eph, const double gps_obs_time, const std::map<int, Gnss_Synchro> & observables);
/*!
* \brief Writes GLONASS GNAV observables into the RINEX file. Example: glonass_bands("1C"), galileo_bands("1B 5X"), galileo_bands("5X"), ... Default: "1B".
*/
void log_rinex_obs(std::fstream & out, const Glonass_Gnav_Ephemeris & eph, double obs_time, const std::map<int, Gnss_Synchro> & observables, const std::string glonass_bands = "1C");
/*!
* \brief Writes Mixed GLONASS / GPS L1 C/A observables into the RINEX file
*/
void log_rinex_obs(std::fstream & out, const Glonass_Gnav_Ephemeris & glonass_gnav_eph, const Gps_Ephemeris & gps_eph, const double gps_obs_time, const std::map<int, Gnss_Synchro> & observables);
/*!
* \brief Writes Mixed GLONASS / GPS L2C observables into the RINEX file
*/
void log_rinex_obs(std::fstream & out, const Glonass_Gnav_Ephemeris & glonass_gnav_eph, const Gps_CNAV_Ephemeris & gps_CNAV_eph, const double gps_obs_time, const std::map<int, Gnss_Synchro> & observables);
/*!
* \brief Writes Mixed GLONASS / Galileo observables into the RINEX file
*/
void log_rinex_obs(std::fstream & out, const Glonass_Gnav_Ephemeris & glonass_gnav_eph, const Galileo_Ephemeris & galileo_eph, const double gps_obs_time, const std::map<int, Gnss_Synchro> & observables);
/*!
* \brief Represents GPS time in the date time format. Leap years are considered, but leap seconds are not.
*/
@ -223,12 +291,22 @@ public:
void update_nav_header(std::fstream & out, const Galileo_Iono & galileo_iono, const Galileo_Utc_Model & utc_model, const Galileo_Almanac & galileo_almanac);
void update_nav_header(std::fstream & out, const Glonass_Gnav_Utc_Model & glonass_gnav_utc_model, const Glonass_Gnav_Almanac & glonass_gnav_almanac);
void update_nav_header(std::fstream & out, const Glonass_Gnav_Utc_Model & glonass_gnav_utc_model, const Glonass_Gnav_Almanac & glonass_gnav_almanac, const Gps_Utc_Model & gps_utc, const Gps_Iono & gps_iono);
void update_nav_header(std::fstream & out, const Glonass_Gnav_Utc_Model & glonass_gnav_utc_model, const Glonass_Gnav_Almanac & glonass_gnav_almanac, const Gps_CNAV_Utc_Model & gps_CNAV_utc, const Gps_CNAV_Iono & gps_CNAV_iono);
void update_nav_header(std::fstream & out, const Glonass_Gnav_Utc_Model & glonass_gnav_utc_model, const Glonass_Gnav_Almanac & glonass_gnav_almanac, const Galileo_Iono & galileo_iono, const Galileo_Utc_Model & galileo_utc_model, const Galileo_Almanac& galileo_almanac);
void update_obs_header(std::fstream & out, const Gps_Utc_Model & utc_model);
void update_obs_header(std::fstream & out, const Gps_CNAV_Utc_Model & utc_model);
void update_obs_header(std::fstream & out, const Galileo_Utc_Model & galileo_utc_model);
void update_obs_header(std::fstream & out, const Glonass_Gnav_Utc_Model & glonass_gnav_utc_model);
std::map<std::string,std::string> satelliteSystem; //<! GPS, GLONASS, SBAS payload, Galileo or Compass
std::map<std::string,std::string> observationType; //<! PSEUDORANGE, CARRIER_PHASE, DOPPLER, SIGNAL_STRENGTH
std::map<std::string,std::string> observationCode; //<! GNSS observation descriptors
@ -238,6 +316,7 @@ public:
std::string obsfilename;
std::string sbsfilename;
std::string navGalfilename;
std::string navGlofilename;
std::string navMixfilename;
private: