From c0f1d95b32df023a46bc2805a2c11a2f4aa1de87 Mon Sep 17 00:00:00 2001 From: Antonio Ramos Date: Fri, 23 Feb 2018 10:50:22 +0100 Subject: [PATCH] debug6 --- .../gnuradio_blocks/hybrid_observables_cc.cc | 22 +++++++++++++++++++ .../gps_l2c_telemetry_decoder_cc.cc | 2 -- 2 files changed, 22 insertions(+), 2 deletions(-) diff --git a/src/algorithms/observables/gnuradio_blocks/hybrid_observables_cc.cc b/src/algorithms/observables/gnuradio_blocks/hybrid_observables_cc.cc index 105e1fc38..4ecb8d236 100644 --- a/src/algorithms/observables/gnuradio_blocks/hybrid_observables_cc.cc +++ b/src/algorithms/observables/gnuradio_blocks/hybrid_observables_cc.cc @@ -422,6 +422,28 @@ void hybrid_observables_cc::correct_TOW_and_compute_prange(std::vector::lowest(); std::vector::iterator it; + + +/////////////////////// DEBUG ////////////////////////// + std::vector::iterator it2; + double thr_ = 250.0 / 3e8; + for(it = data.begin(); it != (data.end() - 1); it++) + { + for(it2 = it + 1; it2 != data.end(); it2++) + { + if(it->PRN == it2->PRN) + { + double tow_dif_ = std::fabs(it->TOW_at_current_symbol_s - it2->TOW_at_current_symbol_s); + if(tow_dif_ > thr_) + { + std::cout << TEXT_RED << "L1 - L2 TOW difference in PRN " << it->PRN << + " = " << tow_dif_ << "[ms]. Equivalent to " << tow_dif_ * 3e8 << " meters in pseudorange" + << TEXT_RESET << std::endl; + } + } + } + } +/////////////////////////////////////////////////////////// for(it = data.begin(); it != data.end(); it++) { if(it->TOW_at_current_symbol_s > TOW_ref) { TOW_ref = it->TOW_at_current_symbol_s; } diff --git a/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2c_telemetry_decoder_cc.cc b/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2c_telemetry_decoder_cc.cc index 95d34aa4f..281698845 100644 --- a/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2c_telemetry_decoder_cc.cc +++ b/src/algorithms/telemetry_decoder/gnuradio_blocks/gps_l2c_telemetry_decoder_cc.cc @@ -150,9 +150,7 @@ int gps_l2c_telemetry_decoder_cc::general_work (int noutput_items __attribute__( } //update TOW at the preamble instant - std::cout<<"delta tow at preamble: "<(msg.tow) * 6.0-d_TOW_at_Preamble*6.0<(msg.tow); - //std::cout<<"["<<(int)msg.prn<<"] deco delay: "<