From b2531cb926d32cb8de579d7ec6766f8d71191553 Mon Sep 17 00:00:00 2001 From: Javier Arribas Date: Thu, 11 May 2017 12:53:58 +0200 Subject: [PATCH] Bug fixes in Galileo E5a telemetry decoding. Code cleaning in Galileo E5a tracking --- ...el_GPS_L2_M_Flexiband_bin_file_III_1b.conf | 115 +++++++++-- .../galileo_e5a_telemetry_decoder_cc.cc | 38 +--- .../galileo_e5a_telemetry_decoder_cc.h | 1 + .../galileo_e5a_dll_pll_tracking_cc.cc | 8 +- src/core/system_parameters/Galileo_E5a.h | 184 +++++++++--------- .../system_parameters/galileo_fnav_message.cc | 8 +- 6 files changed, 205 insertions(+), 149 deletions(-) diff --git a/conf/gnss-sdr_multichannel_GPS_L2_M_Flexiband_bin_file_III_1b.conf b/conf/gnss-sdr_multichannel_GPS_L2_M_Flexiband_bin_file_III_1b.conf index 40913cc7f..36a78f77b 100644 --- a/conf/gnss-sdr_multichannel_GPS_L2_M_Flexiband_bin_file_III_1b.conf +++ b/conf/gnss-sdr_multichannel_GPS_L2_M_Flexiband_bin_file_III_1b.conf @@ -29,7 +29,7 @@ GNSS-SDR.SUPL_CI=0x31b0 SignalSource.implementation=Flexiband_Signal_Source SignalSource.flag_read_file=true -SignalSource.signal_file=/media/javier/SISTEMA/signals/fraunhofer/L125_III1b_210s.usb ; <- PUT YOUR FILE HERE +SignalSource.signal_file=/home/javier/signals/L125_III1b_210s.usb ; <- PUT YOUR FILE HERE ;#item_type: Type and resolution for each of the signal samples. Use only gr_complex in this version. SignalSource.item_type=gr_complex @@ -38,7 +38,7 @@ SignalSource.item_type=gr_complex SignalSource.firmware_file=flexiband_III-1b.bit ;#RF_channels: Number of RF channels present in the frontend device, must agree the FPGA firmware file -SignalSource.RF_channels=2 +SignalSource.RF_channels=3 ;#frontend channels gain. Not usable yet! SignalSource.gain1=0 @@ -74,7 +74,7 @@ DataTypeAdapter0.item_type=gr_complex InputFilter0.implementation=Freq_Xlating_Fir_Filter ;#dump: Dump the filtered data to a file. -InputFilter0.dump=true +InputFilter0.dump=false ;#dump_filename: Log path and filename. InputFilter0.dump_filename=../data/input_filter_ch0.dat @@ -237,22 +237,29 @@ InputFilter1.decimation_factor=4 ;## Resamples the input data. Resampler1.implementation=Pass_Through + +;###################################################### +;######### RF CHANNEL 2 SIGNAL CONDITIONER ############ +;###################################################### + ;######### SIGNAL_CONDITIONER 2 CONFIG ############ ;## It holds blocks to change data type, filter and resample input data. -SignalConditioner2.implementation=Pass_Through +SignalConditioner2.implementation=Signal_Conditioner ;######### DATA_TYPE_ADAPTER 2 CONFIG ############ DataTypeAdapter2.implementation=Pass_Through DataTypeAdapter2.item_type=gr_complex ;######### INPUT_FILTER 2 CONFIG ############ -InputFilter2.implementation=Pass_Through +;## Filter the input data. Can be combined with frequency translation for IF signals + +InputFilter2.implementation=Freq_Xlating_Fir_Filter ;#dump: Dump the filtered data to a file. InputFilter2.dump=false ;#dump_filename: Log path and filename. -InputFilter2.dump_filename=../data/input_filter.dat +InputFilter2.dump_filename=../data/input_filter_ch2.dat ;#input_item_type: Type and resolution for input signal samples. Use only gr_complex in this version. InputFilter2.input_item_type=gr_complex @@ -260,15 +267,66 @@ InputFilter2.input_item_type=gr_complex ;#outut_item_type: Type and resolution for output filtered signal samples. Use only gr_complex in this version. InputFilter2.output_item_type=gr_complex -;######### RESAMPLER CONFIG 2 ############ +;#taps_item_type: Type and resolution for the taps of the filter. Use only float in this version. +InputFilter2.taps_item_type=float + +;#number_of_taps: Number of taps in the filter. Increasing this parameter increases the processing time +InputFilter2.number_of_taps=5 + +;#number_of _bands: Number of frequency bands in the filter. +InputFilter2.number_of_bands=2 + +;#bands: frequency at the band edges [ b1 e1 b2 e2 b3 e3 ...]. +;#Frequency is in the range [0, 1], with 1 being the Nyquist frequency (Fs/2) +;#The number of band_begin and band_end elements must match the number of bands + +InputFilter2.band1_begin=0.0 +InputFilter2.band1_end=0.45 +InputFilter2.band2_begin=0.55 +InputFilter2.band2_end=1.0 + +;#ampl: desired amplitude at the band edges [ a(b1) a(e1) a(b2) a(e2) ...]. +;#The number of ampl_begin and ampl_end elements must match the number of bands + +InputFilter2.ampl1_begin=1.0 +InputFilter2.ampl1_end=1.0 +InputFilter2.ampl2_begin=0.0 +InputFilter2.ampl2_end=0.0 + +;#band_error: weighting applied to each band (usually 1). +;#The number of band_error elements must match the number of bands +InputFilter2.band1_error=1.0 +InputFilter2.band2_error=1.0 + +;#filter_type: one of "bandpass", "hilbert" or "differentiator" +InputFilter2.filter_type=bandpass + +;#grid_density: determines how accurately the filter will be constructed. +;The minimum value is 16; higher values are slower to compute the filter. +InputFilter2.grid_density=16 + +;#The following options are used only in Freq_Xlating_Fir_Filter implementation. +;#InputFilter0.IF is the intermediate frequency (in Hz) shifted down to zero Hz +;FOR USE GNSS-SDR WITH RTLSDR DONGLES USER MUST SET THE CALIBRATED SAMPLE RATE HERE +; i.e. using front-end-cal as reported here:http://www.cttc.es/publication/turning-a-television-into-a-gnss-receiver/ +InputFilter2.sampling_frequency=40000000 +;# IF deviation due to front-end LO inaccuracies [HZ] +InputFilter2.IF=0 + +;# Decimation factor after the frequency tranaslating block +InputFilter2.decimation_factor=8 + + +;######### RESAMPLER CONFIG 1 ############ ;## Resamples the input data. Resampler2.implementation=Pass_Through ;######### CHANNELS GLOBAL CONFIG ############ ;#count: Number of available GPS satellite channels. -Channels_1C.count=11 -Channels_2S.count=0 +Channels_1C.count=1 +Channels_2S.count=1 +Channels_5X.count=2 ;#GPS.prns=7,8 @@ -283,10 +341,11 @@ Channels.in_acquisition=1 ;# CHANNEL NUMBERING ORDER: GPS L1 C/A, GPS L2 L2C (M), GALILEO E1 B, GALILEO E5a ;# CHANNEL CONNECTION + Channel0.RF_channel_ID=0 -Channel1.RF_channel_ID=0 -Channel2.RF_channel_ID=0 -Channel3.RF_channel_ID=0 +Channel1.RF_channel_ID=1 +Channel2.RF_channel_ID=2 +Channel3.RF_channel_ID=2 Channel4.RF_channel_ID=0 Channel5.RF_channel_ID=0 Channel6.RF_channel_ID=0 @@ -333,6 +392,22 @@ Acquisition_2S.doppler_min=-5000 Acquisition_2S.doppler_step=60 Acquisition_2S.max_dwells=1 +;# GALILEO E5a +Acquisition_5X.dump=false +Acquisition_5X.dump_filename=./acq_dump.dat +Acquisition_5X.item_type=gr_complex +Acquisition_5X.if=0 +Acquisition_5X.coherent_integration_time_ms=1 +Acquisition_5X.implementation=Galileo_E5a_Noncoherent_IQ_Acquisition_CAF +Acquisition_5X.threshold=0.008 +Acquisition_5X.doppler_max=10000 +Acquisition_5X.doppler_step=250 +Acquisition_5X.bit_transition_flag=false +Acquisition_5X.max_dwells=1 +Acquisition_5X.CAF_window_hz=0 ; **Only for E5a** Resolves doppler ambiguity averaging the specified BW in the winner code delay. If set to 0 CAF filter is desactivated. Recommended value 3000 Hz +Acquisition_5X.Zero_padding=0 ; **Only for E5a** Avoids power loss and doppler ambiguity in bit transitions by correlating one code with twice the input data length, ensuring that at least one full code is present without transitions. If set to 1 it is ON, if set to 0 it is OFF. + + ;######### TRACKING CONFIG ############ @@ -359,16 +434,28 @@ Tracking_2S.dll_bw_hz=0.25; Tracking_2S.order=2; Tracking_2S.early_late_space_chips=0.5; +Tracking_5X.implementation=Galileo_E5a_DLL_PLL_Tracking +Tracking_5X.item_type=gr_complex +Tracking_5X.if=0 +Tracking_5X.dump=false +Tracking_5X.dump_filename=./tracking_ch_ +Tracking_5X.pll_bw_hz_init=20.0; **Only for E5a** PLL loop filter bandwidth during initialization [Hz] +Tracking_5X.dll_bw_hz_init=20.0; **Only for E5a** DLL loop filter bandwidth during initialization [Hz] +Tracking_5X.ti_ms=1; **Only for E5a** loop filter integration time after initialization (secondary code delay search)[ms] +Tracking_5X.pll_bw_hz=20.0; +Tracking_5X.dll_bw_hz=20.0; +Tracking_5X.order=2; +Tracking_5X.early_late_space_chips=0.5; ;######### TELEMETRY DECODER CONFIG ############ TelemetryDecoder_1C.implementation=GPS_L1_CA_Telemetry_Decoder TelemetryDecoder_1C.dump=false -TelemetryDecoder_1C.decimation_factor=1; TelemetryDecoder_2S.implementation=GPS_L2C_Telemetry_Decoder TelemetryDecoder_2S.dump=false -TelemetryDecoder_2S.decimation_factor=1; +TelemetryDecoder_5X.implementation=Galileo_E5a_Telemetry_Decoder +TelemetryDecoder_5X.dump=false ;######### OBSERVABLES CONFIG ############ ;#implementation: diff --git a/src/algorithms/telemetry_decoder/gnuradio_blocks/galileo_e5a_telemetry_decoder_cc.cc b/src/algorithms/telemetry_decoder/gnuradio_blocks/galileo_e5a_telemetry_decoder_cc.cc index 39fb2b623..03247cadc 100644 --- a/src/algorithms/telemetry_decoder/gnuradio_blocks/galileo_e5a_telemetry_decoder_cc.cc +++ b/src/algorithms/telemetry_decoder/gnuradio_blocks/galileo_e5a_telemetry_decoder_cc.cc @@ -2,6 +2,7 @@ * \file galileo_e5a_telemetry_decoder_cc.cc * \brief Implementation of a Galileo FNAV message demodulator block * \author Marc Sales, 2014. marcsales92(at)gmail.com + * Javier Arribas, 2017. jarribas(at)cttc.es * \based on work from: *