diff --git a/conf/gnss-sdr_BDS_B1I_GPS_L1_CA_ibyte.conf b/conf/gnss-sdr_BDS_B1I_GPS_L1_CA_ibyte.conf index e62e2c553..d050831a7 100644 --- a/conf/gnss-sdr_BDS_B1I_GPS_L1_CA_ibyte.conf +++ b/conf/gnss-sdr_BDS_B1I_GPS_L1_CA_ibyte.conf @@ -231,10 +231,12 @@ Tracking_1B.dump_filename=/home/dmiralles/Documents/Research/Publications/INSIDE ;######### TELEMETRY DECODER GPS CONFIG ############ TelemetryDecoder_B1.implementation=BEIDOU_B1I_Telemetry_Decoder -TelemetryDecoder_B1.dump=false +TelemetryDecoder_B1.dump=true +TelemetryDecoder_B1.dump_filename = ./bds_tel_dec TelemetryDecoder_1C.implementation=GPS_L1_CA_Telemetry_Decoder -TelemetryDecoder_1C.dump=false +TelemetryDecoder_1C.dump=true +TelemetryDecoder_1C.dump_filename=./gps_tel_dec TelemetryDecoder_1B.implementation=Galileo_E1B_Telemetry_Decoder TelemetryDecoder_1B.dump=false diff --git a/conf/gnss-sdr_BDS_B1I_byte.conf b/conf/gnss-sdr_BDS_B1I_byte.conf index 062e0a0e2..4d515b0a4 100644 --- a/conf/gnss-sdr_BDS_B1I_byte.conf +++ b/conf/gnss-sdr_BDS_B1I_byte.conf @@ -95,7 +95,7 @@ Tracking_B1.dump_filename=./epl_tracking_ch_ ;######### TELEMETRY DECODER GPS CONFIG ############ TelemetryDecoder_B1.implementation=BEIDOU_B1I_Telemetry_Decoder -TelemetryDecoder_B1.dump=false +TelemetryDecoder_B1.dump=true ;######### OBSERVABLES CONFIG ############ diff --git a/src/algorithms/libs/rtklib/rtklib_conversions.cc b/src/algorithms/libs/rtklib/rtklib_conversions.cc index 280d81ebe..fe3aad6c8 100644 --- a/src/algorithms/libs/rtklib/rtklib_conversions.cc +++ b/src/algorithms/libs/rtklib/rtklib_conversions.cc @@ -261,6 +261,7 @@ eph_t eph_to_rtklib(const Gps_Ephemeris& gps_eph) return rtklib_sat; } + eph_t eph_to_rtklib(const Beidou_Dnav_Ephemeris& bei_eph) { eph_t rtklib_sat = {0, 0, 0, 0, 0, 0, 0, 0, {0, 0}, {0, 0}, {0, 0}, 0.0, 0.0, 0.0, 0.0, 0.0, @@ -389,6 +390,7 @@ eph_t eph_to_rtklib(const Gps_CNAV_Ephemeris& gps_cnav_eph) return rtklib_sat; } + alm_t alm_to_rtklib(const Gps_Almanac& gps_alm) { alm_t rtklib_alm; diff --git a/src/algorithms/telemetry_decoder/gnuradio_blocks/beidou_b1i_telemetry_decoder_gs.cc b/src/algorithms/telemetry_decoder/gnuradio_blocks/beidou_b1i_telemetry_decoder_gs.cc index 367d28ec6..7adb2b354 100644 --- a/src/algorithms/telemetry_decoder/gnuradio_blocks/beidou_b1i_telemetry_decoder_gs.cc +++ b/src/algorithms/telemetry_decoder/gnuradio_blocks/beidou_b1i_telemetry_decoder_gs.cc @@ -570,11 +570,11 @@ int beidou_b1i_telemetry_decoder_gs::general_work(int noutput_items __attribute_ { double tmp_double; uint64_t tmp_ulong_int; - tmp_double = d_TOW_at_current_symbol_ms; + tmp_double = static_cast(d_TOW_at_current_symbol_ms); d_dump_file.write(reinterpret_cast(&tmp_double), sizeof(double)); tmp_ulong_int = current_symbol.Tracking_sample_counter; d_dump_file.write(reinterpret_cast(&tmp_ulong_int), sizeof(uint64_t)); - tmp_double = 0; + tmp_double = current_symbol.Code_phase_samples; d_dump_file.write(reinterpret_cast(&tmp_double), sizeof(double)); } catch (const std::ifstream::failure &e) diff --git a/src/utils/matlab/gps_l1_ca_telemetry_plot_sample.m b/src/utils/matlab/gps_l1_ca_telemetry_plot_sample.m index 1d56cb60d..baaad4bd7 100644 --- a/src/utils/matlab/gps_l1_ca_telemetry_plot_sample.m +++ b/src/utils/matlab/gps_l1_ca_telemetry_plot_sample.m @@ -26,14 +26,15 @@ % ------------------------------------------------------------------------- % -%close all; -%clear all; -samplingFreq = 64e6/16; %[Hz] -channels=4; -path='/home/sergi/gnss/gnss-sdr/install/'; +close all; + +samplingFreq = 25000000; %[Hz] +channels=[0:9]; +path='/home/dmiralles/Documents/gnss-sdr/'; +addpath('libs/'); clear PRN_absolute_sample_start; -for N=1:1:channels - telemetry_log_path=[path 'telemetry' num2str(N-1) '.dat']; +for N=1:1:length(channels) + telemetry_log_path=[path 'telemetry' num2str(channels(N)) '.dat']; GNSS_telemetry(N)= gps_l1_ca_read_telemetry_dump(telemetry_log_path); end diff --git a/src/utils/matlab/libs/gps_l1_ca_read_telemetry_dump.m b/src/utils/matlab/libs/gps_l1_ca_read_telemetry_dump.m index 2d6cdb479..c7274f1f5 100644 --- a/src/utils/matlab/libs/gps_l1_ca_read_telemetry_dump.m +++ b/src/utils/matlab/libs/gps_l1_ca_read_telemetry_dump.m @@ -50,7 +50,7 @@ else telemetry.preamble_delay_ms = fread (f, count, 'float64',skip_bytes_each_read-double_size_bytes); bytes_shift=bytes_shift+double_size_bytes; fseek(f,bytes_shift,'bof'); % move to next interleaved - telemetry.prn_delay_ms = fread (f, count, 'float64',skip_bytes_each_read-double_size_bytes); + telemetry.prn_delay_ms = fread (f, count, 'uint64',skip_bytes_each_read-double_size_bytes); bytes_shift=bytes_shift+double_size_bytes; fseek(f,bytes_shift,'bof'); % move to next interleaved telemetry.Preamble_symbol_counter = fread (f, count, 'float64',skip_bytes_each_read-double_size_bytes);