1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-12-14 12:10:34 +00:00

Fixing utc and iono info reading when channel 0 is out of lock

This commit is contained in:
Carles Fernandez 2015-03-03 20:40:14 +01:00
parent 504e96b536
commit 42ea31b677

View File

@ -168,14 +168,40 @@ int gps_l1_ca_pvt_cc::general_work (int noutput_items, gr_vector_int &ninput_ite
if (global_gps_utc_model_map.size() > 0) if (global_gps_utc_model_map.size() > 0)
{ {
// UTC MODEL data is shared for all the GPS satellites. Read always at ID=0 // UTC MODEL data is shared for all the GPS satellites. Read always at a locked channel
global_gps_utc_model_map.read(0, d_ls_pvt->gps_utc_model); int i = 0;
while(true)
{
if (in[i][0].Flag_valid_pseudorange == true)
{
global_gps_utc_model_map.read(i, d_ls_pvt->gps_utc_model);
break;
}
i++;
if (i == d_nchannels - 1)
{
break;
}
}
} }
if (global_gps_iono_map.size() > 0) if (global_gps_iono_map.size() > 0)
{ {
// IONO data is shared for all the GPS satellites. Read always at ID=0 // IONO data is shared for all the GPS satellites. Read always at a locked channel
global_gps_iono_map.read(0, d_ls_pvt->gps_iono); int i = 0;
while(true)
{
if (in[i][0].Flag_valid_pseudorange == true)
{
global_gps_iono_map.read(i, d_ls_pvt->gps_iono);
break;
}
i++;
if (i == d_nchannels - 1)
{
break;
}
}
} }
// update SBAS data collections // update SBAS data collections