mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2025-01-16 12:12:57 +00:00
Cleaning includes
plus some code cleaning
This commit is contained in:
parent
1c3a9f98ee
commit
0a1aa50c4a
@ -30,8 +30,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "galileo_e1_pcps_8ms_ambiguous_acquisition.h"
|
#include "galileo_e1_pcps_8ms_ambiguous_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <string>
|
|
||||||
#include <boost/lexical_cast.hpp>
|
#include <boost/lexical_cast.hpp>
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
@ -68,7 +66,6 @@ GalileoE1Pcps8msAmbiguousAcquisition::GalileoE1Pcps8msAmbiguousAcquisition(
|
|||||||
LOG(WARNING) << "coherent_integration_time should be multiple of "
|
LOG(WARNING) << "coherent_integration_time should be multiple of "
|
||||||
<< "Galileo code length (4 ms). coherent_integration_time = "
|
<< "Galileo code length (4 ms). coherent_integration_time = "
|
||||||
<< sampled_ms_ << " ms will be used.";
|
<< sampled_ms_ << " ms will be used.";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
max_dwells_ = configuration_->property(role + ".max_dwells", 1);
|
max_dwells_ = configuration_->property(role + ".max_dwells", 1);
|
||||||
|
@ -30,7 +30,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "galileo_e1_pcps_ambiguous_acquisition.h"
|
#include "galileo_e1_pcps_ambiguous_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <boost/lexical_cast.hpp>
|
#include <boost/lexical_cast.hpp>
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
|
@ -30,11 +30,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "galileo_e1_pcps_cccwsr_ambiguous_acquisition.h"
|
#include "galileo_e1_pcps_cccwsr_ambiguous_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <boost/lexical_cast.hpp>
|
#include <boost/lexical_cast.hpp>
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <volk/volk.h>
|
|
||||||
#include "galileo_e1_signal_processing.h"
|
#include "galileo_e1_signal_processing.h"
|
||||||
#include "Galileo_E1.h"
|
#include "Galileo_E1.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
|
@ -30,11 +30,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "galileo_e1_pcps_quicksync_ambiguous_acquisition.h"
|
#include "galileo_e1_pcps_quicksync_ambiguous_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <boost/lexical_cast.hpp>
|
#include <boost/lexical_cast.hpp>
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <cmath>
|
|
||||||
#include "galileo_e1_signal_processing.h"
|
#include "galileo_e1_signal_processing.h"
|
||||||
#include "Galileo_E1.h"
|
#include "Galileo_E1.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
|
@ -30,7 +30,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "galileo_e1_pcps_tong_ambiguous_acquisition.h"
|
#include "galileo_e1_pcps_tong_ambiguous_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <boost/lexical_cast.hpp>
|
#include <boost/lexical_cast.hpp>
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
|
@ -36,12 +36,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "galileo_e5a_noncoherent_iq_acquisition_caf.h"
|
#include "galileo_e5a_noncoherent_iq_acquisition_caf.h"
|
||||||
#include <iostream>
|
|
||||||
#include <boost/lexical_cast.hpp>
|
#include <boost/lexical_cast.hpp>
|
||||||
#include <stdexcept>
|
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <gnuradio/msg_queue.h>
|
|
||||||
#include "galileo_e5_signal_processing.h"
|
#include "galileo_e5_signal_processing.h"
|
||||||
#include "Galileo_E5a.h"
|
#include "Galileo_E5a.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
|
@ -60,6 +60,7 @@ public:
|
|||||||
{
|
{
|
||||||
return role_;
|
return role_;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Returns "Galileo_E5a_Noncoherent_IQ_Acquisition_CAF"
|
* \brief Returns "Galileo_E5a_Noncoherent_IQ_Acquisition_CAF"
|
||||||
*/
|
*/
|
||||||
@ -67,6 +68,7 @@ public:
|
|||||||
{
|
{
|
||||||
return "Galileo_E5a_Noncoherent_IQ_Acquisition_CAF";
|
return "Galileo_E5a_Noncoherent_IQ_Acquisition_CAF";
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t item_size()
|
size_t item_size()
|
||||||
{
|
{
|
||||||
return item_size_;
|
return item_size_;
|
||||||
|
@ -34,11 +34,8 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gps_l1_ca_pcps_acquisition.h"
|
#include "gps_l1_ca_pcps_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <stdexcept>
|
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <gnuradio/msg_queue.h>
|
|
||||||
#include "gps_sdr_signal_processing.h"
|
#include "gps_sdr_signal_processing.h"
|
||||||
#include "GPS_L1_CA.h"
|
#include "GPS_L1_CA.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
@ -85,7 +82,7 @@ GpsL1CaPcpsAcquisition::GpsL1CaPcpsAcquisition(
|
|||||||
|
|
||||||
vector_length_ = code_length_ * sampled_ms_;
|
vector_length_ = code_length_ * sampled_ms_;
|
||||||
|
|
||||||
code_= new gr_complex[vector_length_];
|
code_ = new gr_complex[vector_length_];
|
||||||
|
|
||||||
// if (item_type_.compare("gr_complex") == 0 )
|
// if (item_type_.compare("gr_complex") == 0 )
|
||||||
// {
|
// {
|
||||||
@ -274,7 +271,7 @@ float GpsL1CaPcpsAcquisition::calculate_threshold(float pfa)
|
|||||||
{
|
{
|
||||||
frequency_bins++;
|
frequency_bins++;
|
||||||
}
|
}
|
||||||
DLOG(INFO) << "Channel " << channel_<< " Pfa = " << pfa;
|
DLOG(INFO) << "Channel " << channel_ << " Pfa = " << pfa;
|
||||||
unsigned int ncells = vector_length_ * frequency_bins;
|
unsigned int ncells = vector_length_ * frequency_bins;
|
||||||
double exponent = 1 / static_cast<double>(ncells);
|
double exponent = 1 / static_cast<double>(ncells);
|
||||||
double val = pow(1.0 - pfa, exponent);
|
double val = pow(1.0 - pfa, exponent);
|
||||||
@ -310,7 +307,6 @@ void GpsL1CaPcpsAcquisition::connect(gr::top_block_sptr top_block)
|
|||||||
{
|
{
|
||||||
LOG(WARNING) << item_type_ << " unknown acquisition item type";
|
LOG(WARNING) << item_type_ << " unknown acquisition item type";
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -34,7 +34,6 @@
|
|||||||
|
|
||||||
#include "gps_l1_ca_pcps_acquisition_fine_doppler.h"
|
#include "gps_l1_ca_pcps_acquisition_fine_doppler.h"
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <gnuradio/io_signature.h>
|
|
||||||
#include "gps_sdr_signal_processing.h"
|
#include "gps_sdr_signal_processing.h"
|
||||||
#include "GPS_L1_CA.h"
|
#include "GPS_L1_CA.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
@ -53,7 +52,6 @@ GpsL1CaPcpsAcquisitionFineDoppler::GpsL1CaPcpsAcquisitionFineDoppler(
|
|||||||
DLOG(INFO) << "role " << role;
|
DLOG(INFO) << "role " << role;
|
||||||
|
|
||||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||||
|
|
||||||
fs_in_ = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
fs_in_ = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||||
if_ = configuration->property(role + ".ifreq", 0);
|
if_ = configuration->property(role + ".ifreq", 0);
|
||||||
dump_ = configuration->property(role + ".dump", false);
|
dump_ = configuration->property(role + ".dump", false);
|
||||||
@ -67,7 +65,7 @@ GpsL1CaPcpsAcquisitionFineDoppler::GpsL1CaPcpsAcquisitionFineDoppler(
|
|||||||
vector_length_ = round(fs_in_
|
vector_length_ = round(fs_in_
|
||||||
/ (GPS_L1_CA_CODE_RATE_HZ / GPS_L1_CA_CODE_LENGTH_CHIPS));
|
/ (GPS_L1_CA_CODE_RATE_HZ / GPS_L1_CA_CODE_LENGTH_CHIPS));
|
||||||
|
|
||||||
code_= new gr_complex[vector_length_];
|
code_ = new gr_complex[vector_length_];
|
||||||
|
|
||||||
if (item_type_.compare("gr_complex") == 0)
|
if (item_type_.compare("gr_complex") == 0)
|
||||||
{
|
{
|
||||||
@ -75,7 +73,6 @@ GpsL1CaPcpsAcquisitionFineDoppler::GpsL1CaPcpsAcquisitionFineDoppler(
|
|||||||
acquisition_cc_ = pcps_make_acquisition_fine_doppler_cc(max_dwells_,sampled_ms_,
|
acquisition_cc_ = pcps_make_acquisition_fine_doppler_cc(max_dwells_,sampled_ms_,
|
||||||
doppler_max_, doppler_min_, if_, fs_in_, vector_length_, queue_,
|
doppler_max_, doppler_min_, if_, fs_in_, vector_length_, queue_,
|
||||||
dump_, dump_filename_);
|
dump_, dump_filename_);
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -169,7 +166,6 @@ void GpsL1CaPcpsAcquisitionFineDoppler::connect(boost::shared_ptr<gr::top_block>
|
|||||||
{
|
{
|
||||||
if(top_block) { /* top_block is not null */};
|
if(top_block) { /* top_block is not null */};
|
||||||
//nothing to disconnect, now the tracking uses gr_sync_decimator
|
//nothing to disconnect, now the tracking uses gr_sync_decimator
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -33,7 +33,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gps_l1_ca_pcps_assisted_acquisition.h"
|
#include "gps_l1_ca_pcps_assisted_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include "gps_sdr_signal_processing.h"
|
#include "gps_sdr_signal_processing.h"
|
||||||
#include "GPS_L1_CA.h"
|
#include "GPS_L1_CA.h"
|
||||||
@ -54,9 +53,7 @@ GpsL1CaPcpsAssistedAcquisition::GpsL1CaPcpsAssistedAcquisition(
|
|||||||
|
|
||||||
DLOG(INFO) << "role " << role;
|
DLOG(INFO) << "role " << role;
|
||||||
|
|
||||||
item_type_ = configuration->property(role + ".item_type",
|
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||||
default_item_type);
|
|
||||||
|
|
||||||
fs_in_ = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
fs_in_ = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||||
if_ = configuration->property(role + ".ifreq", 0);
|
if_ = configuration->property(role + ".ifreq", 0);
|
||||||
dump_ = configuration->property(role + ".dump", false);
|
dump_ = configuration->property(role + ".dump", false);
|
||||||
@ -64,14 +61,13 @@ GpsL1CaPcpsAssistedAcquisition::GpsL1CaPcpsAssistedAcquisition(
|
|||||||
doppler_min_ = configuration->property(role + ".doppler_min", -5000);
|
doppler_min_ = configuration->property(role + ".doppler_min", -5000);
|
||||||
sampled_ms_ = configuration->property(role + ".coherent_integration_time_ms", 1);
|
sampled_ms_ = configuration->property(role + ".coherent_integration_time_ms", 1);
|
||||||
max_dwells_= configuration->property(role + ".max_dwells", 1);
|
max_dwells_= configuration->property(role + ".max_dwells", 1);
|
||||||
dump_filename_ = configuration->property(role + ".dump_filename",
|
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_filename);
|
||||||
default_dump_filename);
|
|
||||||
|
|
||||||
//--- Find number of samples per spreading code -------------------------
|
//--- Find number of samples per spreading code -------------------------
|
||||||
vector_length_ = round(fs_in_
|
vector_length_ = round(fs_in_
|
||||||
/ (GPS_L1_CA_CODE_RATE_HZ / GPS_L1_CA_CODE_LENGTH_CHIPS));
|
/ (GPS_L1_CA_CODE_RATE_HZ / GPS_L1_CA_CODE_LENGTH_CHIPS));
|
||||||
|
|
||||||
code_= new gr_complex[vector_length_];
|
code_ = new gr_complex[vector_length_];
|
||||||
|
|
||||||
if (item_type_.compare("gr_complex") == 0)
|
if (item_type_.compare("gr_complex") == 0)
|
||||||
{
|
{
|
||||||
|
@ -30,11 +30,8 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gps_l1_ca_pcps_multithread_acquisition.h"
|
#include "gps_l1_ca_pcps_multithread_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <stdexcept>
|
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <gnuradio/msg_queue.h>
|
|
||||||
#include "gps_sdr_signal_processing.h"
|
#include "gps_sdr_signal_processing.h"
|
||||||
#include "GPS_L1_CA.h"
|
#include "GPS_L1_CA.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
@ -83,7 +80,7 @@ GpsL1CaPcpsMultithreadAcquisition::GpsL1CaPcpsMultithreadAcquisition(
|
|||||||
|
|
||||||
vector_length_ = code_length_ * sampled_ms_;
|
vector_length_ = code_length_ * sampled_ms_;
|
||||||
|
|
||||||
code_= new gr_complex[vector_length_];
|
code_ = new gr_complex[vector_length_];
|
||||||
|
|
||||||
if (item_type_.compare("gr_complex") == 0)
|
if (item_type_.compare("gr_complex") == 0)
|
||||||
{
|
{
|
||||||
|
@ -30,11 +30,8 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gps_l1_ca_pcps_opencl_acquisition.h"
|
#include "gps_l1_ca_pcps_opencl_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <stdexcept>
|
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <gnuradio/msg_queue.h>
|
|
||||||
#include "gps_sdr_signal_processing.h"
|
#include "gps_sdr_signal_processing.h"
|
||||||
#include "GPS_L1_CA.h"
|
#include "GPS_L1_CA.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
|
@ -31,12 +31,8 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gps_l1_ca_pcps_quicksync_acquisition.h"
|
#include "gps_l1_ca_pcps_quicksync_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <cmath>
|
|
||||||
#include <stdexcept>
|
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <gnuradio/msg_queue.h>
|
|
||||||
#include "gps_sdr_signal_processing.h"
|
#include "gps_sdr_signal_processing.h"
|
||||||
#include "GPS_L1_CA.h"
|
#include "GPS_L1_CA.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
@ -179,7 +175,7 @@ void GpsL1CaPcpsQuickSyncAcquisition::set_threshold(float threshold)
|
|||||||
threshold_ = calculate_threshold(pfa);
|
threshold_ = calculate_threshold(pfa);
|
||||||
}
|
}
|
||||||
|
|
||||||
DLOG(INFO) <<"Channel "<<channel_<<" Threshold = " << threshold_;
|
DLOG(INFO) << "Channel "<< channel_ << " Threshold = " << threshold_;
|
||||||
|
|
||||||
if (item_type_.compare("gr_complex") == 0)
|
if (item_type_.compare("gr_complex") == 0)
|
||||||
{
|
{
|
||||||
@ -205,7 +201,6 @@ void GpsL1CaPcpsQuickSyncAcquisition::set_doppler_step(unsigned int doppler_step
|
|||||||
{
|
{
|
||||||
acquisition_cc_->set_doppler_step(doppler_step_);
|
acquisition_cc_->set_doppler_step(doppler_step_);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -30,11 +30,8 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gps_l1_ca_pcps_tong_acquisition.h"
|
#include "gps_l1_ca_pcps_tong_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <stdexcept>
|
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <gnuradio/msg_queue.h>
|
|
||||||
#include "gps_sdr_signal_processing.h"
|
#include "gps_sdr_signal_processing.h"
|
||||||
#include "GPS_L1_CA.h"
|
#include "GPS_L1_CA.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
@ -54,8 +51,7 @@ GpsL1CaPcpsTongAcquisition::GpsL1CaPcpsTongAcquisition(
|
|||||||
|
|
||||||
DLOG(INFO) << "role " << role;
|
DLOG(INFO) << "role " << role;
|
||||||
|
|
||||||
item_type_ = configuration_->property(role + ".item_type",
|
item_type_ = configuration_->property(role + ".item_type", default_item_type);
|
||||||
default_item_type);
|
|
||||||
|
|
||||||
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_hz", 2048000);
|
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||||
if_ = configuration_->property(role + ".ifreq", 0);
|
if_ = configuration_->property(role + ".ifreq", 0);
|
||||||
@ -66,8 +62,7 @@ GpsL1CaPcpsTongAcquisition::GpsL1CaPcpsTongAcquisition(
|
|||||||
tong_init_val_ = configuration->property(role + ".tong_init_val", 1);
|
tong_init_val_ = configuration->property(role + ".tong_init_val", 1);
|
||||||
tong_max_val_ = configuration->property(role + ".tong_max_val", 2);
|
tong_max_val_ = configuration->property(role + ".tong_max_val", 2);
|
||||||
|
|
||||||
dump_filename_ = configuration_->property(role + ".dump_filename",
|
dump_filename_ = configuration_->property(role + ".dump_filename", default_dump_filename);
|
||||||
default_dump_filename);
|
|
||||||
|
|
||||||
//--- Find number of samples per spreading code -------------------------
|
//--- Find number of samples per spreading code -------------------------
|
||||||
code_length_ = round(fs_in_
|
code_length_ = round(fs_in_
|
||||||
@ -75,7 +70,7 @@ GpsL1CaPcpsTongAcquisition::GpsL1CaPcpsTongAcquisition(
|
|||||||
|
|
||||||
vector_length_ = code_length_ * sampled_ms_;
|
vector_length_ = code_length_ * sampled_ms_;
|
||||||
|
|
||||||
code_= new gr_complex[vector_length_];
|
code_ = new gr_complex[vector_length_];
|
||||||
|
|
||||||
if (item_type_.compare("gr_complex") == 0)
|
if (item_type_.compare("gr_complex") == 0)
|
||||||
{
|
{
|
||||||
@ -86,10 +81,8 @@ GpsL1CaPcpsTongAcquisition::GpsL1CaPcpsTongAcquisition(
|
|||||||
|
|
||||||
stream_to_vector_ = gr::blocks::stream_to_vector::make(item_size_, vector_length_);
|
stream_to_vector_ = gr::blocks::stream_to_vector::make(item_size_, vector_length_);
|
||||||
|
|
||||||
DLOG(INFO) << "stream_to_vector(" << stream_to_vector_->unique_id()
|
DLOG(INFO) << "stream_to_vector(" << stream_to_vector_->unique_id() << ")";
|
||||||
<< ")";
|
DLOG(INFO) << "acquisition(" << acquisition_cc_->unique_id() << ")";
|
||||||
DLOG(INFO) << "acquisition(" << acquisition_cc_->unique_id()
|
|
||||||
<< ")";
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -127,11 +120,11 @@ void GpsL1CaPcpsTongAcquisition::set_threshold(float threshold)
|
|||||||
{
|
{
|
||||||
float pfa = configuration_->property(role_ + boost::lexical_cast<std::string>(channel_) + ".pfa", 0.0);
|
float pfa = configuration_->property(role_ + boost::lexical_cast<std::string>(channel_) + ".pfa", 0.0);
|
||||||
|
|
||||||
if(pfa==0.0)
|
if(pfa == 0.0)
|
||||||
{
|
{
|
||||||
pfa = configuration_->property(role_+".pfa", 0.0);
|
pfa = configuration_->property(role_+".pfa", 0.0);
|
||||||
}
|
}
|
||||||
if(pfa==0.0)
|
if(pfa == 0.0)
|
||||||
{
|
{
|
||||||
threshold_ = threshold;
|
threshold_ = threshold;
|
||||||
}
|
}
|
||||||
@ -140,7 +133,7 @@ void GpsL1CaPcpsTongAcquisition::set_threshold(float threshold)
|
|||||||
threshold_ = calculate_threshold(pfa);
|
threshold_ = calculate_threshold(pfa);
|
||||||
}
|
}
|
||||||
|
|
||||||
DLOG(INFO) <<"Channel "<<channel_<<" Threshold = " << threshold_;
|
DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold_;
|
||||||
|
|
||||||
if (item_type_.compare("gr_complex") == 0)
|
if (item_type_.compare("gr_complex") == 0)
|
||||||
{
|
{
|
||||||
@ -230,6 +223,7 @@ void GpsL1CaPcpsTongAcquisition::set_local_code()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void GpsL1CaPcpsTongAcquisition::reset()
|
void GpsL1CaPcpsTongAcquisition::reset()
|
||||||
{
|
{
|
||||||
if (item_type_.compare("gr_complex") == 0)
|
if (item_type_.compare("gr_complex") == 0)
|
||||||
@ -238,6 +232,7 @@ void GpsL1CaPcpsTongAcquisition::reset()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void GpsL1CaPcpsTongAcquisition::set_state(int state)
|
void GpsL1CaPcpsTongAcquisition::set_state(int state)
|
||||||
{
|
{
|
||||||
if (item_type_.compare("gr_complex") == 0)
|
if (item_type_.compare("gr_complex") == 0)
|
||||||
@ -246,10 +241,10 @@ void GpsL1CaPcpsTongAcquisition::set_state(int state)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
float GpsL1CaPcpsTongAcquisition::calculate_threshold(float pfa)
|
float GpsL1CaPcpsTongAcquisition::calculate_threshold(float pfa)
|
||||||
{
|
{
|
||||||
//Calculate the threshold
|
//Calculate the threshold
|
||||||
|
|
||||||
unsigned int frequency_bins = 0;
|
unsigned int frequency_bins = 0;
|
||||||
for (int doppler = (int)(-doppler_max_); doppler <= (int)doppler_max_; doppler += doppler_step_)
|
for (int doppler = (int)(-doppler_max_); doppler <= (int)doppler_max_; doppler += doppler_step_)
|
||||||
{
|
{
|
||||||
@ -268,6 +263,7 @@ float GpsL1CaPcpsTongAcquisition::calculate_threshold(float pfa)
|
|||||||
return threshold;
|
return threshold;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void GpsL1CaPcpsTongAcquisition::connect(gr::top_block_sptr top_block)
|
void GpsL1CaPcpsTongAcquisition::connect(gr::top_block_sptr top_block)
|
||||||
{
|
{
|
||||||
if (item_type_.compare("gr_complex") == 0)
|
if (item_type_.compare("gr_complex") == 0)
|
||||||
|
@ -32,12 +32,8 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gps_l2_m_pcps_acquisition.h"
|
#include "gps_l2_m_pcps_acquisition.h"
|
||||||
#include <iostream>
|
|
||||||
#include <fstream>
|
|
||||||
#include <stdexcept>
|
|
||||||
#include <boost/math/distributions/exponential.hpp>
|
#include <boost/math/distributions/exponential.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <gnuradio/msg_queue.h>
|
|
||||||
#include "gps_l2c_signal.h"
|
#include "gps_l2c_signal.h"
|
||||||
#include "GPS_L2C.h"
|
#include "GPS_L2C.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
@ -57,8 +53,7 @@ GpsL2MPcpsAcquisition::GpsL2MPcpsAcquisition(
|
|||||||
|
|
||||||
LOG(INFO) << "role " << role;
|
LOG(INFO) << "role " << role;
|
||||||
|
|
||||||
item_type_ = configuration_->property(role + ".item_type",
|
item_type_ = configuration_->property(role + ".item_type", default_item_type);
|
||||||
default_item_type);
|
|
||||||
//float pfa = configuration_->property(role + ".pfa", 0.0);
|
//float pfa = configuration_->property(role + ".pfa", 0.0);
|
||||||
|
|
||||||
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_hz", 2048000);
|
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||||
@ -77,16 +72,15 @@ GpsL2MPcpsAcquisition::GpsL2MPcpsAcquisition(
|
|||||||
max_dwells_ = 2;
|
max_dwells_ = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
dump_filename_ = configuration_->property(role + ".dump_filename",
|
dump_filename_ = configuration_->property(role + ".dump_filename", default_dump_filename);
|
||||||
default_dump_filename);
|
|
||||||
|
|
||||||
//--- Find number of samples per spreading code -------------------------
|
//--- Find number of samples per spreading code -------------------------
|
||||||
code_length_ = round((double)fs_in_
|
code_length_ = round(static_cast<double>(fs_in_)
|
||||||
/ (GPS_L2_M_CODE_RATE_HZ / (double)GPS_L2_M_CODE_LENGTH_CHIPS));
|
/ (GPS_L2_M_CODE_RATE_HZ / static_cast<double>(GPS_L2_M_CODE_LENGTH_CHIPS)));
|
||||||
|
|
||||||
vector_length_ = code_length_;
|
vector_length_ = code_length_;
|
||||||
|
|
||||||
code_= new gr_complex[vector_length_];
|
code_ = new gr_complex[vector_length_];
|
||||||
|
|
||||||
// if (item_type_.compare("gr_complex") == 0 )
|
// if (item_type_.compare("gr_complex") == 0 )
|
||||||
// {
|
// {
|
||||||
@ -161,7 +155,7 @@ void GpsL2MPcpsAcquisition::set_threshold(float threshold)
|
|||||||
threshold_ = calculate_threshold(pfa);
|
threshold_ = calculate_threshold(pfa);
|
||||||
}
|
}
|
||||||
|
|
||||||
DLOG(INFO) <<"Channel "<<channel_<<" Threshold = " << threshold_;
|
DLOG(INFO) << "Channel " << channel_ <<" Threshold = " << threshold_;
|
||||||
|
|
||||||
// if (item_type_.compare("gr_complex") == 0)
|
// if (item_type_.compare("gr_complex") == 0)
|
||||||
// {
|
// {
|
||||||
@ -277,13 +271,13 @@ float GpsL2MPcpsAcquisition::calculate_threshold(float pfa)
|
|||||||
{
|
{
|
||||||
//Calculate the threshold
|
//Calculate the threshold
|
||||||
unsigned int frequency_bins = 0;
|
unsigned int frequency_bins = 0;
|
||||||
for (int doppler = (int)(-doppler_max_); doppler <= (int)doppler_max_; doppler += doppler_step_)
|
for (int doppler = static_cast<int>(-doppler_max_); doppler <= static_cast<int>(doppler_max_); doppler += doppler_step_)
|
||||||
{
|
{
|
||||||
frequency_bins++;
|
frequency_bins++;
|
||||||
}
|
}
|
||||||
DLOG(INFO) << "Channel " << channel_<< " Pfa = " << pfa;
|
DLOG(INFO) << "Channel " << channel_<< " Pfa = " << pfa;
|
||||||
unsigned int ncells = vector_length_ * frequency_bins;
|
unsigned int ncells = vector_length_ * frequency_bins;
|
||||||
double exponent = 1 / static_cast<double>(ncells);
|
double exponent = 1.0 / static_cast<double>(ncells);
|
||||||
double val = pow(1.0 - pfa, exponent);
|
double val = pow(1.0 - pfa, exponent);
|
||||||
double lambda = double(vector_length_);
|
double lambda = double(vector_length_);
|
||||||
boost::math::exponential_distribution<double> mydist (lambda);
|
boost::math::exponential_distribution<double> mydist (lambda);
|
||||||
|
@ -52,8 +52,6 @@
|
|||||||
|
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
#include <string>
|
#include <string>
|
||||||
#include <boost/thread/mutex.hpp>
|
|
||||||
#include <boost/thread/thread.hpp>
|
|
||||||
#include <gnuradio/block.h>
|
#include <gnuradio/block.h>
|
||||||
#include <gnuradio/msg_queue.h>
|
#include <gnuradio/msg_queue.h>
|
||||||
#include <gnuradio/gr_complex.h>
|
#include <gnuradio/gr_complex.h>
|
||||||
@ -225,7 +223,6 @@ public:
|
|||||||
d_doppler_step = doppler_step;
|
d_doppler_step = doppler_step;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Set tracking channel internal queue.
|
* \brief Set tracking channel internal queue.
|
||||||
* \param channel_internal_queue - Channel's internal blocks information queue.
|
* \param channel_internal_queue - Channel's internal blocks information queue.
|
||||||
|
@ -51,9 +51,7 @@ class ConfigurationInterface;
|
|||||||
*/
|
*/
|
||||||
class GalileoE1DllPllVemlTracking : public TrackingInterface
|
class GalileoE1DllPllVemlTracking : public TrackingInterface
|
||||||
{
|
{
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
GalileoE1DllPllVemlTracking(ConfigurationInterface* configuration,
|
GalileoE1DllPllVemlTracking(ConfigurationInterface* configuration,
|
||||||
std::string role,
|
std::string role,
|
||||||
unsigned int in_streams,
|
unsigned int in_streams,
|
||||||
@ -103,12 +101,9 @@ public:
|
|||||||
void start_tracking();
|
void start_tracking();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
galileo_e1_dll_pll_veml_tracking_cc_sptr tracking_;
|
galileo_e1_dll_pll_veml_tracking_cc_sptr tracking_;
|
||||||
size_t item_size_;
|
size_t item_size_;
|
||||||
|
|
||||||
unsigned int channel_;
|
unsigned int channel_;
|
||||||
|
|
||||||
std::string role_;
|
std::string role_;
|
||||||
unsigned int in_streams_;
|
unsigned int in_streams_;
|
||||||
unsigned int out_streams_;
|
unsigned int out_streams_;
|
||||||
|
@ -52,9 +52,7 @@ class ConfigurationInterface;
|
|||||||
*/
|
*/
|
||||||
class GalileoE1TcpConnectorTracking : public TrackingInterface
|
class GalileoE1TcpConnectorTracking : public TrackingInterface
|
||||||
{
|
{
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
GalileoE1TcpConnectorTracking(ConfigurationInterface* configuration,
|
GalileoE1TcpConnectorTracking(ConfigurationInterface* configuration,
|
||||||
std::string role,
|
std::string role,
|
||||||
unsigned int in_streams,
|
unsigned int in_streams,
|
||||||
@ -67,6 +65,7 @@ public:
|
|||||||
{
|
{
|
||||||
return role_;
|
return role_;
|
||||||
}
|
}
|
||||||
|
|
||||||
//! Returns "Galileo_E1_TCP_CONNECTOR_Tracking"
|
//! Returns "Galileo_E1_TCP_CONNECTOR_Tracking"
|
||||||
std::string implementation()
|
std::string implementation()
|
||||||
{
|
{
|
||||||
@ -103,12 +102,9 @@ public:
|
|||||||
void start_tracking();
|
void start_tracking();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
galileo_e1_tcp_connector_tracking_cc_sptr tracking_;
|
galileo_e1_tcp_connector_tracking_cc_sptr tracking_;
|
||||||
size_t item_size_;
|
size_t item_size_;
|
||||||
|
|
||||||
unsigned int channel_;
|
unsigned int channel_;
|
||||||
|
|
||||||
std::string role_;
|
std::string role_;
|
||||||
unsigned int in_streams_;
|
unsigned int in_streams_;
|
||||||
unsigned int out_streams_;
|
unsigned int out_streams_;
|
||||||
|
@ -53,7 +53,6 @@ class ConfigurationInterface;
|
|||||||
class GalileoE5aDllPllTracking : public TrackingInterface
|
class GalileoE5aDllPllTracking : public TrackingInterface
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
GalileoE5aDllPllTracking(ConfigurationInterface* configuration,
|
GalileoE5aDllPllTracking(ConfigurationInterface* configuration,
|
||||||
std::string role,
|
std::string role,
|
||||||
unsigned int in_streams,
|
unsigned int in_streams,
|
||||||
@ -82,7 +81,6 @@ public:
|
|||||||
gr::basic_block_sptr get_left_block();
|
gr::basic_block_sptr get_left_block();
|
||||||
gr::basic_block_sptr get_right_block();
|
gr::basic_block_sptr get_right_block();
|
||||||
|
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief Set tracking channel unique ID
|
* \brief Set tracking channel unique ID
|
||||||
*/
|
*/
|
||||||
|
@ -51,9 +51,7 @@ class ConfigurationInterface;
|
|||||||
*/
|
*/
|
||||||
class GalileoVolkE1DllPllVemlTracking : public TrackingInterface
|
class GalileoVolkE1DllPllVemlTracking : public TrackingInterface
|
||||||
{
|
{
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
||||||
GalileoVolkE1DllPllVemlTracking(ConfigurationInterface* configuration,
|
GalileoVolkE1DllPllVemlTracking(ConfigurationInterface* configuration,
|
||||||
std::string role,
|
std::string role,
|
||||||
unsigned int in_streams,
|
unsigned int in_streams,
|
||||||
@ -103,12 +101,9 @@ public:
|
|||||||
void start_tracking();
|
void start_tracking();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
galileo_volk_e1_dll_pll_veml_tracking_cc_sptr tracking_;
|
galileo_volk_e1_dll_pll_veml_tracking_cc_sptr tracking_;
|
||||||
size_t item_size_;
|
size_t item_size_;
|
||||||
|
|
||||||
unsigned int channel_;
|
unsigned int channel_;
|
||||||
|
|
||||||
std::string role_;
|
std::string role_;
|
||||||
unsigned int in_streams_;
|
unsigned int in_streams_;
|
||||||
unsigned int out_streams_;
|
unsigned int out_streams_;
|
||||||
|
@ -37,8 +37,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "gps_l1_ca_dll_pll_optim_tracking.h"
|
#include "gps_l1_ca_dll_pll_optim_tracking.h"
|
||||||
#include <boost/math/special_functions/round.hpp>
|
#include <cmath>
|
||||||
#include <gnuradio/io_signature.h>
|
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include "GPS_L1_CA.h"
|
#include "GPS_L1_CA.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
|
@ -64,7 +64,6 @@ GpsL1CaDllPllTracking::GpsL1CaDllPllTracking(
|
|||||||
float dll_bw_hz;
|
float dll_bw_hz;
|
||||||
float early_late_space_chips;
|
float early_late_space_chips;
|
||||||
item_type = configuration->property(role + ".item_type", default_item_type);
|
item_type = configuration->property(role + ".item_type", default_item_type);
|
||||||
//vector_length = configuration->property(role + ".vector_length", 2048);
|
|
||||||
fs_in = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
fs_in = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||||
f_if = configuration->property(role + ".if", 0);
|
f_if = configuration->property(role + ".if", 0);
|
||||||
dump = configuration->property(role + ".dump", false);
|
dump = configuration->property(role + ".dump", false);
|
||||||
@ -72,8 +71,7 @@ GpsL1CaDllPllTracking::GpsL1CaDllPllTracking(
|
|||||||
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
|
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
|
||||||
early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.5);
|
early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.5);
|
||||||
std::string default_dump_filename = "./track_ch";
|
std::string default_dump_filename = "./track_ch";
|
||||||
dump_filename = configuration->property(role + ".dump_filename",
|
dump_filename = configuration->property(role + ".dump_filename", default_dump_filename); //unused!
|
||||||
default_dump_filename); //unused!
|
|
||||||
vector_length = std::round(fs_in / (GPS_L1_CA_CODE_RATE_HZ / GPS_L1_CA_CODE_LENGTH_CHIPS));
|
vector_length = std::round(fs_in / (GPS_L1_CA_CODE_RATE_HZ / GPS_L1_CA_CODE_LENGTH_CHIPS));
|
||||||
|
|
||||||
//################# MAKE TRACKING GNURadio object ###################
|
//################# MAKE TRACKING GNURadio object ###################
|
||||||
@ -111,6 +109,7 @@ void GpsL1CaDllPllTracking::start_tracking()
|
|||||||
tracking_->start_tracking();
|
tracking_->start_tracking();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Set tracking channel unique ID
|
* Set tracking channel unique ID
|
||||||
*/
|
*/
|
||||||
@ -120,6 +119,7 @@ void GpsL1CaDllPllTracking::set_channel(unsigned int channel)
|
|||||||
tracking_->set_channel(channel);
|
tracking_->set_channel(channel);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Set tracking channel internal queue
|
* Set tracking channel internal queue
|
||||||
*/
|
*/
|
||||||
@ -130,28 +130,33 @@ void GpsL1CaDllPllTracking::set_channel_queue(
|
|||||||
tracking_->set_channel_queue(channel_internal_queue_);
|
tracking_->set_channel_queue(channel_internal_queue_);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void GpsL1CaDllPllTracking::set_gnss_synchro(Gnss_Synchro* p_gnss_synchro)
|
void GpsL1CaDllPllTracking::set_gnss_synchro(Gnss_Synchro* p_gnss_synchro)
|
||||||
{
|
{
|
||||||
tracking_->set_gnss_synchro(p_gnss_synchro);
|
tracking_->set_gnss_synchro(p_gnss_synchro);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void GpsL1CaDllPllTracking::connect(gr::top_block_sptr top_block)
|
void GpsL1CaDllPllTracking::connect(gr::top_block_sptr top_block)
|
||||||
{
|
{
|
||||||
if(top_block) { /* top_block is not null */};
|
if(top_block) { /* top_block is not null */};
|
||||||
//nothing to connect, now the tracking uses gr_sync_decimator
|
//nothing to connect, now the tracking uses gr_sync_decimator
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void GpsL1CaDllPllTracking::disconnect(gr::top_block_sptr top_block)
|
void GpsL1CaDllPllTracking::disconnect(gr::top_block_sptr top_block)
|
||||||
{
|
{
|
||||||
if(top_block) { /* top_block is not null */};
|
if(top_block) { /* top_block is not null */};
|
||||||
//nothing to disconnect, now the tracking uses gr_sync_decimator
|
//nothing to disconnect, now the tracking uses gr_sync_decimator
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
gr::basic_block_sptr GpsL1CaDllPllTracking::get_left_block()
|
gr::basic_block_sptr GpsL1CaDllPllTracking::get_left_block()
|
||||||
{
|
{
|
||||||
return tracking_;
|
return tracking_;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
gr::basic_block_sptr GpsL1CaDllPllTracking::get_right_block()
|
gr::basic_block_sptr GpsL1CaDllPllTracking::get_right_block()
|
||||||
{
|
{
|
||||||
return tracking_;
|
return tracking_;
|
||||||
|
@ -52,7 +52,6 @@ class ConfigurationInterface;
|
|||||||
class GpsL1CaDllPllTracking : public TrackingInterface
|
class GpsL1CaDllPllTracking : public TrackingInterface
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
GpsL1CaDllPllTracking(ConfigurationInterface* configuration,
|
GpsL1CaDllPllTracking(ConfigurationInterface* configuration,
|
||||||
std::string role,
|
std::string role,
|
||||||
unsigned int in_streams,
|
unsigned int in_streams,
|
||||||
@ -71,6 +70,7 @@ public:
|
|||||||
{
|
{
|
||||||
return "GPS_L1_CA_DLL_PLL_Tracking";
|
return "GPS_L1_CA_DLL_PLL_Tracking";
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t item_size()
|
size_t item_size()
|
||||||
{
|
{
|
||||||
return item_size_;
|
return item_size_;
|
||||||
|
@ -52,7 +52,6 @@ class ConfigurationInterface;
|
|||||||
class GpsL2MDllPllTracking : public TrackingInterface
|
class GpsL2MDllPllTracking : public TrackingInterface
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
GpsL2MDllPllTracking(ConfigurationInterface* configuration,
|
GpsL2MDllPllTracking(ConfigurationInterface* configuration,
|
||||||
std::string role,
|
std::string role,
|
||||||
unsigned int in_streams,
|
unsigned int in_streams,
|
||||||
@ -71,6 +70,7 @@ public:
|
|||||||
{
|
{
|
||||||
return "gps_l2_m_dll_pll_tracking";
|
return "gps_l2_m_dll_pll_tracking";
|
||||||
}
|
}
|
||||||
|
|
||||||
size_t item_size()
|
size_t item_size()
|
||||||
{
|
{
|
||||||
return item_size_;
|
return item_size_;
|
||||||
|
Loading…
Reference in New Issue
Block a user