Files
gnss-sdr/utils/matlab
ObvMamut a81888f2ae Write the accumulated carrier phase as double in tracking dumps
log_data() in dll_pll_veml_tracking and dll_pll_veml_tracking_fpga casts
d_acc_carrier_phase_rad, a double, to float before writing it to the
binary dump, and save_matfile() reads it back as a float. The
accumulated phase grows by 2*pi times the Doppler shift every second
(about 31400 rad/s at 5 kHz), so it reaches 1e6 rad after about 30 s of
tracking at 5 kHz, or under 3 minutes at 1 kHz. The float spacing is
0.0625 rad at 1e6 rad, 0.25 rad at 3e6 rad and 1 rad at 1e7 rad. At
3e6 rad, for instance, the phase difference between two 1 ms epochs of
the dump is only known to within +/-0.25 rad, about 40 Hz in frequency
terms. The phase used by the receiver (Gnss_Synchro::Carrier_phase_rads)
is a double and is not affected; only the dump is.

Write the field as a double, and read it back as a double in
save_matfile(), so that the .mat file also holds a double.

This changes the dump record layout. The field keeps its position but
grows from 4 to 8 bytes, so a record is now 112 bytes long in
dll_pll_veml_tracking (it was 108) and 100 bytes long in
dll_pll_veml_tracking_fpga (it was 96). The readers of this format are
updated accordingly: Tracking_Dump_Reader, used by the unit tests, and
dll_pll_veml_read_tracking_dump in utils/matlab and utils/python.

Signed-off-by: ObvMamut <obvmamut@proton.me>
2026-10-20 14:17:46 +02:00
..