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

Add FDMA protocol to pcps algorithm

This commit is contained in:
Gastd 2017-06-05 20:22:46 -03:00
parent eec6f07f1d
commit 88a0976f96
2 changed files with 19 additions and 6 deletions

View File

@ -188,6 +188,21 @@ void pcps_acquisition_cc::set_local_code(std::complex<float> * code)
volk_32fc_conjugate_32fc(d_fft_codes, d_fft_if->get_outbuf(), d_fft_size);
}
bool pcps_acquisition_cc::is_fdma()
{
// Dealing with FDMA system
if( strcmp(d_gnss_synchro->Signal,"1G") == 0 )
{
d_freq += DFRQ1_GLO * GLONASS_PRN.at(d_gnss_synchro->PRN);
LOG(INFO) << "Trying to acquire SV PRN " << d_gnss_synchro->PRN << " with freq " << DFRQ1_GLO * GLONASS_PRN.at(d_gnss_synchro->PRN) << " in Channel " << GLONASS_PRN.at(d_gnss_synchro->PRN) << std::endl;
return true;
}
else
{
return false;
}
}
bool pcps_acquisition_cc::is_fdma()
{
@ -228,7 +243,10 @@ void pcps_acquisition_cc::init()
d_input_power = 0.0;
d_num_doppler_bins = ceil( static_cast<double>(static_cast<int>(d_doppler_max) - static_cast<int>(-d_doppler_max)) / static_cast<double>(d_doppler_step));
}
void pcps_acquisition_cc::update_grid_doppler_wipeoffs()
{
// Create the carrier Doppler wipeoff signals
d_grid_doppler_wipeoffs = new gr_complex*[d_num_doppler_bins];
@ -255,6 +273,7 @@ void pcps_acquisition_cc::update_grid_doppler_wipeoffs()
void pcps_acquisition_cc::set_state(int state)
{
gr::thread::scoped_lock lock(d_setlock); // require mutex with work function called by the scheduler

View File

@ -151,12 +151,6 @@ public:
{
gr::thread::scoped_lock lock(d_setlock); // require mutex with work function called by the scheduler
d_gnss_synchro = p_gnss_synchro;
// Dealing with FDMA system
if(d_gnss_synchro->System == 'R')
{
d_freq += 0.5625e6 * GLONASS_PRN[d_gnss_synchro->PRN+1];
std::cout << "d_freq " << d_freq << std::endl;
}
}
/*!