- Major changes:
- The executable file and the default configuration file is now changed from "./install/mercurio" and "./conf/mercurio.conf" to "./install/gnss-sdr" and "./conf/gnss-sdr.conf", respectively.
- Configuration file structure changed to define in a single entry the internal sampling frequency (after the signal conditioner). NOTICE that this change affects the all the adapters (acquisition, tracking, telemetry_decoder, observables, and PVT). All the adapters are now modified to work with this feature.
- Moved several in-line GPS L1 CA parameters (a.k.a magic numbers..) to ./src/core/system_parameters/GPS_L1_CA.h definition file.
- Tracking blocks now uses DOUBLE values in their outputs.
- Observables and PVT now are separated. PVT and their associated libraries are moved to ./src/algorithms/PVT
- Temporarily disabled the RINEX output (I am working on that!)
- GNSS-SDR screen output now gives extended debug information of the receiver status and events. In the future, this output will be redirected to a log file.
- Bug fixes:
- FILE_SIGNAL_SOURCE now works correctly when the user configures GNSS-SDR to process the entire file.
- GPS_L1_CA_DLL_PLL now computes correctly the PRN start values.
- GPS_L1_CA_DLL_FLL_PLL now computes correctly the PRN start values.
- Several modifications in GPS_L1_CA_Telemetry_Decoder, GPS_L1_CA_Observables, and GPS_L1_CA_PVT modules to fix the GPS position computation.
- New features
- Tracking blocks perform a signal integrity check against NaN outliers before the correlation process.
- Tracking and PVT binary dump options are now documented and we provide MATLAB libraries and sample files to read it. Available in ./utils/matlab" and "./utils/matlab/libs"
- Observables output rate can be configured. This option enables the GPS L1 CA PVT computation at a maximum rate of 1ms.
- GPS_L1_CA_PVT now can perform a moving average Latitude, Longitude, and Altitude output for each of the Observables output. It is configurable using the configuration file.
- Added Google Earth compatible Keyhole Markup Language (KML) output writer class (./src/algorithms/PVT/libs/kml_printer.h and ./src/algorithms/PVT/libs/kml_printer.cc ). You can see the receiver position directly using Google Earth.
- We provide a master configuration file which includes an in-line documentation with all the new (and old) options. It can be found in ./conf/master.conf
git-svn-id: https://svn.code.sf.net/p/gnss-sdr/code/trunk@84 64b25241-fba3-4117-9849-534c7e92360d
2011-12-07 17:59:34 +00:00
|
|
|
/*!
|
2019-03-02 01:21:03 +00:00
|
|
|
* \file gps_l1_ca_telemetry_decoder_gs.h
|
2011-12-28 21:36:45 +00:00
|
|
|
* \brief Interface of a NAV message demodulator block based on
|
|
|
|
* Kay Borre book MATLAB-based GPS receiver
|
- Major changes:
- The executable file and the default configuration file is now changed from "./install/mercurio" and "./conf/mercurio.conf" to "./install/gnss-sdr" and "./conf/gnss-sdr.conf", respectively.
- Configuration file structure changed to define in a single entry the internal sampling frequency (after the signal conditioner). NOTICE that this change affects the all the adapters (acquisition, tracking, telemetry_decoder, observables, and PVT). All the adapters are now modified to work with this feature.
- Moved several in-line GPS L1 CA parameters (a.k.a magic numbers..) to ./src/core/system_parameters/GPS_L1_CA.h definition file.
- Tracking blocks now uses DOUBLE values in their outputs.
- Observables and PVT now are separated. PVT and their associated libraries are moved to ./src/algorithms/PVT
- Temporarily disabled the RINEX output (I am working on that!)
- GNSS-SDR screen output now gives extended debug information of the receiver status and events. In the future, this output will be redirected to a log file.
- Bug fixes:
- FILE_SIGNAL_SOURCE now works correctly when the user configures GNSS-SDR to process the entire file.
- GPS_L1_CA_DLL_PLL now computes correctly the PRN start values.
- GPS_L1_CA_DLL_FLL_PLL now computes correctly the PRN start values.
- Several modifications in GPS_L1_CA_Telemetry_Decoder, GPS_L1_CA_Observables, and GPS_L1_CA_PVT modules to fix the GPS position computation.
- New features
- Tracking blocks perform a signal integrity check against NaN outliers before the correlation process.
- Tracking and PVT binary dump options are now documented and we provide MATLAB libraries and sample files to read it. Available in ./utils/matlab" and "./utils/matlab/libs"
- Observables output rate can be configured. This option enables the GPS L1 CA PVT computation at a maximum rate of 1ms.
- GPS_L1_CA_PVT now can perform a moving average Latitude, Longitude, and Altitude output for each of the Observables output. It is configurable using the configuration file.
- Added Google Earth compatible Keyhole Markup Language (KML) output writer class (./src/algorithms/PVT/libs/kml_printer.h and ./src/algorithms/PVT/libs/kml_printer.cc ). You can see the receiver position directly using Google Earth.
- We provide a master configuration file which includes an in-line documentation with all the new (and old) options. It can be found in ./conf/master.conf
git-svn-id: https://svn.code.sf.net/p/gnss-sdr/code/trunk@84 64b25241-fba3-4117-9849-534c7e92360d
2011-12-07 17:59:34 +00:00
|
|
|
* \author Javier Arribas, 2011. jarribas(at)cttc.es
|
|
|
|
* -------------------------------------------------------------------------
|
|
|
|
*
|
2019-07-26 10:38:20 +00:00
|
|
|
* Copyright (C) 2010-2019 (see AUTHORS file for a list of contributors)
|
- Major changes:
- The executable file and the default configuration file is now changed from "./install/mercurio" and "./conf/mercurio.conf" to "./install/gnss-sdr" and "./conf/gnss-sdr.conf", respectively.
- Configuration file structure changed to define in a single entry the internal sampling frequency (after the signal conditioner). NOTICE that this change affects the all the adapters (acquisition, tracking, telemetry_decoder, observables, and PVT). All the adapters are now modified to work with this feature.
- Moved several in-line GPS L1 CA parameters (a.k.a magic numbers..) to ./src/core/system_parameters/GPS_L1_CA.h definition file.
- Tracking blocks now uses DOUBLE values in their outputs.
- Observables and PVT now are separated. PVT and their associated libraries are moved to ./src/algorithms/PVT
- Temporarily disabled the RINEX output (I am working on that!)
- GNSS-SDR screen output now gives extended debug information of the receiver status and events. In the future, this output will be redirected to a log file.
- Bug fixes:
- FILE_SIGNAL_SOURCE now works correctly when the user configures GNSS-SDR to process the entire file.
- GPS_L1_CA_DLL_PLL now computes correctly the PRN start values.
- GPS_L1_CA_DLL_FLL_PLL now computes correctly the PRN start values.
- Several modifications in GPS_L1_CA_Telemetry_Decoder, GPS_L1_CA_Observables, and GPS_L1_CA_PVT modules to fix the GPS position computation.
- New features
- Tracking blocks perform a signal integrity check against NaN outliers before the correlation process.
- Tracking and PVT binary dump options are now documented and we provide MATLAB libraries and sample files to read it. Available in ./utils/matlab" and "./utils/matlab/libs"
- Observables output rate can be configured. This option enables the GPS L1 CA PVT computation at a maximum rate of 1ms.
- GPS_L1_CA_PVT now can perform a moving average Latitude, Longitude, and Altitude output for each of the Observables output. It is configurable using the configuration file.
- Added Google Earth compatible Keyhole Markup Language (KML) output writer class (./src/algorithms/PVT/libs/kml_printer.h and ./src/algorithms/PVT/libs/kml_printer.cc ). You can see the receiver position directly using Google Earth.
- We provide a master configuration file which includes an in-line documentation with all the new (and old) options. It can be found in ./conf/master.conf
git-svn-id: https://svn.code.sf.net/p/gnss-sdr/code/trunk@84 64b25241-fba3-4117-9849-534c7e92360d
2011-12-07 17:59:34 +00:00
|
|
|
*
|
|
|
|
* GNSS-SDR is a software defined Global Navigation
|
|
|
|
* Satellite Systems receiver
|
|
|
|
*
|
|
|
|
* This file is part of GNSS-SDR.
|
|
|
|
*
|
2020-02-08 00:20:02 +00:00
|
|
|
* SPDX-License-Identifier: GPL-3.0-or-later
|
- Major changes:
- The executable file and the default configuration file is now changed from "./install/mercurio" and "./conf/mercurio.conf" to "./install/gnss-sdr" and "./conf/gnss-sdr.conf", respectively.
- Configuration file structure changed to define in a single entry the internal sampling frequency (after the signal conditioner). NOTICE that this change affects the all the adapters (acquisition, tracking, telemetry_decoder, observables, and PVT). All the adapters are now modified to work with this feature.
- Moved several in-line GPS L1 CA parameters (a.k.a magic numbers..) to ./src/core/system_parameters/GPS_L1_CA.h definition file.
- Tracking blocks now uses DOUBLE values in their outputs.
- Observables and PVT now are separated. PVT and their associated libraries are moved to ./src/algorithms/PVT
- Temporarily disabled the RINEX output (I am working on that!)
- GNSS-SDR screen output now gives extended debug information of the receiver status and events. In the future, this output will be redirected to a log file.
- Bug fixes:
- FILE_SIGNAL_SOURCE now works correctly when the user configures GNSS-SDR to process the entire file.
- GPS_L1_CA_DLL_PLL now computes correctly the PRN start values.
- GPS_L1_CA_DLL_FLL_PLL now computes correctly the PRN start values.
- Several modifications in GPS_L1_CA_Telemetry_Decoder, GPS_L1_CA_Observables, and GPS_L1_CA_PVT modules to fix the GPS position computation.
- New features
- Tracking blocks perform a signal integrity check against NaN outliers before the correlation process.
- Tracking and PVT binary dump options are now documented and we provide MATLAB libraries and sample files to read it. Available in ./utils/matlab" and "./utils/matlab/libs"
- Observables output rate can be configured. This option enables the GPS L1 CA PVT computation at a maximum rate of 1ms.
- GPS_L1_CA_PVT now can perform a moving average Latitude, Longitude, and Altitude output for each of the Observables output. It is configurable using the configuration file.
- Added Google Earth compatible Keyhole Markup Language (KML) output writer class (./src/algorithms/PVT/libs/kml_printer.h and ./src/algorithms/PVT/libs/kml_printer.cc ). You can see the receiver position directly using Google Earth.
- We provide a master configuration file which includes an in-line documentation with all the new (and old) options. It can be found in ./conf/master.conf
git-svn-id: https://svn.code.sf.net/p/gnss-sdr/code/trunk@84 64b25241-fba3-4117-9849-534c7e92360d
2011-12-07 17:59:34 +00:00
|
|
|
*
|
|
|
|
* -------------------------------------------------------------------------
|
2011-10-01 18:45:20 +00:00
|
|
|
*/
|
|
|
|
|
2020-02-08 09:10:46 +00:00
|
|
|
#ifndef GNSS_SDR_GPS_L1_CA_TELEMETRY_DECODER_GS_H
|
|
|
|
#define GNSS_SDR_GPS_L1_CA_TELEMETRY_DECODER_GS_H
|
2011-10-01 18:45:20 +00:00
|
|
|
|
2014-01-12 20:07:38 +00:00
|
|
|
#include "GPS_L1_CA.h"
|
2012-01-20 23:28:11 +00:00
|
|
|
#include "gnss_satellite.h"
|
2019-03-05 22:09:02 +00:00
|
|
|
#include "gnss_synchro.h"
|
2019-03-18 15:28:49 +00:00
|
|
|
#include "gps_navigation_message.h"
|
2018-12-09 21:00:09 +00:00
|
|
|
#include <boost/circular_buffer.hpp>
|
2020-04-02 21:59:35 +00:00
|
|
|
#include <gnuradio/block.h> // for block
|
|
|
|
#include <gnuradio/types.h> // for gr_vector_const_void_star
|
|
|
|
#include <array> // for array
|
|
|
|
#include <cstdint> // for int32_t
|
|
|
|
#include <fstream> // for ofstream
|
|
|
|
#include <string> // for string
|
|
|
|
#if GNURADIO_USES_STD_POINTERS
|
2020-04-02 11:23:20 +00:00
|
|
|
#include <memory> // for std::shared_ptr
|
2020-04-02 21:59:35 +00:00
|
|
|
#else
|
|
|
|
#include <boost/shared_ptr.hpp>
|
|
|
|
#endif
|
2011-10-01 18:45:20 +00:00
|
|
|
|
2019-03-02 01:21:03 +00:00
|
|
|
class gps_l1_ca_telemetry_decoder_gs;
|
2011-12-28 03:05:37 +00:00
|
|
|
|
2020-04-02 21:59:35 +00:00
|
|
|
#if GNURADIO_USES_STD_POINTERS
|
2020-04-02 11:23:20 +00:00
|
|
|
using gps_l1_ca_telemetry_decoder_gs_sptr = std::shared_ptr<gps_l1_ca_telemetry_decoder_gs>;
|
2020-04-02 21:59:35 +00:00
|
|
|
#else
|
|
|
|
using gps_l1_ca_telemetry_decoder_gs_sptr = boost::shared_ptr<gps_l1_ca_telemetry_decoder_gs>;
|
|
|
|
#endif
|
2011-12-28 03:05:37 +00:00
|
|
|
|
2019-07-20 09:13:28 +00:00
|
|
|
gps_l1_ca_telemetry_decoder_gs_sptr gps_l1_ca_make_telemetry_decoder_gs(
|
|
|
|
const Gnss_Satellite &satellite,
|
|
|
|
bool dump);
|
2011-10-01 18:45:20 +00:00
|
|
|
|
2011-12-28 03:05:37 +00:00
|
|
|
/*!
|
2020-01-25 12:07:03 +00:00
|
|
|
* \brief This class implements a block that decodes the NAV data defined in IS-GPS-200K
|
2011-12-28 03:05:37 +00:00
|
|
|
*/
|
2019-03-02 01:21:03 +00:00
|
|
|
class gps_l1_ca_telemetry_decoder_gs : public gr::block
|
2012-10-28 10:56:04 +00:00
|
|
|
{
|
2012-01-16 18:27:31 +00:00
|
|
|
public:
|
2019-03-02 01:21:03 +00:00
|
|
|
~gps_l1_ca_telemetry_decoder_gs();
|
2018-03-03 01:03:39 +00:00
|
|
|
void set_satellite(const Gnss_Satellite &satellite); //!< Set satellite PRN
|
|
|
|
void set_channel(int channel); //!< Set receiver's channel
|
2019-03-18 15:28:49 +00:00
|
|
|
void reset();
|
2019-04-27 10:43:34 +00:00
|
|
|
|
2013-11-17 10:48:27 +00:00
|
|
|
/*!
|
|
|
|
* \brief This is where all signal processing takes place
|
|
|
|
*/
|
2018-03-03 01:03:39 +00:00
|
|
|
int general_work(int noutput_items, gr_vector_int &ninput_items,
|
|
|
|
gr_vector_const_void_star &input_items, gr_vector_void_star &output_items);
|
2013-11-17 10:48:27 +00:00
|
|
|
|
2011-10-01 18:45:20 +00:00
|
|
|
private:
|
2019-07-20 09:13:28 +00:00
|
|
|
friend gps_l1_ca_telemetry_decoder_gs_sptr gps_l1_ca_make_telemetry_decoder_gs(
|
|
|
|
const Gnss_Satellite &satellite,
|
|
|
|
bool dump);
|
2013-11-17 10:48:27 +00:00
|
|
|
|
2019-03-02 01:21:03 +00:00
|
|
|
gps_l1_ca_telemetry_decoder_gs(const Gnss_Satellite &satellite, bool dump);
|
2020-06-19 00:15:56 +00:00
|
|
|
|
2020-06-19 10:39:28 +00:00
|
|
|
bool gps_word_parityCheck(uint32_t gpsword);
|
|
|
|
bool decode_subframe();
|
|
|
|
|
2020-06-23 07:47:58 +00:00
|
|
|
Gps_Navigation_Message d_nav;
|
|
|
|
Gnss_Satellite d_satellite;
|
|
|
|
|
|
|
|
std::array<int32_t, GPS_CA_PREAMBLE_LENGTH_BITS> d_preamble_samples{};
|
|
|
|
|
|
|
|
std::string d_dump_filename;
|
|
|
|
std::ofstream d_dump_file;
|
|
|
|
|
|
|
|
boost::circular_buffer<float> d_symbol_history;
|
|
|
|
|
|
|
|
uint64_t d_sample_counter;
|
|
|
|
uint64_t d_preamble_index;
|
|
|
|
uint64_t d_last_valid_preamble;
|
2019-04-16 07:47:26 +00:00
|
|
|
|
|
|
|
int32_t d_bits_per_preamble;
|
|
|
|
int32_t d_samples_per_preamble;
|
|
|
|
int32_t d_preamble_period_symbols;
|
2020-06-19 00:15:56 +00:00
|
|
|
int32_t d_CRC_error_counter;
|
|
|
|
int32_t d_channel;
|
|
|
|
|
2019-04-16 07:47:26 +00:00
|
|
|
uint32_t d_required_symbols;
|
|
|
|
uint32_t d_frame_length_symbols;
|
|
|
|
uint32_t d_prev_GPS_frame_4bytes;
|
2020-06-19 00:15:56 +00:00
|
|
|
uint32_t d_max_symbols_without_valid_frame;
|
|
|
|
uint32_t d_stat;
|
|
|
|
uint32_t d_TOW_at_Preamble_ms;
|
|
|
|
uint32_t d_TOW_at_current_symbol_ms;
|
2019-04-16 07:47:26 +00:00
|
|
|
|
2020-06-23 07:47:58 +00:00
|
|
|
bool d_flag_frame_sync;
|
|
|
|
bool d_flag_parity;
|
|
|
|
bool d_flag_preamble;
|
|
|
|
bool d_sent_tlm_failed_msg;
|
|
|
|
bool d_flag_PLL_180_deg_phase_locked;
|
|
|
|
bool d_flag_TOW_set;
|
|
|
|
bool d_dump;
|
2011-10-01 18:45:20 +00:00
|
|
|
};
|
|
|
|
|
2020-02-08 09:10:46 +00:00
|
|
|
#endif // GNSS_SDR_GPS_L1_CA_TELEMETRY_DECODER_GS_H
|