mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2024-12-15 20:50:33 +00:00
Fixed Carrier phase observable initialization. GNSS-SDR Observables quality verified with RTK positioning modes using RINEX files
This commit is contained in:
parent
79a47a8a49
commit
e4dd4349c6
@ -1945,7 +1945,8 @@ void rtklib_pvt_gs::initialize_and_apply_carrier_phase_offset()
|
|||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
initial_carrier_phase_offset_estimation_rads.at(observables_iter->second.Channel_ID) = (PI_2 * observables_iter->second.Pseudorange_m / wavelength_m) - observables_iter->second.Carrier_phase_rads;
|
double wrap_carrier_phase_rad = fmod(observables_iter->second.Carrier_phase_rads, PI_2);
|
||||||
|
initial_carrier_phase_offset_estimation_rads.at(observables_iter->second.Channel_ID) = PI_2 * round(observables_iter->second.Pseudorange_m / wavelength_m) - observables_iter->second.Carrier_phase_rads + wrap_carrier_phase_rad;
|
||||||
channel_initialized.at(observables_iter->second.Channel_ID) = true;
|
channel_initialized.at(observables_iter->second.Channel_ID) = true;
|
||||||
DLOG(INFO) << "initialized carrier phase at channel " << observables_iter->second.Channel_ID;
|
DLOG(INFO) << "initialized carrier phase at channel " << observables_iter->second.Channel_ID;
|
||||||
}
|
}
|
||||||
|
@ -529,6 +529,7 @@ dll_pll_veml_tracking::dll_pll_veml_tracking(const Dll_Pll_Conf &conf_) : gr::bl
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
d_corrected_doppler = false;
|
d_corrected_doppler = false;
|
||||||
|
d_acc_carrier_phase_initialized = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -757,6 +758,7 @@ void dll_pll_veml_tracking::start_tracking()
|
|||||||
d_pull_in_transitory = true;
|
d_pull_in_transitory = true;
|
||||||
d_Prompt_circular_buffer.clear();
|
d_Prompt_circular_buffer.clear();
|
||||||
d_corrected_doppler = false;
|
d_corrected_doppler = false;
|
||||||
|
d_acc_carrier_phase_initialized = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1021,6 +1023,16 @@ void dll_pll_veml_tracking::run_dll_pll()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void dll_pll_veml_tracking::check_carrier_phase_coherent_initialization(uint64_t sample_counter)
|
||||||
|
{
|
||||||
|
if (d_acc_carrier_phase_initialized == false)
|
||||||
|
{
|
||||||
|
double T_rx = static_cast<double>(sample_counter) / trk_parameters.fs_in;
|
||||||
|
d_acc_carrier_phase_rad = -d_rem_carr_phase_rad;
|
||||||
|
d_acc_carrier_phase_initialized = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void dll_pll_veml_tracking::clear_tracking_vars()
|
void dll_pll_veml_tracking::clear_tracking_vars()
|
||||||
{
|
{
|
||||||
std::fill_n(d_correlator_outs.begin(), d_n_correlator_taps, gr_complex(0.0, 0.0));
|
std::fill_n(d_correlator_outs.begin(), d_n_correlator_taps, gr_complex(0.0, 0.0));
|
||||||
@ -1819,6 +1831,7 @@ int dll_pll_veml_tracking::general_work(int noutput_items __attribute__((unused)
|
|||||||
do_correlation_step(in);
|
do_correlation_step(in);
|
||||||
save_correlation_results();
|
save_correlation_results();
|
||||||
|
|
||||||
|
|
||||||
// check lock status
|
// check lock status
|
||||||
if (!cn0_and_tracking_lock_status(d_code_period * static_cast<double>(trk_parameters.extend_correlation_symbols)))
|
if (!cn0_and_tracking_lock_status(d_code_period * static_cast<double>(trk_parameters.extend_correlation_symbols)))
|
||||||
{
|
{
|
||||||
@ -1829,6 +1842,7 @@ int dll_pll_veml_tracking::general_work(int noutput_items __attribute__((unused)
|
|||||||
{
|
{
|
||||||
run_dll_pll();
|
run_dll_pll();
|
||||||
update_tracking_vars();
|
update_tracking_vars();
|
||||||
|
check_carrier_phase_coherent_initialization(d_sample_counter + static_cast<uint64_t>(d_current_prn_length_samples));
|
||||||
if (d_current_data_symbol == 0)
|
if (d_current_data_symbol == 0)
|
||||||
{
|
{
|
||||||
// enable write dump file this cycle (valid DLL/PLL cycle)
|
// enable write dump file this cycle (valid DLL/PLL cycle)
|
||||||
|
@ -78,6 +78,8 @@ private:
|
|||||||
void log_data();
|
void log_data();
|
||||||
int32_t save_matfile();
|
int32_t save_matfile();
|
||||||
|
|
||||||
|
void check_carrier_phase_coherent_initialization(uint64_t sample_counter);
|
||||||
|
|
||||||
// tracking configuration vars
|
// tracking configuration vars
|
||||||
Dll_Pll_Conf trk_parameters;
|
Dll_Pll_Conf trk_parameters;
|
||||||
bool d_veml;
|
bool d_veml;
|
||||||
@ -107,6 +109,7 @@ private:
|
|||||||
boost::circular_buffer<float> d_dll_filt_history;
|
boost::circular_buffer<float> d_dll_filt_history;
|
||||||
// tracking state machine
|
// tracking state machine
|
||||||
int32_t d_state;
|
int32_t d_state;
|
||||||
|
bool d_acc_carrier_phase_initialized;
|
||||||
|
|
||||||
// Integration period in samples
|
// Integration period in samples
|
||||||
int32_t d_correlation_length_ms;
|
int32_t d_correlation_length_ms;
|
||||||
|
Loading…
Reference in New Issue
Block a user