mirror of
				https://github.com/gnss-sdr/gnss-sdr
				synced 2025-11-04 09:13:05 +00:00 
			
		
		
		
	Reducing the latency in the acquisition to tracking transition
This commit is contained in:
		@@ -98,6 +98,7 @@ target_link_libraries(acquisition_adapters
 | 
				
			|||||||
        algorithms_libs
 | 
					        algorithms_libs
 | 
				
			||||||
        gnss_sdr_flags
 | 
					        gnss_sdr_flags
 | 
				
			||||||
        acquisition_gr_blocks
 | 
					        acquisition_gr_blocks
 | 
				
			||||||
 | 
					        channel_libs
 | 
				
			||||||
        core_system_parameters
 | 
					        core_system_parameters
 | 
				
			||||||
        Gnuradio::blocks
 | 
					        Gnuradio::blocks
 | 
				
			||||||
        Volk::volk
 | 
					        Volk::volk
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -124,6 +124,7 @@ BeidouB1iPcpsAcquisition::BeidouB1iPcpsAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -145,12 +146,6 @@ void BeidouB1iPcpsAcquisition::stop_acquisition()
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void BeidouB1iPcpsAcquisition::set_channel(uint32_t channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
void BeidouB1iPcpsAcquisition::set_threshold(float threshold)
 | 
					void BeidouB1iPcpsAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -34,7 +34,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_BEIDOU_B1I_PCPS_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_BEIDOU_B1I_PCPS_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_BEIDOU_B1I_PCPS_ACQUISITION_H_
 | 
					#define GNSS_SDR_BEIDOU_B1I_PCPS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition.h"
 | 
					#include "pcps_acquisition.h"
 | 
				
			||||||
@@ -93,7 +93,21 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(uint32_t channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
@@ -159,6 +173,7 @@ private:
 | 
				
			|||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    bool use_CFAR_algorithm_flag_;
 | 
					    bool use_CFAR_algorithm_flag_;
 | 
				
			||||||
    uint32_t channel_;
 | 
					    uint32_t channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    uint32_t doppler_max_;
 | 
					    uint32_t doppler_max_;
 | 
				
			||||||
    uint32_t doppler_step_;
 | 
					    uint32_t doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -121,6 +121,7 @@ BeidouB3iPcpsAcquisition::BeidouB3iPcpsAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -142,13 +143,6 @@ void BeidouB3iPcpsAcquisition::stop_acquisition()
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void BeidouB3iPcpsAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void BeidouB3iPcpsAcquisition::set_threshold(float threshold)
 | 
					void BeidouB3iPcpsAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,7 +33,7 @@
 | 
				
			|||||||
#define GNSS_SDR_BEIDOU_B3I_PCPS_ACQUISITION_H_
 | 
					#define GNSS_SDR_BEIDOU_B3I_PCPS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acq_conf.h"
 | 
					#include "acq_conf.h"
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition.h"
 | 
					#include "pcps_acquisition.h"
 | 
				
			||||||
@@ -92,7 +92,21 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
@@ -158,6 +172,7 @@ private:
 | 
				
			|||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    bool use_CFAR_algorithm_flag_;
 | 
					    bool use_CFAR_algorithm_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -110,6 +110,7 @@ GalileoE1Pcps8msAmbiguousAcquisition::GalileoE1Pcps8msAmbiguousAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -132,16 +133,6 @@ void GalileoE1Pcps8msAmbiguousAcquisition::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GalileoE1Pcps8msAmbiguousAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    if (item_type_ == "gr_complex")
 | 
					 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
            acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE1Pcps8msAmbiguousAcquisition::set_threshold(float threshold)
 | 
					void GalileoE1Pcps8msAmbiguousAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -87,7 +87,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
@@ -143,6 +156,7 @@ private:
 | 
				
			|||||||
    unsigned int vector_length_;
 | 
					    unsigned int vector_length_;
 | 
				
			||||||
    unsigned int code_length_;
 | 
					    unsigned int code_length_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -154,6 +154,7 @@ GalileoE1PcpsAmbiguousAcquisition::GalileoE1PcpsAmbiguousAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -175,14 +176,6 @@ void GalileoE1PcpsAmbiguousAcquisition::stop_acquisition()
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE1PcpsAmbiguousAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE1PcpsAmbiguousAcquisition::set_threshold(float threshold)
 | 
					void GalileoE1PcpsAmbiguousAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,7 +33,7 @@
 | 
				
			|||||||
#define GNSS_SDR_GALILEO_E1_PCPS_AMBIGUOUS_ACQUISITION_H_
 | 
					#define GNSS_SDR_GALILEO_E1_PCPS_AMBIGUOUS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acq_conf.h"
 | 
					#include "acq_conf.h"
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition.h"
 | 
					#include "pcps_acquisition.h"
 | 
				
			||||||
@@ -91,8 +91,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -159,6 +171,7 @@ private:
 | 
				
			|||||||
    bool use_CFAR_algorithm_flag_;
 | 
					    bool use_CFAR_algorithm_flag_;
 | 
				
			||||||
    bool acquire_pilot_;
 | 
					    bool acquire_pilot_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -168,7 +168,7 @@ GalileoE1PcpsAmbiguousAcquisitionFpga::GalileoE1PcpsAmbiguousAcquisitionFpga(
 | 
				
			|||||||
    channel_ = 0;
 | 
					    channel_ = 0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    // temporary buffers that we can delete
 | 
					    // temporary buffers that we can delete
 | 
				
			||||||
    delete[] code;
 | 
					    delete[] code;
 | 
				
			||||||
    delete fft_if;
 | 
					    delete fft_if;
 | 
				
			||||||
@@ -189,13 +189,6 @@ void GalileoE1PcpsAmbiguousAcquisitionFpga::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GalileoE1PcpsAmbiguousAcquisitionFpga::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_fpga_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE1PcpsAmbiguousAcquisitionFpga::set_threshold(float threshold)
 | 
					void GalileoE1PcpsAmbiguousAcquisitionFpga::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold;
 | 
					    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -32,7 +32,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GALILEO_E1_PCPS_AMBIGUOUS_ACQUISITION_FPGA_H_
 | 
					#ifndef GNSS_SDR_GALILEO_E1_PCPS_AMBIGUOUS_ACQUISITION_FPGA_H_
 | 
				
			||||||
#define GNSS_SDR_GALILEO_E1_PCPS_AMBIGUOUS_ACQUISITION_FPGA_H_
 | 
					#define GNSS_SDR_GALILEO_E1_PCPS_AMBIGUOUS_ACQUISITION_FPGA_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "pcps_acquisition_fpga.h"
 | 
					#include "pcps_acquisition_fpga.h"
 | 
				
			||||||
#include <gnuradio/blocks/float_to_complex.h>
 | 
					#include <gnuradio/blocks/float_to_complex.h>
 | 
				
			||||||
@@ -93,8 +93,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -150,6 +162,7 @@ private:
 | 
				
			|||||||
    complex_byte_to_float_x2_sptr cbyte_to_float_x2_;
 | 
					    complex_byte_to_float_x2_sptr cbyte_to_float_x2_;
 | 
				
			||||||
    bool acquire_pilot_;
 | 
					    bool acquire_pilot_;
 | 
				
			||||||
    uint32_t channel_;
 | 
					    uint32_t channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    uint32_t doppler_max_;
 | 
					    uint32_t doppler_max_;
 | 
				
			||||||
    uint32_t doppler_step_;
 | 
					    uint32_t doppler_step_;
 | 
				
			||||||
    std::string dump_filename_;
 | 
					    std::string dump_filename_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -111,6 +111,7 @@ GalileoE1PcpsCccwsrAmbiguousAcquisition::GalileoE1PcpsCccwsrAmbiguousAcquisition
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -134,31 +135,8 @@ void GalileoE1PcpsCccwsrAmbiguousAcquisition::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GalileoE1PcpsCccwsrAmbiguousAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    if (item_type_ == "gr_complex")
 | 
					 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
            acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE1PcpsCccwsrAmbiguousAcquisition::set_threshold(float threshold)
 | 
					void GalileoE1PcpsCccwsrAmbiguousAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    //    float pfa = configuration_->property(role_+ std::to_string(channel_) + ".pfa", 0.0);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    //    if(pfa==0.0) pfa = configuration_->property(role_+".pfa", 0.0);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    //    if(pfa==0.0)
 | 
					 | 
				
			||||||
    //        {
 | 
					 | 
				
			||||||
    //            threshold_ = threshold;
 | 
					 | 
				
			||||||
    //        }
 | 
					 | 
				
			||||||
    //    else
 | 
					 | 
				
			||||||
    //        {
 | 
					 | 
				
			||||||
    //            threshold_ = calculate_threshold(pfa);
 | 
					 | 
				
			||||||
    //        }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    threshold_ = threshold;
 | 
					    threshold_ = threshold;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold_;
 | 
					    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -32,7 +32,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GALILEO_E1_PCPS_CCCWSR_AMBIGUOUS_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GALILEO_E1_PCPS_CCCWSR_AMBIGUOUS_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GALILEO_E1_PCPS_CCCWSR_AMBIGUOUS_ACQUISITION_H_
 | 
					#define GNSS_SDR_GALILEO_E1_PCPS_CCCWSR_AMBIGUOUS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_cccwsr_acquisition_cc.h"
 | 
					#include "pcps_cccwsr_acquisition_cc.h"
 | 
				
			||||||
#include <gnuradio/blocks/stream_to_vector.h>
 | 
					#include <gnuradio/blocks/stream_to_vector.h>
 | 
				
			||||||
@@ -87,8 +87,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of CCCWSR algorithm
 | 
					     * \brief Set statistics threshold of CCCWSR algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -143,6 +155,7 @@ private:
 | 
				
			|||||||
    unsigned int code_length_;
 | 
					    unsigned int code_length_;
 | 
				
			||||||
    //unsigned int satellite_;
 | 
					    //unsigned int satellite_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -144,6 +144,7 @@ GalileoE1PcpsQuickSyncAmbiguousAcquisition::GalileoE1PcpsQuickSyncAmbiguousAcqui
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -166,16 +167,6 @@ void GalileoE1PcpsQuickSyncAmbiguousAcquisition::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GalileoE1PcpsQuickSyncAmbiguousAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    if (item_type_ == "gr_complex")
 | 
					 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
            acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE1PcpsQuickSyncAmbiguousAcquisition::set_threshold(float threshold)
 | 
					void GalileoE1PcpsQuickSyncAmbiguousAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -32,7 +32,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GALILEO_E1_PCPS_QUICKSYNC_AMBIGUOUS_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GALILEO_E1_PCPS_QUICKSYNC_AMBIGUOUS_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GALILEO_E1_PCPS_QUICKSYNC_AMBIGUOUS_ACQUISITION_H_
 | 
					#define GNSS_SDR_GALILEO_E1_PCPS_QUICKSYNC_AMBIGUOUS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_quicksync_acquisition_cc.h"
 | 
					#include "pcps_quicksync_acquisition_cc.h"
 | 
				
			||||||
#include <gnuradio/blocks/stream_to_vector.h>
 | 
					#include <gnuradio/blocks/stream_to_vector.h>
 | 
				
			||||||
@@ -88,8 +88,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -147,6 +159,7 @@ private:
 | 
				
			|||||||
    unsigned int code_length_;
 | 
					    unsigned int code_length_;
 | 
				
			||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -114,6 +114,7 @@ GalileoE1PcpsTongAmbiguousAcquisition::GalileoE1PcpsTongAmbiguousAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -136,16 +137,6 @@ void GalileoE1PcpsTongAmbiguousAcquisition::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GalileoE1PcpsTongAmbiguousAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    if (item_type_ == "gr_complex")
 | 
					 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
            acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE1PcpsTongAmbiguousAcquisition::set_threshold(float threshold)
 | 
					void GalileoE1PcpsTongAmbiguousAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -32,7 +32,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GALILEO_E1_PCPS_TONG_AMBIGUOUS_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GALILEO_E1_PCPS_TONG_AMBIGUOUS_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GALILEO_E1_PCPS_TONG_AMBIGUOUS_ACQUISITION_H_
 | 
					#define GNSS_SDR_GALILEO_E1_PCPS_TONG_AMBIGUOUS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_tong_acquisition_cc.h"
 | 
					#include "pcps_tong_acquisition_cc.h"
 | 
				
			||||||
#include <gnuradio/blocks/stream_to_vector.h>
 | 
					#include <gnuradio/blocks/stream_to_vector.h>
 | 
				
			||||||
@@ -87,8 +87,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of TONG algorithm
 | 
					     * \brief Set statistics threshold of TONG algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -145,6 +157,7 @@ private:
 | 
				
			|||||||
    unsigned int vector_length_;
 | 
					    unsigned int vector_length_;
 | 
				
			||||||
    unsigned int code_length_;
 | 
					    unsigned int code_length_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -119,6 +119,7 @@ GalileoE5aNoncoherentIQAcquisitionCaf::GalileoE5aNoncoherentIQAcquisitionCaf(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -142,16 +143,6 @@ void GalileoE5aNoncoherentIQAcquisitionCaf::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GalileoE5aNoncoherentIQAcquisitionCaf::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    if (item_type_ == "gr_complex")
 | 
					 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
            acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE5aNoncoherentIQAcquisitionCaf::set_threshold(float threshold)
 | 
					void GalileoE5aNoncoherentIQAcquisitionCaf::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -38,7 +38,7 @@
 | 
				
			|||||||
#ifndef GALILEO_E5A_NONCOHERENT_IQ_ACQUISITION_CAF_H_
 | 
					#ifndef GALILEO_E5A_NONCOHERENT_IQ_ACQUISITION_CAF_H_
 | 
				
			||||||
#define GALILEO_E5A_NONCOHERENT_IQ_ACQUISITION_CAF_H_
 | 
					#define GALILEO_E5A_NONCOHERENT_IQ_ACQUISITION_CAF_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "galileo_e5a_noncoherent_iq_acquisition_caf_cc.h"
 | 
					#include "galileo_e5a_noncoherent_iq_acquisition_caf_cc.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include <string>
 | 
					#include <string>
 | 
				
			||||||
@@ -88,8 +88,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -148,6 +160,7 @@ private:
 | 
				
			|||||||
    unsigned int code_length_;
 | 
					    unsigned int code_length_;
 | 
				
			||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -152,6 +152,7 @@ GalileoE5aPcpsAcquisition::GalileoE5aPcpsAcquisition(ConfigurationInterface* con
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -174,13 +175,6 @@ void GalileoE5aPcpsAcquisition::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GalileoE5aPcpsAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE5aPcpsAcquisition::set_threshold(float threshold)
 | 
					void GalileoE5aPcpsAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -32,7 +32,7 @@
 | 
				
			|||||||
#define GALILEO_E5A_PCPS_ACQUISITION_H_
 | 
					#define GALILEO_E5A_PCPS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition.h"
 | 
					#include "pcps_acquisition.h"
 | 
				
			||||||
#include <string>
 | 
					#include <string>
 | 
				
			||||||
@@ -79,8 +79,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -157,6 +169,7 @@ private:
 | 
				
			|||||||
    unsigned int vector_length_;
 | 
					    unsigned int vector_length_;
 | 
				
			||||||
    unsigned int code_length_;
 | 
					    unsigned int code_length_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
    unsigned int sampled_ms_;
 | 
					    unsigned int sampled_ms_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -169,7 +169,7 @@ GalileoE5aPcpsAcquisitionFpga::GalileoE5aPcpsAcquisitionFpga(ConfigurationInterf
 | 
				
			|||||||
    channel_ = 0;
 | 
					    channel_ = 0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    // temporary buffers that we can delete
 | 
					    // temporary buffers that we can delete
 | 
				
			||||||
    delete[] code;
 | 
					    delete[] code;
 | 
				
			||||||
    delete fft_if;
 | 
					    delete fft_if;
 | 
				
			||||||
@@ -190,13 +190,6 @@ void GalileoE5aPcpsAcquisitionFpga::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GalileoE5aPcpsAcquisitionFpga::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_fpga_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GalileoE5aPcpsAcquisitionFpga::set_threshold(float threshold)
 | 
					void GalileoE5aPcpsAcquisitionFpga::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold;
 | 
					    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,7 +33,7 @@
 | 
				
			|||||||
#define GNSS_SDR_GALILEO_E5A_PCPS_ACQUISITION_FPGA_H_
 | 
					#define GNSS_SDR_GALILEO_E5A_PCPS_ACQUISITION_FPGA_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "pcps_acquisition_fpga.h"
 | 
					#include "pcps_acquisition_fpga.h"
 | 
				
			||||||
#include <gnuradio/blocks/stream_to_vector.h>
 | 
					#include <gnuradio/blocks/stream_to_vector.h>
 | 
				
			||||||
#include <gnuradio/runtime_types.h>  // for basic_block_sptr, top_block_sptr
 | 
					#include <gnuradio/runtime_types.h>  // for basic_block_sptr, top_block_sptr
 | 
				
			||||||
@@ -89,12 +89,23 @@ public:
 | 
				
			|||||||
     * tracking blocks
 | 
					     * tracking blocks
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_gnss_synchro(Gnss_Synchro* p_gnss_synchro) override;
 | 
					    void set_gnss_synchro(Gnss_Synchro* p_gnss_synchro) override;
 | 
				
			||||||
 | 
					 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -165,6 +176,7 @@ private:
 | 
				
			|||||||
    bool acq_iq_;
 | 
					    bool acq_iq_;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    uint32_t channel_;
 | 
					    uint32_t channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    uint32_t doppler_max_;
 | 
					    uint32_t doppler_max_;
 | 
				
			||||||
    uint32_t doppler_step_;
 | 
					    uint32_t doppler_step_;
 | 
				
			||||||
    unsigned int in_streams_;
 | 
					    unsigned int in_streams_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -125,6 +125,7 @@ GlonassL1CaPcpsAcquisition::GlonassL1CaPcpsAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -146,14 +147,6 @@ void GlonassL1CaPcpsAcquisition::stop_acquisition()
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					 | 
				
			||||||
void GlonassL1CaPcpsAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GlonassL1CaPcpsAcquisition::set_threshold(float threshold)
 | 
					void GlonassL1CaPcpsAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -34,7 +34,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GLONASS_L1_CA_PCPS_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GLONASS_L1_CA_PCPS_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GLONASS_L1_CA_PCPS_ACQUISITION_H_
 | 
					#define GNSS_SDR_GLONASS_L1_CA_PCPS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition.h"
 | 
					#include "pcps_acquisition.h"
 | 
				
			||||||
@@ -86,12 +86,23 @@ public:
 | 
				
			|||||||
     *  tracking blocks
 | 
					     *  tracking blocks
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_gnss_synchro(Gnss_Synchro* p_gnss_synchro) override;
 | 
					    void set_gnss_synchro(Gnss_Synchro* p_gnss_synchro) override;
 | 
				
			||||||
 | 
					 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -151,6 +162,7 @@ private:
 | 
				
			|||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    bool use_CFAR_algorithm_flag_;
 | 
					    bool use_CFAR_algorithm_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -124,6 +124,7 @@ GlonassL2CaPcpsAcquisition::GlonassL2CaPcpsAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -146,13 +147,6 @@ void GlonassL2CaPcpsAcquisition::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GlonassL2CaPcpsAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GlonassL2CaPcpsAcquisition::set_threshold(float threshold)
 | 
					void GlonassL2CaPcpsAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,7 +33,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GLONASS_L2_CA_PCPS_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GLONASS_L2_CA_PCPS_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GLONASS_L2_CA_PCPS_ACQUISITION_H_
 | 
					#define GNSS_SDR_GLONASS_L2_CA_PCPS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition.h"
 | 
					#include "pcps_acquisition.h"
 | 
				
			||||||
@@ -89,8 +89,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -150,6 +162,7 @@ private:
 | 
				
			|||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    bool use_CFAR_algorithm_flag_;
 | 
					    bool use_CFAR_algorithm_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -147,6 +147,7 @@ GpsL1CaPcpsAcquisition::GpsL1CaPcpsAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -168,14 +169,6 @@ void GpsL1CaPcpsAcquisition::stop_acquisition()
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsAcquisition::set_threshold(float threshold)
 | 
					void GpsL1CaPcpsAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -37,7 +37,7 @@
 | 
				
			|||||||
#define GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_H_
 | 
					#define GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acq_conf.h"
 | 
					#include "acq_conf.h"
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition.h"
 | 
					#include "pcps_acquisition.h"
 | 
				
			||||||
@@ -95,8 +95,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -162,6 +174,7 @@ private:
 | 
				
			|||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    bool use_CFAR_algorithm_flag_;
 | 
					    bool use_CFAR_algorithm_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -97,6 +97,7 @@ GpsL1CaPcpsAcquisitionFineDoppler::GpsL1CaPcpsAcquisitionFineDoppler(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -119,13 +120,6 @@ void GpsL1CaPcpsAcquisitionFineDoppler::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GpsL1CaPcpsAcquisitionFineDoppler::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsAcquisitionFineDoppler::set_threshold(float threshold)
 | 
					void GpsL1CaPcpsAcquisitionFineDoppler::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    threshold_ = threshold;
 | 
					    threshold_ = threshold;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -34,7 +34,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_FINE_DOPPLER_H_
 | 
					#ifndef GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_FINE_DOPPLER_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_FINE_DOPPLER_H_
 | 
					#define GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_FINE_DOPPLER_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition_fine_doppler_cc.h"
 | 
					#include "pcps_acquisition_fine_doppler_cc.h"
 | 
				
			||||||
#include <string>
 | 
					#include <string>
 | 
				
			||||||
@@ -88,8 +88,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -140,6 +152,7 @@ private:
 | 
				
			|||||||
    std::string item_type_;
 | 
					    std::string item_type_;
 | 
				
			||||||
    unsigned int vector_length_;
 | 
					    unsigned int vector_length_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    int doppler_max_;
 | 
					    int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -151,7 +151,7 @@ GpsL1CaPcpsAcquisitionFpga::GpsL1CaPcpsAcquisitionFpga(
 | 
				
			|||||||
    channel_ = 0;
 | 
					    channel_ = 0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    // temporary buffers that we can delete
 | 
					    // temporary buffers that we can delete
 | 
				
			||||||
    delete[] code;
 | 
					    delete[] code;
 | 
				
			||||||
    delete fft_if;
 | 
					    delete fft_if;
 | 
				
			||||||
@@ -172,13 +172,6 @@ void GpsL1CaPcpsAcquisitionFpga::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GpsL1CaPcpsAcquisitionFpga::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_fpga_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsAcquisitionFpga::set_threshold(float threshold)
 | 
					void GpsL1CaPcpsAcquisitionFpga::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold;
 | 
					    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -35,7 +35,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_FPGA_H_
 | 
					#ifndef GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_FPGA_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_FPGA_H_
 | 
					#define GNSS_SDR_GPS_L1_CA_PCPS_ACQUISITION_FPGA_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "pcps_acquisition_fpga.h"
 | 
					#include "pcps_acquisition_fpga.h"
 | 
				
			||||||
#include <gnuradio/runtime_types.h>  // for basic_block_sptr, top_block_sptr
 | 
					#include <gnuradio/runtime_types.h>  // for basic_block_sptr, top_block_sptr
 | 
				
			||||||
#include <volk/volk_complex.h>       // for lv_16sc_t
 | 
					#include <volk/volk_complex.h>       // for lv_16sc_t
 | 
				
			||||||
@@ -93,8 +93,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -146,6 +158,7 @@ private:
 | 
				
			|||||||
    ConfigurationInterface* configuration_;
 | 
					    ConfigurationInterface* configuration_;
 | 
				
			||||||
    pcps_acquisition_fpga_sptr acquisition_fpga_;
 | 
					    pcps_acquisition_fpga_sptr acquisition_fpga_;
 | 
				
			||||||
    uint32_t channel_;
 | 
					    uint32_t channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    uint32_t doppler_max_;
 | 
					    uint32_t doppler_max_;
 | 
				
			||||||
    uint32_t doppler_step_;
 | 
					    uint32_t doppler_step_;
 | 
				
			||||||
    Gnss_Synchro* gnss_synchro_;
 | 
					    Gnss_Synchro* gnss_synchro_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -89,6 +89,7 @@ GpsL1CaPcpsAssistedAcquisition::GpsL1CaPcpsAssistedAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -111,13 +112,6 @@ void GpsL1CaPcpsAssistedAcquisition::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GpsL1CaPcpsAssistedAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsAssistedAcquisition::set_threshold(float threshold)
 | 
					void GpsL1CaPcpsAssistedAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    threshold_ = threshold;
 | 
					    threshold_ = threshold;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -34,7 +34,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L1_CA_PCPS_ASSISTED_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GPS_L1_CA_PCPS_ASSISTED_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L1_CA_PCPS_ASSISTED_ACQUISITION_H_
 | 
					#define GNSS_SDR_GPS_L1_CA_PCPS_ASSISTED_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_assisted_acquisition_cc.h"
 | 
					#include "pcps_assisted_acquisition_cc.h"
 | 
				
			||||||
#include <string>
 | 
					#include <string>
 | 
				
			||||||
@@ -88,8 +88,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -137,6 +149,7 @@ private:
 | 
				
			|||||||
    unsigned int vector_length_;
 | 
					    unsigned int vector_length_;
 | 
				
			||||||
    //unsigned int satellite_;
 | 
					    //unsigned int satellite_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    int doppler_max_;
 | 
					    int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -105,6 +105,7 @@ GpsL1CaPcpsOpenClAcquisition::GpsL1CaPcpsOpenClAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -126,17 +127,6 @@ void GpsL1CaPcpsOpenClAcquisition::stop_acquisition()
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsOpenClAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    if (item_type_ == "gr_complex")
 | 
					 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
            acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsOpenClAcquisition::set_threshold(float threshold)
 | 
					void GpsL1CaPcpsOpenClAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -32,7 +32,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L1_CA_PCPS_OPENCL_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GPS_L1_CA_PCPS_OPENCL_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L1_CA_PCPS_OPENCL_ACQUISITION_H_
 | 
					#define GNSS_SDR_GPS_L1_CA_PCPS_OPENCL_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_opencl_acquisition_cc.h"
 | 
					#include "pcps_opencl_acquisition_cc.h"
 | 
				
			||||||
#include <gnuradio/blocks/stream_to_vector.h>
 | 
					#include <gnuradio/blocks/stream_to_vector.h>
 | 
				
			||||||
@@ -87,8 +87,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -142,6 +154,7 @@ private:
 | 
				
			|||||||
    unsigned int code_length_;
 | 
					    unsigned int code_length_;
 | 
				
			||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -137,6 +137,7 @@ GpsL1CaPcpsQuickSyncAcquisition::GpsL1CaPcpsQuickSyncAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -158,17 +159,6 @@ void GpsL1CaPcpsQuickSyncAcquisition::stop_acquisition()
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsQuickSyncAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    if (item_type_ == "gr_complex")
 | 
					 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
            acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsQuickSyncAcquisition::set_threshold(float threshold)
 | 
					void GpsL1CaPcpsQuickSyncAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,7 +33,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L1_CA_PCPS_QUICKSYNC_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GPS_L1_CA_PCPS_QUICKSYNC_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L1_CA_PCPS_QUICKSYNC_ACQUISITION_H_
 | 
					#define GNSS_SDR_GPS_L1_CA_PCPS_QUICKSYNC_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "configuration_interface.h"
 | 
					#include "configuration_interface.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_quicksync_acquisition_cc.h"
 | 
					#include "pcps_quicksync_acquisition_cc.h"
 | 
				
			||||||
@@ -89,8 +89,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -148,6 +160,7 @@ private:
 | 
				
			|||||||
    unsigned int code_length_;
 | 
					    unsigned int code_length_;
 | 
				
			||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -99,6 +99,7 @@ GpsL1CaPcpsTongAcquisition::GpsL1CaPcpsTongAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -120,17 +121,6 @@ void GpsL1CaPcpsTongAcquisition::stop_acquisition()
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsTongAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    if (item_type_ == "gr_complex")
 | 
					 | 
				
			||||||
        {
 | 
					 | 
				
			||||||
            acquisition_cc_->set_channel(channel_);
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL1CaPcpsTongAcquisition::set_threshold(float threshold)
 | 
					void GpsL1CaPcpsTongAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -32,7 +32,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L1_CA_TONG_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GPS_L1_CA_TONG_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L1_CA_TONG_ACQUISITION_H_
 | 
					#define GNSS_SDR_GPS_L1_CA_TONG_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "configuration_interface.h"
 | 
					#include "configuration_interface.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_tong_acquisition_cc.h"
 | 
					#include "pcps_tong_acquisition_cc.h"
 | 
				
			||||||
@@ -88,8 +88,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_cc_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of TONG algorithm
 | 
					     * \brief Set statistics threshold of TONG algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -146,6 +158,7 @@ private:
 | 
				
			|||||||
    unsigned int vector_length_;
 | 
					    unsigned int vector_length_;
 | 
				
			||||||
    unsigned int code_length_;
 | 
					    unsigned int code_length_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -151,6 +151,7 @@ GpsL2MPcpsAcquisition::GpsL2MPcpsAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    num_codes_ = acq_parameters_.sampled_ms / acq_parameters_.ms_per_code;
 | 
					    num_codes_ = acq_parameters_.sampled_ms / acq_parameters_.ms_per_code;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
@@ -174,13 +175,6 @@ void GpsL2MPcpsAcquisition::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GpsL2MPcpsAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL2MPcpsAcquisition::set_threshold(float threshold)
 | 
					void GpsL2MPcpsAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -34,7 +34,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L2_M_PCPS_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GPS_L2_M_PCPS_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L2_M_PCPS_ACQUISITION_H_
 | 
					#define GNSS_SDR_GPS_L2_M_PCPS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition.h"
 | 
					#include "pcps_acquisition.h"
 | 
				
			||||||
@@ -92,8 +92,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -159,6 +171,7 @@ private:
 | 
				
			|||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    bool use_CFAR_algorithm_flag_;
 | 
					    bool use_CFAR_algorithm_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -144,7 +144,7 @@ GpsL2MPcpsAcquisitionFpga::GpsL2MPcpsAcquisitionFpga(
 | 
				
			|||||||
    channel_ = 0;
 | 
					    channel_ = 0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    DLOG(INFO) << "acquisition(" << acquisition_fpga_->unique_id() << ")";
 | 
					    DLOG(INFO) << "acquisition(" << acquisition_fpga_->unique_id() << ")";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
@@ -162,13 +162,6 @@ void GpsL2MPcpsAcquisitionFpga::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GpsL2MPcpsAcquisitionFpga::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_fpga_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL2MPcpsAcquisitionFpga::set_threshold(float threshold)
 | 
					void GpsL2MPcpsAcquisitionFpga::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    threshold_ = threshold;
 | 
					    threshold_ = threshold;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -34,7 +34,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L2_M_PCPS_ACQUISITION_FPGA_H_
 | 
					#ifndef GNSS_SDR_GPS_L2_M_PCPS_ACQUISITION_FPGA_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L2_M_PCPS_ACQUISITION_FPGA_H_
 | 
					#define GNSS_SDR_GPS_L2_M_PCPS_ACQUISITION_FPGA_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "pcps_acquisition_fpga.h"
 | 
					#include "pcps_acquisition_fpga.h"
 | 
				
			||||||
#include <gnuradio/blocks/float_to_complex.h>
 | 
					#include <gnuradio/blocks/float_to_complex.h>
 | 
				
			||||||
@@ -94,8 +94,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -151,6 +163,7 @@ private:
 | 
				
			|||||||
    complex_byte_to_float_x2_sptr cbyte_to_float_x2_;
 | 
					    complex_byte_to_float_x2_sptr cbyte_to_float_x2_;
 | 
				
			||||||
    std::string item_type_;
 | 
					    std::string item_type_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -147,6 +147,7 @@ GpsL5iPcpsAcquisition::GpsL5iPcpsAcquisition(
 | 
				
			|||||||
    threshold_ = 0.0;
 | 
					    threshold_ = 0.0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    if (in_streams_ > 1)
 | 
					    if (in_streams_ > 1)
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
            LOG(ERROR) << "This implementation only supports one input stream";
 | 
					            LOG(ERROR) << "This implementation only supports one input stream";
 | 
				
			||||||
@@ -169,13 +170,6 @@ void GpsL5iPcpsAcquisition::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GpsL5iPcpsAcquisition::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL5iPcpsAcquisition::set_threshold(float threshold)
 | 
					void GpsL5iPcpsAcquisition::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
					    float pfa = configuration_->property(role_ + std::to_string(channel_) + ".pfa", 0.0);
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -34,7 +34,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L5i_PCPS_ACQUISITION_H_
 | 
					#ifndef GNSS_SDR_GPS_L5i_PCPS_ACQUISITION_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L5i_PCPS_ACQUISITION_H_
 | 
					#define GNSS_SDR_GPS_L5i_PCPS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "pcps_acquisition.h"
 | 
					#include "pcps_acquisition.h"
 | 
				
			||||||
@@ -92,8 +92,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -158,6 +170,7 @@ private:
 | 
				
			|||||||
    bool bit_transition_flag_;
 | 
					    bool bit_transition_flag_;
 | 
				
			||||||
    bool use_CFAR_algorithm_flag_;
 | 
					    bool use_CFAR_algorithm_flag_;
 | 
				
			||||||
    unsigned int channel_;
 | 
					    unsigned int channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    float threshold_;
 | 
					    float threshold_;
 | 
				
			||||||
    unsigned int doppler_max_;
 | 
					    unsigned int doppler_max_;
 | 
				
			||||||
    unsigned int doppler_step_;
 | 
					    unsigned int doppler_step_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -151,7 +151,7 @@ GpsL5iPcpsAcquisitionFpga::GpsL5iPcpsAcquisitionFpga(
 | 
				
			|||||||
    channel_ = 0;
 | 
					    channel_ = 0;
 | 
				
			||||||
    doppler_step_ = 0;
 | 
					    doppler_step_ = 0;
 | 
				
			||||||
    gnss_synchro_ = nullptr;
 | 
					    gnss_synchro_ = nullptr;
 | 
				
			||||||
 | 
					    channel_fsm_ = nullptr;
 | 
				
			||||||
    // temporary buffers that we can delete
 | 
					    // temporary buffers that we can delete
 | 
				
			||||||
    delete[] code;
 | 
					    delete[] code;
 | 
				
			||||||
    delete fft_if;
 | 
					    delete fft_if;
 | 
				
			||||||
@@ -173,13 +173,6 @@ void GpsL5iPcpsAcquisitionFpga::stop_acquisition()
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void GpsL5iPcpsAcquisitionFpga::set_channel(unsigned int channel)
 | 
					 | 
				
			||||||
{
 | 
					 | 
				
			||||||
    channel_ = channel;
 | 
					 | 
				
			||||||
    acquisition_fpga_->set_channel(channel_);
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
void GpsL5iPcpsAcquisitionFpga::set_threshold(float threshold)
 | 
					void GpsL5iPcpsAcquisitionFpga::set_threshold(float threshold)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold;
 | 
					    DLOG(INFO) << "Channel " << channel_ << " Threshold = " << threshold;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -35,7 +35,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_GPS_L5I_PCPS_ACQUISITION_FPGA_H_
 | 
					#ifndef GNSS_SDR_GPS_L5I_PCPS_ACQUISITION_FPGA_H_
 | 
				
			||||||
#define GNSS_SDR_GPS_L5I_PCPS_ACQUISITION_FPGA_H_
 | 
					#define GNSS_SDR_GPS_L5I_PCPS_ACQUISITION_FPGA_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acquisition_interface.h"
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "complex_byte_to_float_x2.h"
 | 
					#include "complex_byte_to_float_x2.h"
 | 
				
			||||||
#include "pcps_acquisition_fpga.h"
 | 
					#include "pcps_acquisition_fpga.h"
 | 
				
			||||||
#include <gnuradio/blocks/float_to_complex.h>
 | 
					#include <gnuradio/blocks/float_to_complex.h>
 | 
				
			||||||
@@ -95,8 +95,20 @@ public:
 | 
				
			|||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set acquisition channel unique ID
 | 
					     * \brief Set acquisition channel unique ID
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    void set_channel(unsigned int channel) override;
 | 
					    inline void set_channel(unsigned int channel)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_ = channel;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel(channel_);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        channel_fsm_ = channel_fsm;
 | 
				
			||||||
 | 
					        acquisition_fpga_->set_channel_fsm(channel_fsm);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm
 | 
					     * \brief Set statistics threshold of PCPS algorithm
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
@@ -152,6 +164,7 @@ private:
 | 
				
			|||||||
    complex_byte_to_float_x2_sptr cbyte_to_float_x2_;
 | 
					    complex_byte_to_float_x2_sptr cbyte_to_float_x2_;
 | 
				
			||||||
    std::string item_type_;
 | 
					    std::string item_type_;
 | 
				
			||||||
    uint32_t channel_;
 | 
					    uint32_t channel_;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> channel_fsm_;
 | 
				
			||||||
    uint32_t doppler_max_;
 | 
					    uint32_t doppler_max_;
 | 
				
			||||||
    uint32_t doppler_step_;
 | 
					    uint32_t doppler_step_;
 | 
				
			||||||
    std::string dump_filename_;
 | 
					    std::string dump_filename_;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -71,6 +71,7 @@ target_link_libraries(acquisition_gr_blocks
 | 
				
			|||||||
        Gnuradio::runtime
 | 
					        Gnuradio::runtime
 | 
				
			||||||
        Gnuradio::fft
 | 
					        Gnuradio::fft
 | 
				
			||||||
        Volk::volk
 | 
					        Volk::volk
 | 
				
			||||||
 | 
					        channel_libs
 | 
				
			||||||
        acquisition_libs
 | 
					        acquisition_libs
 | 
				
			||||||
        core_system_parameters
 | 
					        core_system_parameters
 | 
				
			||||||
        ${OPT_LIBRARIES}
 | 
					        ${OPT_LIBRARIES}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -38,6 +38,7 @@
 | 
				
			|||||||
#ifndef GALILEO_E5A_NONCOHERENT_IQ_ACQUISITION_CAF_CC_H_
 | 
					#ifndef GALILEO_E5A_NONCOHERENT_IQ_ACQUISITION_CAF_CC_H_
 | 
				
			||||||
#define GALILEO_E5A_NONCOHERENT_IQ_ACQUISITION_CAF_CC_H_
 | 
					#define GALILEO_E5A_NONCOHERENT_IQ_ACQUISITION_CAF_CC_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include <gnuradio/block.h>
 | 
					#include <gnuradio/block.h>
 | 
				
			||||||
#include <gnuradio/fft/fft.h>
 | 
					#include <gnuradio/fft/fft.h>
 | 
				
			||||||
@@ -99,6 +100,7 @@ private:
 | 
				
			|||||||
        int doppler_offset);
 | 
					        int doppler_offset);
 | 
				
			||||||
    float estimate_input_power(gr_complex* in);
 | 
					    float estimate_input_power(gr_complex* in);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
    int64_t d_fs_in;
 | 
					    int64_t d_fs_in;
 | 
				
			||||||
    int d_samples_per_ms;
 | 
					    int d_samples_per_ms;
 | 
				
			||||||
    int d_sampled_ms;
 | 
					    int d_sampled_ms;
 | 
				
			||||||
@@ -211,6 +213,13 @@ public:
 | 
				
			|||||||
        d_channel = channel;
 | 
					        d_channel = channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
      * \brief Set statistics threshold of PCPS algorithm.
 | 
					      * \brief Set statistics threshold of PCPS algorithm.
 | 
				
			||||||
      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -32,6 +32,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_PCPS_8MS_ACQUISITION_CC_H_
 | 
					#ifndef GNSS_SDR_PCPS_8MS_ACQUISITION_CC_H_
 | 
				
			||||||
#define GNSS_SDR_PCPS_8MS_ACQUISITION_CC_H_
 | 
					#define GNSS_SDR_PCPS_8MS_ACQUISITION_CC_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include <gnuradio/block.h>
 | 
					#include <gnuradio/block.h>
 | 
				
			||||||
#include <gnuradio/fft/fft.h>
 | 
					#include <gnuradio/fft/fft.h>
 | 
				
			||||||
@@ -117,6 +118,7 @@ private:
 | 
				
			|||||||
    int32_t d_state;
 | 
					    int32_t d_state;
 | 
				
			||||||
    bool d_dump;
 | 
					    bool d_dump;
 | 
				
			||||||
    uint32_t d_channel;
 | 
					    uint32_t d_channel;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
    std::string d_dump_filename;
 | 
					    std::string d_dump_filename;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
public:
 | 
					public:
 | 
				
			||||||
@@ -180,6 +182,14 @@ public:
 | 
				
			|||||||
        d_channel = channel;
 | 
					        d_channel = channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm.
 | 
					     * \brief Set statistics threshold of PCPS algorithm.
 | 
				
			||||||
     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -429,7 +429,15 @@ void pcps_acquisition::send_positive_acquisition()
 | 
				
			|||||||
               << ", magnitude " << d_mag
 | 
					               << ", magnitude " << d_mag
 | 
				
			||||||
               << ", input signal power " << d_input_power;
 | 
					               << ", input signal power " << d_input_power;
 | 
				
			||||||
    d_positive_acq = 1;
 | 
					    d_positive_acq = 1;
 | 
				
			||||||
    this->message_port_pub(pmt::mp("events"), pmt::from_long(1));
 | 
					    if (d_channel_fsm)
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					            //the channel FSM is set, so, notify it directly the positive acquisition to minimize delays
 | 
				
			||||||
 | 
					            d_channel_fsm->Event_valid_acquisition();
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					    else
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					            this->message_port_pub(pmt::mp("events"), pmt::from_long(1));
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -53,6 +53,7 @@
 | 
				
			|||||||
#define GNSS_SDR_PCPS_ACQUISITION_H_
 | 
					#define GNSS_SDR_PCPS_ACQUISITION_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acq_conf.h"
 | 
					#include "acq_conf.h"
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include <armadillo>
 | 
					#include <armadillo>
 | 
				
			||||||
#include <gnuradio/block.h>
 | 
					#include <gnuradio/block.h>
 | 
				
			||||||
#include <gnuradio/fft/fft.h>
 | 
					#include <gnuradio/fft/fft.h>
 | 
				
			||||||
@@ -123,6 +124,7 @@ private:
 | 
				
			|||||||
    int64_t d_old_freq;
 | 
					    int64_t d_old_freq;
 | 
				
			||||||
    int32_t d_state;
 | 
					    int32_t d_state;
 | 
				
			||||||
    uint32_t d_channel;
 | 
					    uint32_t d_channel;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
    uint32_t d_doppler_step;
 | 
					    uint32_t d_doppler_step;
 | 
				
			||||||
    float d_doppler_center_step_two;
 | 
					    float d_doppler_center_step_two;
 | 
				
			||||||
    uint32_t d_num_noncoherent_integrations_counter;
 | 
					    uint32_t d_num_noncoherent_integrations_counter;
 | 
				
			||||||
@@ -204,10 +206,18 @@ public:
 | 
				
			|||||||
      */
 | 
					      */
 | 
				
			||||||
    inline void set_channel(uint32_t channel)
 | 
					    inline void set_channel(uint32_t channel)
 | 
				
			||||||
    {
 | 
					    {
 | 
				
			||||||
        gr::thread::scoped_lock lock(d_setlock);  // require mutex with work function called by the scheduler
 | 
					 | 
				
			||||||
        d_channel = channel;
 | 
					        d_channel = channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
      * \brief Set statistics threshold of PCPS algorithm.
 | 
					      * \brief Set statistics threshold of PCPS algorithm.
 | 
				
			||||||
      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -50,6 +50,7 @@
 | 
				
			|||||||
#define GNSS_SDR_PCPS_ACQUISITION_FINE_DOPPLER_CC_H_
 | 
					#define GNSS_SDR_PCPS_ACQUISITION_FINE_DOPPLER_CC_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#include "acq_conf.h"
 | 
					#include "acq_conf.h"
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include <armadillo>
 | 
					#include <armadillo>
 | 
				
			||||||
#include <gnuradio/block.h>
 | 
					#include <gnuradio/block.h>
 | 
				
			||||||
@@ -121,10 +122,11 @@ private:
 | 
				
			|||||||
    int d_n_samples_in_buffer;
 | 
					    int d_n_samples_in_buffer;
 | 
				
			||||||
    bool d_dump;
 | 
					    bool d_dump;
 | 
				
			||||||
    unsigned int d_channel;
 | 
					    unsigned int d_channel;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    std::string d_dump_filename;
 | 
					    std::string d_dump_filename;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    arma ::fmat grid_;
 | 
					    arma::fmat grid_;
 | 
				
			||||||
    int64_t d_dump_number;
 | 
					    int64_t d_dump_number;
 | 
				
			||||||
    unsigned int d_dump_channel;
 | 
					    unsigned int d_dump_channel;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -183,6 +185,14 @@ public:
 | 
				
			|||||||
        d_dump_channel = d_channel;
 | 
					        d_dump_channel = d_channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm.
 | 
					     * \brief Set statistics threshold of PCPS algorithm.
 | 
				
			||||||
     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -150,7 +150,15 @@ void pcps_acquisition_fpga::send_positive_acquisition()
 | 
				
			|||||||
               << ", magnitude " << d_mag
 | 
					               << ", magnitude " << d_mag
 | 
				
			||||||
               << ", input signal power " << d_input_power;
 | 
					               << ", input signal power " << d_input_power;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    this->message_port_pub(pmt::mp("events"), pmt::from_long(1));
 | 
					    if (d_channel_fsm)
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					            //the channel FSM is set, so, notify it directly the positive acquisition to minimize delays
 | 
				
			||||||
 | 
					            d_channel_fsm->Event_valid_acquisition();
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					    else
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					            this->message_port_pub(pmt::mp("events"), pmt::from_long(1));
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -41,6 +41,7 @@
 | 
				
			|||||||
#define GNSS_SDR_PCPS_ACQUISITION_FPGA_H_
 | 
					#define GNSS_SDR_PCPS_ACQUISITION_FPGA_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "fpga_acquisition.h"
 | 
					#include "fpga_acquisition.h"
 | 
				
			||||||
#include <boost/shared_ptr.hpp>
 | 
					#include <boost/shared_ptr.hpp>
 | 
				
			||||||
#include <gnuradio/block.h>     // for block
 | 
					#include <gnuradio/block.h>     // for block
 | 
				
			||||||
@@ -104,6 +105,7 @@ private:
 | 
				
			|||||||
    float d_test_statistics;
 | 
					    float d_test_statistics;
 | 
				
			||||||
    int32_t d_state;
 | 
					    int32_t d_state;
 | 
				
			||||||
    uint32_t d_channel;
 | 
					    uint32_t d_channel;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
    uint32_t d_doppler_step;
 | 
					    uint32_t d_doppler_step;
 | 
				
			||||||
    uint32_t d_fft_size;
 | 
					    uint32_t d_fft_size;
 | 
				
			||||||
    uint32_t d_num_doppler_bins;
 | 
					    uint32_t d_num_doppler_bins;
 | 
				
			||||||
@@ -171,6 +173,15 @@ public:
 | 
				
			|||||||
        d_channel = channel;
 | 
					        d_channel = channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm.
 | 
					     * \brief Set statistics threshold of PCPS algorithm.
 | 
				
			||||||
     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -48,6 +48,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_PCPS_ASSISTED_ACQUISITION_CC_H_
 | 
					#ifndef GNSS_SDR_PCPS_ASSISTED_ACQUISITION_CC_H_
 | 
				
			||||||
#define GNSS_SDR_PCPS_ASSISTED_ACQUISITION_CC_H_
 | 
					#define GNSS_SDR_PCPS_ASSISTED_ACQUISITION_CC_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include <gnuradio/block.h>
 | 
					#include <gnuradio/block.h>
 | 
				
			||||||
#include <gnuradio/fft/fft.h>
 | 
					#include <gnuradio/fft/fft.h>
 | 
				
			||||||
@@ -137,7 +138,7 @@ private:
 | 
				
			|||||||
    int32_t d_well_count;
 | 
					    int32_t d_well_count;
 | 
				
			||||||
    bool d_dump;
 | 
					    bool d_dump;
 | 
				
			||||||
    uint32_t d_channel;
 | 
					    uint32_t d_channel;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
    std::string d_dump_filename;
 | 
					    std::string d_dump_filename;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
public:
 | 
					public:
 | 
				
			||||||
@@ -194,6 +195,15 @@ public:
 | 
				
			|||||||
        d_channel = channel;
 | 
					        d_channel = channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm.
 | 
					     * \brief Set statistics threshold of PCPS algorithm.
 | 
				
			||||||
     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -37,6 +37,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_PCPS_CCCWSR_ACQUISITION_CC_H_
 | 
					#ifndef GNSS_SDR_PCPS_CCCWSR_ACQUISITION_CC_H_
 | 
				
			||||||
#define GNSS_SDR_PCPS_CCCWSR_ACQUISITION_CC_H_
 | 
					#define GNSS_SDR_PCPS_CCCWSR_ACQUISITION_CC_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include <gnuradio/block.h>
 | 
					#include <gnuradio/block.h>
 | 
				
			||||||
#include <gnuradio/fft/fft.h>
 | 
					#include <gnuradio/fft/fft.h>
 | 
				
			||||||
@@ -116,6 +117,7 @@ private:
 | 
				
			|||||||
    int32_t d_state;
 | 
					    int32_t d_state;
 | 
				
			||||||
    bool d_dump;
 | 
					    bool d_dump;
 | 
				
			||||||
    uint32_t d_channel;
 | 
					    uint32_t d_channel;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
    std::string d_dump_filename;
 | 
					    std::string d_dump_filename;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
public:
 | 
					public:
 | 
				
			||||||
@@ -180,6 +182,14 @@ public:
 | 
				
			|||||||
        d_channel = channel;
 | 
					        d_channel = channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
      * \brief Set statistics threshold of CCCWSR algorithm.
 | 
					      * \brief Set statistics threshold of CCCWSR algorithm.
 | 
				
			||||||
      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -51,6 +51,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_PCPS_OPENCL_ACQUISITION_CC_H_
 | 
					#ifndef GNSS_SDR_PCPS_OPENCL_ACQUISITION_CC_H_
 | 
				
			||||||
#define GNSS_SDR_PCPS_OPENCL_ACQUISITION_CC_H_
 | 
					#define GNSS_SDR_PCPS_OPENCL_ACQUISITION_CC_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include "opencl/fft_internal.h"
 | 
					#include "opencl/fft_internal.h"
 | 
				
			||||||
#include <gnuradio/block.h>
 | 
					#include <gnuradio/block.h>
 | 
				
			||||||
@@ -161,7 +162,7 @@ private:
 | 
				
			|||||||
    cl::CommandQueue* d_cl_queue;
 | 
					    cl::CommandQueue* d_cl_queue;
 | 
				
			||||||
    clFFT_Plan d_cl_fft_plan;
 | 
					    clFFT_Plan d_cl_fft_plan;
 | 
				
			||||||
    cl_int d_cl_fft_batch_size;
 | 
					    cl_int d_cl_fft_batch_size;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
    int d_opencl;
 | 
					    int d_opencl;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
public:
 | 
					public:
 | 
				
			||||||
@@ -225,6 +226,14 @@ public:
 | 
				
			|||||||
        d_channel = channel;
 | 
					        d_channel = channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
      * \brief Set statistics threshold of PCPS algorithm.
 | 
					      * \brief Set statistics threshold of PCPS algorithm.
 | 
				
			||||||
      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -51,6 +51,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_PCPS_QUICKSYNC_ACQUISITION_CC_H_
 | 
					#ifndef GNSS_SDR_PCPS_QUICKSYNC_ACQUISITION_CC_H_
 | 
				
			||||||
#define GNSS_SDR_PCPS_QUICKSYNC_ACQUISITION_CC_H_
 | 
					#define GNSS_SDR_PCPS_QUICKSYNC_ACQUISITION_CC_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include <gnuradio/block.h>
 | 
					#include <gnuradio/block.h>
 | 
				
			||||||
#include <gnuradio/fft/fft.h>
 | 
					#include <gnuradio/fft/fft.h>
 | 
				
			||||||
@@ -150,6 +151,7 @@ private:
 | 
				
			|||||||
    int32_t d_state;
 | 
					    int32_t d_state;
 | 
				
			||||||
    bool d_dump;
 | 
					    bool d_dump;
 | 
				
			||||||
    uint32_t d_channel;
 | 
					    uint32_t d_channel;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
    std::string d_dump_filename;
 | 
					    std::string d_dump_filename;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
public:
 | 
					public:
 | 
				
			||||||
@@ -213,6 +215,14 @@ public:
 | 
				
			|||||||
        d_channel = channel;
 | 
					        d_channel = channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
     * \brief Set statistics threshold of PCPS algorithm.
 | 
					     * \brief Set statistics threshold of PCPS algorithm.
 | 
				
			||||||
     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					     * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -51,6 +51,7 @@
 | 
				
			|||||||
#ifndef GNSS_SDR_PCPS_TONG_ACQUISITION_CC_H_
 | 
					#ifndef GNSS_SDR_PCPS_TONG_ACQUISITION_CC_H_
 | 
				
			||||||
#define GNSS_SDR_PCPS_TONG_ACQUISITION_CC_H_
 | 
					#define GNSS_SDR_PCPS_TONG_ACQUISITION_CC_H_
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "gnss_synchro.h"
 | 
					#include "gnss_synchro.h"
 | 
				
			||||||
#include <gnuradio/block.h>
 | 
					#include <gnuradio/block.h>
 | 
				
			||||||
#include <gnuradio/fft/fft.h>
 | 
					#include <gnuradio/fft/fft.h>
 | 
				
			||||||
@@ -133,6 +134,7 @@ private:
 | 
				
			|||||||
    int32_t d_state;
 | 
					    int32_t d_state;
 | 
				
			||||||
    bool d_dump;
 | 
					    bool d_dump;
 | 
				
			||||||
    uint32_t d_channel;
 | 
					    uint32_t d_channel;
 | 
				
			||||||
 | 
					    std::shared_ptr<ChannelFsm> d_channel_fsm;
 | 
				
			||||||
    std::string d_dump_filename;
 | 
					    std::string d_dump_filename;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
public:
 | 
					public:
 | 
				
			||||||
@@ -196,6 +198,14 @@ public:
 | 
				
			|||||||
        d_channel = channel;
 | 
					        d_channel = channel;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /*!
 | 
				
			||||||
 | 
					      * \brief Set channel fsm associated to this acquisition instance
 | 
				
			||||||
 | 
					      */
 | 
				
			||||||
 | 
					    inline void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm)
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					        d_channel_fsm = channel_fsm;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
    /*!
 | 
					    /*!
 | 
				
			||||||
      * \brief Set statistics threshold of TONG algorithm.
 | 
					      * \brief Set statistics threshold of TONG algorithm.
 | 
				
			||||||
      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
					      * \param threshold - Threshold for signal detection (check \ref Navitec2012,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -57,6 +57,7 @@ Channel::Channel(ConfigurationInterface* configuration, uint32_t channel, std::s
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
    flag_enable_fpga = configuration->property("Channel.enable_FPGA", false);
 | 
					    flag_enable_fpga = configuration->property("Channel.enable_FPGA", false);
 | 
				
			||||||
    acq_->set_channel(channel_);
 | 
					    acq_->set_channel(channel_);
 | 
				
			||||||
 | 
					    acq_->set_channel_fsm(channel_fsm_);
 | 
				
			||||||
    trk_->set_channel(channel_);
 | 
					    trk_->set_channel(channel_);
 | 
				
			||||||
    nav_->set_channel(channel_);
 | 
					    nav_->set_channel(channel_);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -34,7 +34,7 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
#ifndef GNSS_SDR_CHANNEL_H_
 | 
					#ifndef GNSS_SDR_CHANNEL_H_
 | 
				
			||||||
#define GNSS_SDR_CHANNEL_H_
 | 
					#define GNSS_SDR_CHANNEL_H_
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "channel_interface.h"
 | 
					#include "channel_interface.h"
 | 
				
			||||||
#include "channel_msg_receiver_cc.h"
 | 
					#include "channel_msg_receiver_cc.h"
 | 
				
			||||||
#include "gnss_signal.h"
 | 
					#include "gnss_signal.h"
 | 
				
			||||||
@@ -51,7 +51,7 @@ class ConfigurationInterface;
 | 
				
			|||||||
class AcquisitionInterface;
 | 
					class AcquisitionInterface;
 | 
				
			||||||
class TrackingInterface;
 | 
					class TrackingInterface;
 | 
				
			||||||
class TelemetryDecoderInterface;
 | 
					class TelemetryDecoderInterface;
 | 
				
			||||||
class ChannelFsm;
 | 
					//class ChannelFsm;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/*!
 | 
					/*!
 | 
				
			||||||
 * \brief This class represents a GNSS channel. It wraps an AcquisitionInterface,
 | 
					 * \brief This class represents a GNSS channel. It wraps an AcquisitionInterface,
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -24,7 +24,7 @@ set(CHANNEL_FSM_SOURCES
 | 
				
			|||||||
set(CHANNEL_FSM_HEADERS
 | 
					set(CHANNEL_FSM_HEADERS
 | 
				
			||||||
    channel_fsm.h
 | 
					    channel_fsm.h
 | 
				
			||||||
    channel_msg_receiver_cc.h
 | 
					    channel_msg_receiver_cc.h
 | 
				
			||||||
)
 | 
					) 
 | 
				
			||||||
 | 
					
 | 
				
			||||||
list(SORT CHANNEL_FSM_HEADERS)
 | 
					list(SORT CHANNEL_FSM_HEADERS)
 | 
				
			||||||
list(SORT CHANNEL_FSM_SOURCES)
 | 
					list(SORT CHANNEL_FSM_SOURCES)
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -67,6 +67,8 @@ void channel_msg_receiver_cc::msg_handler_events(pmt::pmt_t msg)
 | 
				
			|||||||
            switch (message)
 | 
					            switch (message)
 | 
				
			||||||
                {
 | 
					                {
 | 
				
			||||||
                case 1:  // positive acquisition
 | 
					                case 1:  // positive acquisition
 | 
				
			||||||
 | 
					                         // Now the acquisition block can optionally trigger the event valid acquisition internally,
 | 
				
			||||||
 | 
					                         // in order to reduce acquisition to tracking delay.
 | 
				
			||||||
                    result = d_channel_fsm->Event_valid_acquisition();
 | 
					                    result = d_channel_fsm->Event_valid_acquisition();
 | 
				
			||||||
                    break;
 | 
					                    break;
 | 
				
			||||||
                case 2:  // negative acquisition
 | 
					                case 2:  // negative acquisition
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -44,6 +44,8 @@
 | 
				
			|||||||
template <typename Data>
 | 
					template <typename Data>
 | 
				
			||||||
class Concurrent_Queue;
 | 
					class Concurrent_Queue;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					class ChannelFsm;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/*! \brief This abstract class represents an interface to an acquisition GNSS block.
 | 
					/*! \brief This abstract class represents an interface to an acquisition GNSS block.
 | 
				
			||||||
 *
 | 
					 *
 | 
				
			||||||
 * Abstract class for acquisition algorithms. Since all its methods are virtual,
 | 
					 * Abstract class for acquisition algorithms. Since all its methods are virtual,
 | 
				
			||||||
@@ -55,7 +57,8 @@ class AcquisitionInterface : public GNSSBlockInterface
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
public:
 | 
					public:
 | 
				
			||||||
    virtual void set_gnss_synchro(Gnss_Synchro* gnss_synchro) = 0;
 | 
					    virtual void set_gnss_synchro(Gnss_Synchro* gnss_synchro) = 0;
 | 
				
			||||||
    virtual void set_channel(unsigned int channel) = 0;
 | 
					    virtual void set_channel(unsigned int channel_id) = 0;
 | 
				
			||||||
 | 
					    virtual void set_channel_fsm(std::shared_ptr<ChannelFsm> channel_fsm) = 0;
 | 
				
			||||||
    virtual void set_threshold(float threshold) = 0;
 | 
					    virtual void set_threshold(float threshold) = 0;
 | 
				
			||||||
    virtual void set_doppler_max(unsigned int doppler_max) = 0;
 | 
					    virtual void set_doppler_max(unsigned int doppler_max) = 0;
 | 
				
			||||||
    virtual void set_doppler_step(unsigned int doppler_step) = 0;
 | 
					    virtual void set_doppler_step(unsigned int doppler_step) = 0;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -140,6 +140,7 @@ target_link_libraries(core_receiver
 | 
				
			|||||||
        Boost::boost
 | 
					        Boost::boost
 | 
				
			||||||
        Boost::thread
 | 
					        Boost::thread
 | 
				
			||||||
        Gnuradio::runtime
 | 
					        Gnuradio::runtime
 | 
				
			||||||
 | 
					        channel_libs
 | 
				
			||||||
        core_libs
 | 
					        core_libs
 | 
				
			||||||
        core_monitor
 | 
					        core_monitor
 | 
				
			||||||
    PRIVATE
 | 
					    PRIVATE
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -39,6 +39,7 @@
 | 
				
			|||||||
#include "Galileo_E1.h"
 | 
					#include "Galileo_E1.h"
 | 
				
			||||||
#include "Galileo_E5a.h"
 | 
					#include "Galileo_E5a.h"
 | 
				
			||||||
#include "channel.h"
 | 
					#include "channel.h"
 | 
				
			||||||
 | 
					#include "channel_fsm.h"
 | 
				
			||||||
#include "channel_interface.h"
 | 
					#include "channel_interface.h"
 | 
				
			||||||
#include "configuration_interface.h"
 | 
					#include "configuration_interface.h"
 | 
				
			||||||
#include "gnss_block_factory.h"
 | 
					#include "gnss_block_factory.h"
 | 
				
			||||||
@@ -214,7 +215,7 @@ void GNSSFlowgraph::connect()
 | 
				
			|||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    DLOG(INFO) << "blocks connected internally";
 | 
					    DLOG(INFO) << "blocks connected internally";
 | 
				
			||||||
    // Signal Source (i) >  Signal conditioner (i) >
 | 
					// Signal Source (i) >  Signal conditioner (i) >
 | 
				
			||||||
#ifndef ENABLE_FPGA
 | 
					#ifndef ENABLE_FPGA
 | 
				
			||||||
    int RF_Channels = 0;
 | 
					    int RF_Channels = 0;
 | 
				
			||||||
    int signal_conditioner_ID = 0;
 | 
					    int signal_conditioner_ID = 0;
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user