mirror of
				https://github.com/gnss-sdr/gnss-sdr
				synced 2025-10-30 23:03:05 +00:00 
			
		
		
		
	Merge branch 'next' of https://github.com/gnss-sdr/gnss-sdr into newsatdispatcher
This commit is contained in:
		| @@ -1,274 +0,0 @@ | ||||
| ; This is a GNSS-SDR configuration file | ||||
| ; The configuration API is described at https://gnss-sdr.org/docs/sp-blocks/ | ||||
|  | ||||
| ; You can define your own receiver and invoke it by doing | ||||
| ; gnss-sdr --config_file=my_GNSS_SDR_configuration.conf | ||||
| ; | ||||
|  | ||||
| [GNSS-SDR] | ||||
|  | ||||
| ;######### GLOBAL OPTIONS ################## | ||||
| ;internal_fs_sps: Internal signal sampling frequency after the signal conditioning stage [samples per second]. | ||||
| GNSS-SDR.internal_fs_sps=25000000 | ||||
| Receiver.sources_count=2 | ||||
|  | ||||
| ;######### CONTROL_THREAD CONFIG ############ | ||||
| ControlThread.wait_for_flowgraph=false | ||||
|  | ||||
| ;######### SIGNAL_SOURCE CONFIG ############ | ||||
| ;# Signal Source config for GPS, Galileo signals | ||||
| SignalSource0.implementation=File_Signal_Source | ||||
| SignalSource0.filename=/home/dmiralles/Documents/GNSS-Metadata-Standard/install/GPSL1-GalileoE1.dat | ||||
| SignalSource0.item_type=byte | ||||
| SignalSource0.sampling_frequency=25000000 | ||||
| SignalSource0.samples=0 | ||||
| SignalSource0.repeat=false | ||||
| SignalSource0.dump=false | ||||
| SignalSource0.enable_throttle_control=false | ||||
|  | ||||
| ;# Signal Source config for BDS signals | ||||
| SignalSource1.implementation=File_Signal_Source | ||||
| SignalSource1.filename=/home/dmiralles/Documents/GNSS-Metadata-Standard/install/BdsB1IStr01.dat | ||||
| SignalSource1.item_type=byte | ||||
| SignalSource1.sampling_frequency=25000000 | ||||
| SignalSource1.samples=0 | ||||
| SignalSource1.repeat=false | ||||
| SignalSource1.dump=false | ||||
| SignalSource1.enable_throttle_control=false | ||||
|  | ||||
| ;######### SIGNAL_CONDITIONER CONFIG ############ | ||||
| ;# Signal Conditioner config for GPS, Galileo signals | ||||
| SignalConditioner0.implementation=Signal_Conditioner | ||||
| DataTypeAdapter0.implementation=Byte_To_Short | ||||
| InputFilter0.implementation=Freq_Xlating_Fir_Filter | ||||
| InputFilter0.input_item_type=short | ||||
| InputFilter0.output_item_type=gr_complex | ||||
| InputFilter0.taps_item_type=float | ||||
| InputFilter0.number_of_taps=5 | ||||
| InputFilter0.number_of_bands=2 | ||||
| InputFilter0.band1_begin=0.0 | ||||
| InputFilter0.band1_end=0.70 | ||||
| InputFilter0.band2_begin=0.80 | ||||
| InputFilter0.band2_end=1.0 | ||||
| InputFilter0.ampl1_begin=1.0 | ||||
| InputFilter0.ampl1_end=1.0 | ||||
| InputFilter0.ampl2_begin=0.0 | ||||
| InputFilter0.ampl2_end=0.0 | ||||
| InputFilter0.band1_error=1.0 | ||||
| InputFilter0.band2_error=1.0 | ||||
| InputFilter0.filter_type=bandpass | ||||
| InputFilter0.grid_density=16 | ||||
| InputFilter0.sampling_frequency=25000000 | ||||
| InputFilter0.IF=6250000 | ||||
| Resampler0.implementation=Pass_Through | ||||
| Resampler0.sample_freq_in=25000000 | ||||
| Resampler0.sample_freq_out=25000000 | ||||
| Resampler0.item_type=gr_complex | ||||
|  | ||||
| ;# Signal Conditioner config for BDS signals | ||||
| SignalConditioner1.implementation=Signal_Conditioner | ||||
| DataTypeAdapter1.implementation=Byte_To_Short | ||||
| InputFilter1.implementation=Freq_Xlating_Fir_Filter | ||||
| InputFilter1.input_item_type=short | ||||
| InputFilter1.output_item_type=gr_complex | ||||
| InputFilter1.taps_item_type=float | ||||
| InputFilter1.number_of_taps=5 | ||||
| InputFilter1.number_of_bands=2 | ||||
| InputFilter1.band1_begin=0.0 | ||||
| InputFilter1.band1_end=0.70 | ||||
| InputFilter1.band2_begin=0.80 | ||||
| InputFilter1.band2_end=1.0 | ||||
| InputFilter1.ampl1_begin=1.0 | ||||
| InputFilter1.ampl1_end=1.0 | ||||
| InputFilter1.ampl2_begin=0.0 | ||||
| InputFilter1.ampl2_end=0.0 | ||||
| InputFilter1.band1_error=1.0 | ||||
| InputFilter1.band2_error=1.0 | ||||
| InputFilter1.filter_type=bandpass | ||||
| InputFilter1.grid_density=16 | ||||
| InputFilter1.sampling_frequency=25000000 | ||||
| InputFilter1.IF=6250000 | ||||
| Resampler1.implementation=Pass_Through | ||||
| Resampler1.sample_freq_in=25000000 | ||||
| Resampler1.sample_freq_out=25000000 | ||||
| Resampler1.item_type=gr_complex | ||||
|  | ||||
| ;######### CHANNELS GLOBAL CONFIG ############ | ||||
| Channels_1C.count=7 | ||||
| Channels_1B.count=7 | ||||
| Channels_B1.count=10 | ||||
| Channels.in_acquisition=10 | ||||
|  | ||||
| ;# Preparing collection for GPS satellites | ||||
| Channel0.RF_channel_ID=0 | ||||
| Channel1.RF_channel_ID=0 | ||||
| Channel2.RF_channel_ID=0 | ||||
| Channel3.RF_channel_ID=0 | ||||
| Channel4.RF_channel_ID=0 | ||||
| Channel5.RF_channel_ID=0 | ||||
| Channel6.RF_channel_ID=0 | ||||
| Channel0.signal=1C | ||||
| Channel0.satellite = 2 | ||||
| Channel1.signal=1C | ||||
| Channel1.satellite = 5 | ||||
| Channel2.signal=1C | ||||
| Channel2.satellite = 6 | ||||
| Channel3.signal=1C | ||||
| Channel3.satellite = 7 | ||||
| Channel4.signal=1C | ||||
| Channel4.satellite = 13 | ||||
| Channel5.signal=1C | ||||
| Channel5.satellite = 19 | ||||
| Channel6.signal=1C | ||||
| Channel6.satellite = 29 | ||||
|  | ||||
| ;# Preparing collection for Galileo satellites | ||||
| Channel7.RF_channel_ID=0 | ||||
| Channel8.RF_channel_ID=0 | ||||
| Channel9.RF_channel_ID=0 | ||||
| Channel10.RF_channel_ID=0 | ||||
| Channel11.RF_channel_ID=0 | ||||
| Channel12.RF_channel_ID=0 | ||||
| Channel13.RF_channel_ID=0 | ||||
| Channel7.signal=1B | ||||
| Channel7.satellite = 2 | ||||
| Channel8.signal=1B | ||||
| Channel8.satellite = 5 | ||||
| Channel9.signal=1B | ||||
| Channel9.satellite = 6 | ||||
| Channel10.signal=1B | ||||
| Channel10.satellite = 7 | ||||
| Channel11.signal=1B | ||||
| Channel11.satellite = 13 | ||||
| Channel12.signal=1B | ||||
| Channel12.satellite = 19 | ||||
| Channel13.signal=1B | ||||
| Channel13.satellite = 29 | ||||
|  | ||||
| ;# Preparing collection for BDS satellites | ||||
| Channel14.RF_channel_ID=1 | ||||
| Channel15.RF_channel_ID=1 | ||||
| Channel16.RF_channel_ID=1 | ||||
| Channel17.RF_channel_ID=1 | ||||
| Channel18.RF_channel_ID=1 | ||||
| Channel19.RF_channel_ID=1 | ||||
| Channel20.RF_channel_ID=1 | ||||
| Channel21.RF_channel_ID=1 | ||||
| Channel22.RF_channel_ID=1 | ||||
| Channel23.RF_channel_ID=1 | ||||
|  | ||||
| Channel14.signal=B1 | ||||
| Channel14.satellite = 6 | ||||
| Channel15.signal=B1 | ||||
| Channel15.satellite = 8 | ||||
| Channel16.signal=B1 | ||||
| Channel16.satellite = 9 | ||||
| Channel17.signal=B1 | ||||
| Channel17.satellite = 13 | ||||
| Channel18.signal=B1 | ||||
| Channel18.satellite = 17 | ||||
| Channel19.signal=B1 | ||||
| Channel19.satellite = 1 | ||||
| Channel20.signal=B1 | ||||
| Channel20.satellite = 2 | ||||
| Channel21.signal=B1 | ||||
| Channel21.satellite = 3 | ||||
| Channel22.signal=B1 | ||||
| Channel22.satellite = 4 | ||||
| Channel23.signal=B1 | ||||
| Channel23.satellite = 5 | ||||
|  | ||||
| ;######### ACQUISITION GLOBAL CONFIG ############ | ||||
| ;# Acquisition config for BDS signals | ||||
| Acquisition_B1.implementation=BEIDOU_B1I_PCPS_Acquisition | ||||
| Acquisition_B1.item_type=gr_complex | ||||
| Acquisition_B1.coherent_integration_time_ms=1 | ||||
| Acquisition_B1.threshold=0.0038 | ||||
| Acquisition_B1.doppler_max=15000 | ||||
| Acquisition_B1.doppler_step=100 | ||||
| Acquisition_B1.dump=true | ||||
| Acquisition_B1.dump_filename=/home/dmiralles/Documents/Research/Publications/INSIDE_GNSS/bds_leg_pvt/Data/bds_b1i_acq | ||||
| Acquisition_B1.blocking=false; | ||||
| Acquisition_B1.use_CFAR_algorithm=true; | ||||
| Acquisition_B1.bit_transition_flag = false; | ||||
|  | ||||
| ;# Acquisition config for GPS signals | ||||
| Acquisition_1C.implementation=GPS_L1_CA_PCPS_Acquisition | ||||
| Acquisition_1C.item_type=gr_complex | ||||
| Acquisition_1C.coherent_integration_time_ms=1 | ||||
| Acquisition_1C.threshold=0.0038 | ||||
| Acquisition_1C.doppler_max=15000 | ||||
| Acquisition_1C.doppler_step=100 | ||||
| Acquisition_1C.dump=true | ||||
| Acquisition_1C.dump_filename=/home/dmiralles/Documents/Research/Publications/INSIDE_GNSS/bds_leg_pvt/Data/gps_l1ca_acq | ||||
| Acquisition_1C.blocking=false; | ||||
| Acquisition_1C.use_CFAR_algorithm=true; | ||||
| Acquisition_1C.bit_transition_flag = false; | ||||
|  | ||||
| ;# Acquisition config for Galileo signals | ||||
| Acquisition_1B.implementation=Galileo_E1_PCPS_Ambiguous_Acquisition | ||||
| Acquisition_1B.item_type=gr_complex | ||||
| Acquisition_1B.coherent_integration_time_ms=4 | ||||
| Acquisition_1B.threshold=0.0038 | ||||
| Acquisition_1B.doppler_max=15000 | ||||
| Acquisition_1B.doppler_step=100 | ||||
| Acquisition_1B.dump=true | ||||
| Acquisition_1B.dump_filename=/home/dmiralles/Documents/Research/Publications/INSIDE_GNSS/bds_leg_pvt/Data/gal_e1b_acq | ||||
| Acquisition_1B.blocking=false; | ||||
| Acquisition_1B.use_CFAR_algorithm=true; | ||||
| Acquisition_1B.bit_transition_flag = false; | ||||
|  | ||||
| ;######### TRACKING GLOBAL CONFIG ############ | ||||
| Tracking_B1.implementation=BEIDOU_B1I_DLL_PLL_Tracking | ||||
| Tracking_B1.item_type=gr_complex | ||||
| Tracking_B1.pll_bw_hz=25.0; | ||||
| Tracking_B1.dll_bw_hz=2.50; | ||||
| Tracking_B1.dump=true; | ||||
| Tracking_B1.dump_filename=/home/dmiralles/Documents/Research/Publications/INSIDE_GNSS/bds_leg_pvt/Data/bds_b1i_trk_ch_ | ||||
|  | ||||
| Tracking_1C.implementation=GPS_L1_CA_DLL_PLL_Tracking | ||||
| Tracking_1C.item_type=gr_complex | ||||
| Tracking_1C.pll_bw_hz=25.0; | ||||
| Tracking_1C.dll_bw_hz=2.50; | ||||
| Tracking_1C.dump=true; | ||||
| Tracking_1C.dump_filename=/home/dmiralles/Documents/Research/Publications/INSIDE_GNSS/bds_leg_pvt/Data/gps_l1ca_trk_ch_ | ||||
|  | ||||
| Tracking_1B.implementation=Galileo_E1_DLL_PLL_VEML_Tracking | ||||
| Tracking_1B.item_type=gr_complex | ||||
| Tracking_1B.pll_bw_hz=25.0; | ||||
| Tracking_1B.dll_bw_hz=2.50; | ||||
| Tracking_1B.dump=true; | ||||
| Tracking_1B.dump_filename=/home/dmiralles/Documents/Research/Publications/INSIDE_GNSS/bds_leg_pvt/Data/gal_e1b_trk_ch_ | ||||
|  | ||||
| ;######### TELEMETRY DECODER GPS CONFIG ############ | ||||
| TelemetryDecoder_B1.implementation=BEIDOU_B1I_Telemetry_Decoder | ||||
| TelemetryDecoder_B1.dump=false | ||||
|  | ||||
| TelemetryDecoder_1C.implementation=GPS_L1_CA_Telemetry_Decoder | ||||
| TelemetryDecoder_1C.dump=false | ||||
|  | ||||
| TelemetryDecoder_1B.implementation=Galileo_E1B_Telemetry_Decoder | ||||
| TelemetryDecoder_1B.dump=false | ||||
|  | ||||
| ;######### OBSERVABLES CONFIG ############ | ||||
| Observables.implementation=Hybrid_Observables | ||||
| Observables.dump=true | ||||
| Observables.dump_filename=./observables.dat | ||||
|  | ||||
|  | ||||
| ;######### PVT CONFIG ############ | ||||
| PVT.implementation=RTKLIB_PVT | ||||
| PVT.positioning_mode=Single  ; options: Single, Static, Kinematic, PPP_Static, PPP_Kinematic | ||||
| PVT.iono_model=OFF ; options: OFF, Broadcast, SBAS, Iono-Free-LC, Estimate_STEC, IONEX | ||||
| PVT.trop_model=Saastamoinen ; options: OFF, Saastamoinen, SBAS, Estimate_ZTD, Estimate_ZTD_Grad | ||||
| PVT.output_rate_ms=100 | ||||
| PVT.display_rate_ms=500 | ||||
| PVT.dump=true | ||||
| PVT.dump_filename = /home/dmiralles/Documents/Research/Publications/INSIDE_GNSS/bds_leg_pvt/Data/pvt_l1 | ||||
| PVT.kml_output_enabled = false; | ||||
| PVT.xml_output_enabled = false; | ||||
| PVT.gpx_output_enabled = false; | ||||
| PVT.rinex_output_enabled = false; | ||||
| PVT.rtcm_output_enabled = false; | ||||
| PVT.nmea_output_enabled = false; | ||||
| PVT.geojson_output_enabled = false; | ||||
| @@ -91,25 +91,25 @@ Tracking_B1.implementation=BEIDOU_B1I_DLL_PLL_Tracking | ||||
| Tracking_B1.item_type=gr_complex | ||||
| Tracking_B1.pll_bw_hz=25.0; | ||||
| Tracking_B1.dll_bw_hz=2.50; | ||||
| Tracking_B1.dump=true; | ||||
| Tracking_B1.dump=false; | ||||
| Tracking_B1.dump_filename=./epl_tracking_ch_ | ||||
|  | ||||
|  | ||||
| ;######### TELEMETRY DECODER GPS CONFIG ############ | ||||
| TelemetryDecoder_B1.implementation=BEIDOU_B1I_Telemetry_Decoder | ||||
| TelemetryDecoder_B1.dump=true | ||||
| TelemetryDecoder_B1.dump=false | ||||
|  | ||||
|  | ||||
| ;######### OBSERVABLES CONFIG ############ | ||||
| Observables.implementation=Hybrid_Observables | ||||
| Observables.dump=true | ||||
| Observables.dump=false | ||||
| Observables.dump_filename=./observables.dat | ||||
|  | ||||
|  | ||||
| ;######### PVT CONFIG ############ | ||||
| PVT.implementation=RTKLIB_PVT | ||||
| PVT.positioning_mode=Single  ; options: Single, Static, Kinematic, PPP_Static, PPP_Kinematic | ||||
| PVT.iono_model=OFF ; options: OFF, Broadcast, SBAS, Iono-Free-LC, Estimate_STEC, IONEX | ||||
| PVT.iono_model=Broadcast ; options: OFF, Broadcast, SBAS, Iono-Free-LC, Estimate_STEC, IONEX | ||||
| PVT.trop_model=Saastamoinen ; options: OFF, Saastamoinen, SBAS, Estimate_ZTD, Estimate_ZTD_Grad | ||||
| PVT.output_rate_ms=100 | ||||
| PVT.display_rate_ms=500 | ||||
| @@ -121,3 +121,6 @@ PVT.flag_rtcm_server=false | ||||
| PVT.flag_rtcm_tty_port=false | ||||
| PVT.rtcm_dump_devname=/dev/pts/1 | ||||
| PVT.dump=true | ||||
| PVT.rinex_version=3 | ||||
| PVT.rinex_output_enabled=true | ||||
| PVT.gpx_output_enabled=true | ||||
|   | ||||
| @@ -100,14 +100,14 @@ TelemetryDecoder_B3.dump=false | ||||
|  | ||||
| ;######### OBSERVABLES CONFIG ############ | ||||
| Observables.implementation=Hybrid_Observables | ||||
| Observables.dump=true | ||||
| Observables.dump=false | ||||
| Observables.dump_filename=./observables.dat | ||||
|  | ||||
|  | ||||
| ;######### PVT CONFIG ############ | ||||
| PVT.implementation=RTKLIB_PVT | ||||
| PVT.positioning_mode=Single  ; options: Single, Static, Kinematic, PPP_Static, PPP_Kinematic | ||||
| PVT.iono_model=OFF ; options: OFF, Broadcast, SBAS, Iono-Free-LC, Estimate_STEC, IONEX | ||||
| PVT.iono_model=Broadcast ; options: OFF, Broadcast, SBAS, Iono-Free-LC, Estimate_STEC, IONEX | ||||
| PVT.trop_model=Saastamoinen ; options: OFF, Saastamoinen, SBAS, Estimate_ZTD, Estimate_ZTD_Grad | ||||
| PVT.output_rate_ms=100 | ||||
| PVT.display_rate_ms=500 | ||||
|   | ||||
| @@ -783,7 +783,7 @@ bool Rtklib_Solver::get_PVT(const std::map<int, Gnss_Synchro> &gnss_observables_ | ||||
|                                                         obs_data[i + glo_valid_obs] = insert_obs_to_rtklib(obs_data[i + glo_valid_obs], | ||||
|                                                             gnss_observables_iter->second, | ||||
|                                                             beidou_ephemeris_iter->second.i_BEIDOU_week + BEIDOU_DNAV_BDT2GPST_WEEK_NUM_OFFSET, | ||||
|                                                             1);  // Band 3 (L2/G2/B3) | ||||
|                                                             2);  // Band 3 (L2/G2/B3) | ||||
|                                                         found_B1I_obs = true; | ||||
|                                                         break; | ||||
|                                                     } | ||||
| @@ -801,7 +801,7 @@ bool Rtklib_Solver::get_PVT(const std::map<int, Gnss_Synchro> &gnss_observables_ | ||||
|                                                 obs_data[valid_obs + glo_valid_obs] = insert_obs_to_rtklib(newobs, | ||||
|                                                     gnss_observables_iter->second, | ||||
|                                                     beidou_ephemeris_iter->second.i_BEIDOU_week + BEIDOU_DNAV_BDT2GPST_WEEK_NUM_OFFSET, | ||||
|                                                     1);  // Band 2 (L2/G2) | ||||
|                                                     2);  // Band 2 (L2/G2) | ||||
|                                                 valid_obs++; | ||||
|                                             } | ||||
|                                     } | ||||
| @@ -827,7 +827,6 @@ bool Rtklib_Solver::get_PVT(const std::map<int, Gnss_Synchro> &gnss_observables_ | ||||
|     if ((valid_obs + glo_valid_obs) > 3) | ||||
|         { | ||||
|             int result = 0; | ||||
|             int sat = 0; | ||||
|             nav_t nav_data{}; | ||||
|             nav_data.eph = eph_data.data(); | ||||
|             nav_data.geph = geph_data.data(); | ||||
| @@ -913,21 +912,8 @@ bool Rtklib_Solver::get_PVT(const std::map<int, Gnss_Synchro> &gnss_observables_ | ||||
|                     nav_data.leaps = beidou_dnav_utc_model.d_DeltaT_LS; | ||||
|                 } | ||||
|  | ||||
|             for (auto &lambda_ : nav_data.lam) | ||||
|                 { | ||||
|                     lambda_[0] = SPEED_OF_LIGHT / FREQ1;  // L1/E1 | ||||
|                     lambda_[1] = SPEED_OF_LIGHT / FREQ2;  // L2 | ||||
|                     lambda_[2] = SPEED_OF_LIGHT / FREQ5;  // L5/E5 | ||||
|  | ||||
|                     // Keep update on sat number | ||||
|                     sat++; | ||||
|                     if (sat > NSYSGPS + NSYSGLO + NSYSGAL + NSYSQZS and sat < NSYSGPS + NSYSGLO + NSYSGAL + NSYSQZS + NSYSBDS) | ||||
|                         { | ||||
|                             lambda_[0] = SPEED_OF_LIGHT / FREQ1_BDS;  // B1I | ||||
|                             lambda_[1] = SPEED_OF_LIGHT / FREQ3_BDS;  // B3I | ||||
|                             lambda_[2] = SPEED_OF_LIGHT / FREQ5;      // L5/E5 | ||||
|                         } | ||||
|                 } | ||||
|             /* update carrier wave length using native function call in RTKlib */ | ||||
|             uniqnav(&nav_data); | ||||
|  | ||||
|             result = rtkpos(&rtk_, obs_data.data(), valid_obs + glo_valid_obs, &nav_data); | ||||
|  | ||||
|   | ||||
| @@ -234,7 +234,7 @@ void GalileoE5aPcpsAcquisition::init() | ||||
| void GalileoE5aPcpsAcquisition::set_local_code() | ||||
| { | ||||
|     std::unique_ptr<std::complex<float>> code{new std::complex<float>[code_length_]}; | ||||
|     std::array<char, 3> signal_; | ||||
|     std::array<char, 3> signal_{}; | ||||
|     signal_[0] = '5'; | ||||
|     signal_[2] = '\0'; | ||||
|  | ||||
|   | ||||
| @@ -70,8 +70,8 @@ void beidou_b1i_code_gen_int(gsl::span<int32_t> _dest, int32_t _prn, uint32_t _c | ||||
|             G1[lcv] = G1_register[0]; | ||||
|             G2[lcv] = G2_register[-(phase1[prn_idx] - 11)] ^ G2_register[-(phase2[prn_idx] - 11)]; | ||||
|  | ||||
|             feedback1 = (G1_register[0] + G1_register[1] + G1_register[2] + G1_register[3] + G1_register[4] + G1_register[10]) & 0x1; | ||||
|             feedback2 = (G2_register[0] + G2_register[2] + G2_register[3] + G2_register[6] + G2_register[7] + G2_register[8] + G2_register[9] + G2_register[10]) & 0x1; | ||||
|             feedback1 = G1_register[0] xor G1_register[1] xor G1_register[2] xor G1_register[3] xor G1_register[4] xor G1_register[10]; | ||||
|             feedback2 = G2_register[0] xor G2_register[2] xor G2_register[3] xor G2_register[6] xor G2_register[7] xor G2_register[8] xor G2_register[9] xor G2_register[10]; | ||||
|  | ||||
|             for (lcv2 = 0; lcv2 < 10; lcv2++) | ||||
|                 { | ||||
|   | ||||
| @@ -129,10 +129,9 @@ void beidou_b3i_code_gen_int(gsl::span<int> _dest, signed int _prn, unsigned int | ||||
|             G2[lcv] = G2_register[0]; | ||||
|  | ||||
|             //feedback1 = (test_G1_register[0]+test_G1_register[2]+test_G1_register[3]+test_G1_register[12]) & 0x1; | ||||
|             feedback1 = (G1_register[0] + G1_register[9] + G1_register[10] + G1_register[12]) & 0x01; | ||||
|             feedback2 = (G2_register[0] + G2_register[1] + G2_register[3] + G2_register[4] + | ||||
|                             G2_register[6] + G2_register[7] + G2_register[8] + G2_register[12]) & | ||||
|                         0x01; | ||||
|             feedback1 = G1_register[0] xor G1_register[9] xor G1_register[10] xor G1_register[12]; | ||||
|             feedback2 = G2_register[0] xor G2_register[1] xor G2_register[3] xor G2_register[4] xor | ||||
|                         G2_register[6] xor G2_register[7] xor G2_register[8] xor G2_register[12]; | ||||
|  | ||||
|             for (lcv2 = 0; lcv2 < 12; lcv2++) | ||||
|                 { | ||||
| @@ -157,7 +156,7 @@ void beidou_b3i_code_gen_int(gsl::span<int> _dest, signed int _prn, unsigned int | ||||
|     // Generate PRN from G1 and G2 Registers | ||||
|     for (lcv = 0; lcv < _code_length; lcv++) | ||||
|         { | ||||
|             aux = (G1[(lcv + _chip_shift) % _code_length] + G2[delay]) & 0x01; | ||||
|             aux = G1[(lcv + _chip_shift) % _code_length] xor G2[delay]; | ||||
|             if (aux == true) | ||||
|                 { | ||||
|                     _dest[lcv] = 1; | ||||
|   | ||||
| @@ -30,6 +30,7 @@ | ||||
|  */ | ||||
|  | ||||
| #include "geofunctions.h" | ||||
| #include <array> | ||||
| #include <cmath>  // for sin, cos, sqrt, abs, pow | ||||
|  | ||||
| const double STRP_PI = 3.1415926535898;  // Pi as defined in IS-GPS-200E | ||||
| @@ -350,8 +351,8 @@ arma::mat Euler_to_CTM(const arma::vec &eul) | ||||
|  | ||||
| arma::vec cart2geo(const arma::vec &XYZ, int elipsoid_selection) | ||||
| { | ||||
|     const double a[5] = {6378388.0, 6378160.0, 6378135.0, 6378137.0, 6378137.0}; | ||||
|     const double f[5] = {1.0 / 297.0, 1.0 / 298.247, 1.0 / 298.26, 1.0 / 298.257222101, 1.0 / 298.257223563}; | ||||
|     const std::array<double, 5> a{6378388.0, 6378160.0, 6378135.0, 6378137.0, 6378137.0}; | ||||
|     const std::array<double, 5> f{1.0 / 297.0, 1.0 / 298.247, 1.0 / 298.26, 1.0 / 298.257222101, 1.0 / 298.257223563}; | ||||
|  | ||||
|     double lambda = atan2(XYZ[1], XYZ[0]); | ||||
|     double ex2 = (2.0 - f[elipsoid_selection]) * f[elipsoid_selection] / ((1.0 - f[elipsoid_selection]) * (1.0 - f[elipsoid_selection])); | ||||
|   | ||||
| @@ -36,19 +36,19 @@ | ||||
| #include <memory> | ||||
|  | ||||
|  | ||||
| int32_t gps_l2c_m_shift(int32_t x) | ||||
| uint32_t gps_l2c_m_shift(uint32_t x) | ||||
| { | ||||
|     return static_cast<int32_t>((x >> 1) ^ ((x & 1) * 0445112474)); | ||||
|     return static_cast<uint32_t>((x >> 1U) ^ ((x & 1U) * 0445112474U)); | ||||
| } | ||||
|  | ||||
|  | ||||
| void gps_l2c_m_code(gsl::span<int32_t> _dest, uint32_t _prn) | ||||
| { | ||||
|     int32_t x; | ||||
|     uint32_t x; | ||||
|     x = GPS_L2C_M_INIT_REG[_prn - 1]; | ||||
|     for (int32_t n = 0; n < GPS_L2_M_CODE_LENGTH_CHIPS; n++) | ||||
|         { | ||||
|             _dest[n] = static_cast<int8_t>(x & 1); | ||||
|             _dest[n] = static_cast<int8_t>(x & 1U); | ||||
|             x = gps_l2c_m_shift(x); | ||||
|         } | ||||
| } | ||||
|   | ||||
| @@ -83,7 +83,7 @@ void gps_l1_ca_code_gen_int(gsl::span<int32_t> _dest, int32_t _prn, uint32_t _ch | ||||
|             G2[lcv] = G2_register[0]; | ||||
|  | ||||
|             feedback1 = G1_register[7] ^ G1_register[0]; | ||||
|             feedback2 = (G2_register[8] + G2_register[7] + G2_register[4] + G2_register[2] + G2_register[1] + G2_register[0]) & 0x1; | ||||
|             feedback2 = G2_register[8] xor G2_register[7] xor G2_register[4] xor G2_register[2] xor G2_register[1] xor G2_register[0]; | ||||
|  | ||||
|             for (lcv2 = 0; lcv2 < 9; lcv2++) | ||||
|                 { | ||||
|   | ||||
| @@ -166,9 +166,8 @@ double prange(const obsd_t *obs, const nav_t *nav, const double *azel, | ||||
|             return 0.0; | ||||
|         } | ||||
|  | ||||
|  | ||||
|     /* L1-L2 for GPS/GLO/QZS, L1-L5 for GAL/SBS */ | ||||
|     if (sys == SYS_GAL or sys == SYS_SBS) | ||||
|     /* L1-L2 for GPS/GLO/QZS, L1-L5 for GAL/SBS/BDS */ | ||||
|     if (sys == SYS_GAL or sys == SYS_SBS or sys == SYS_BDS) | ||||
|         { | ||||
|             j = 2; | ||||
|         } | ||||
| @@ -285,7 +284,7 @@ double prange(const obsd_t *obs, const nav_t *nav, const double *azel, | ||||
|                     if (sys == SYS_BDS) | ||||
|                         { | ||||
|                             P2 += P2_C2; /* C2->P2 */ | ||||
|                             PC = P2; // no tgd corrections for B3I | ||||
|                             PC = P2;     // no tgd corrections for B3I | ||||
|                         } | ||||
|                     else if (sys == SYS_GAL or sys == SYS_GLO or sys == SYS_BDS)  // Gal. E5a single freq. | ||||
|                         { | ||||
|   | ||||
| @@ -271,7 +271,7 @@ void beidou_b1i_telemetry_decoder_gs::decode_subframe(float *frame_symbols) | ||||
|             std::shared_ptr<Beidou_Dnav_Iono> tmp_obj = std::make_shared<Beidou_Dnav_Iono>(d_nav.get_iono()); | ||||
|             this->message_port_pub(pmt::mp("telemetry"), pmt::make_any(tmp_obj)); | ||||
|             LOG(INFO) << "BEIDOU DNAV Iono have been received in channel" << d_channel << " from satellite " << d_satellite; | ||||
|             std::cout << "New BEIDOU B1I DNAV Iono message received in channel " << d_channel << ": Iono model parameters from satellite " << d_satellite << TEXT_RESET << std::endl; | ||||
|             std::cout << TEXT_YELLOW << "New BEIDOU B1I DNAV Iono message received in channel " << d_channel << ": Iono model parameters from satellite " << d_satellite << TEXT_RESET << std::endl; | ||||
|         } | ||||
|     if (d_nav.have_new_almanac() == true) | ||||
|         { | ||||
|   | ||||
| @@ -578,8 +578,10 @@ void dll_pll_veml_tracking::start_tracking() | ||||
|     d_carrier_phase_rate_step_rad = 0.0; | ||||
|     d_carr_ph_history.clear(); | ||||
|     d_code_ph_history.clear(); | ||||
|     std::array<char, 3> Signal_; | ||||
|     std::memcpy(Signal_.data(), d_acquisition_gnss_synchro->Signal, 3); | ||||
|     std::array<char, 3> Signal_{}; | ||||
|     Signal_[0] = d_acquisition_gnss_synchro->Signal[0]; | ||||
|     Signal_[1] = d_acquisition_gnss_synchro->Signal[1]; | ||||
|     Signal_[2] = d_acquisition_gnss_synchro->Signal[2]; | ||||
|  | ||||
|     if (systemName == "GPS" and signal_type == "1C") | ||||
|         { | ||||
| @@ -665,7 +667,7 @@ void dll_pll_veml_tracking::start_tracking() | ||||
|                     d_symbols_per_bit = BEIDOU_B1I_TELEMETRY_SYMBOLS_PER_BIT;  //todo: enable after fixing beidou symbol synchronization | ||||
|                     d_correlation_length_ms = 1; | ||||
|                     d_code_samples_per_chip = 1; | ||||
|                     d_secondary = false; | ||||
|                     d_secondary = true; | ||||
|                     trk_parameters.track_pilot = false; | ||||
|                     // synchronize and remove data secondary code | ||||
|                     d_secondary_code_length = static_cast<uint32_t>(BEIDOU_B1I_SECONDARY_CODE_LENGTH); | ||||
| @@ -685,7 +687,7 @@ void dll_pll_veml_tracking::start_tracking() | ||||
|                     d_symbols_per_bit = BEIDOU_B3I_GEO_TELEMETRY_SYMBOLS_PER_BIT;  //todo: enable after fixing beidou symbol synchronization | ||||
|                     d_correlation_length_ms = 1; | ||||
|                     d_code_samples_per_chip = 1; | ||||
|                     d_secondary = true; | ||||
|                     d_secondary = false; | ||||
|                     trk_parameters.track_pilot = false; | ||||
|                     // set the preamble in the secondary code acquisition | ||||
|                     d_secondary_code_length = static_cast<uint32_t>(BEIDOU_B3I_GEO_PREAMBLE_LENGTH_SYMBOLS); | ||||
|   | ||||
| @@ -467,9 +467,9 @@ int Galileo_E1_Tcp_Connector_Tracking_cc::general_work(int noutput_items __attri | ||||
|         } | ||||
|     //assign the GNURadio block output data | ||||
|     current_synchro_data.System = {'E'}; | ||||
|     std::string str_aux = "1B"; | ||||
|     const char *str = str_aux.c_str();  // get a C style null terminated string | ||||
|     std::memcpy(static_cast<void *>(current_synchro_data.Signal), str, 3); | ||||
|     current_synchro_data.Signal[0] = '1'; | ||||
|     current_synchro_data.Signal[1] = 'B'; | ||||
|     current_synchro_data.Signal[2] = '\0'; | ||||
|  | ||||
|     current_synchro_data.fs = d_fs_in; | ||||
|     *out[0] = current_synchro_data; | ||||
|   | ||||
| @@ -500,11 +500,11 @@ int Gps_L1_Ca_Tcp_Connector_Tracking_cc::general_work(int noutput_items __attrib | ||||
|             d_tcp_com.send_receive_tcp_packet_gps_l1_ca(tx_variables_array, &tcp_data); | ||||
|         } | ||||
|  | ||||
|     //assign the GNURadio block output data | ||||
|     // assign the GNU Radio block output data | ||||
|     current_synchro_data.System = {'G'}; | ||||
|     std::string str_aux = "1C"; | ||||
|     const char *str = str_aux.c_str();  // get a C style null terminated string | ||||
|     std::memcpy(static_cast<void *>(current_synchro_data.Signal), str, 3); | ||||
|     current_synchro_data.Signal[0] = '1'; | ||||
|     current_synchro_data.Signal[1] = 'C'; | ||||
|     current_synchro_data.Signal[2] = '\0'; | ||||
|  | ||||
|     current_synchro_data.fs = d_fs_in; | ||||
|     *out[0] = current_synchro_data; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Javier Arribas
					Javier Arribas