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

Add a common shared pointer definition

Makes transition to GNU Radio 3.9 API less verbose
This commit is contained in:
Carles Fernandez 2020-11-03 20:51:57 +01:00
parent 165ae06d7a
commit f0e1ef6f9a
No known key found for this signature in database
GPG Key ID: 4C583C52B0C3877D
129 changed files with 315 additions and 1198 deletions

View File

@ -23,6 +23,12 @@ SPDX-FileCopyrightText: 2011-2020 Carles Fernandez-Prades <carles.fernandez@cttc
- Faster `SignalConditioner` block when its implementation is set to - Faster `SignalConditioner` block when its implementation is set to
`Pass_Through`. `Pass_Through`.
### Improvements in Maintainability:
- Added a common shared pointer definition `gnss_shared_ptr`, which allows to
handle the `boost::shared_ptr` to `std::shared_ptr` transition in GNU Radio
3.9 API more nicely.
### Improvements in Portability: ### Improvements in Portability:
- Fixed `-DENABLE_OWN_GLOG=ON` building option when gflags is installed and it - Fixed `-DENABLE_OWN_GLOG=ON` building option when gflags is installed and it

View File

@ -50,6 +50,11 @@ if(GNURADIO_USES_STD_POINTERS)
) )
endif() endif()
target_include_directories(pvt_gr_blocks
PUBLIC
${CMAKE_SOURCE_DIR}/src/core/interfaces
)
if(USE_GENERIC_LAMBDAS) if(USE_GENERIC_LAMBDAS)
set(has_generic_lambdas HAS_GENERIC_LAMBDA=1) set(has_generic_lambdas HAS_GENERIC_LAMBDA=1)
set(no_has_generic_lambdas HAS_GENERIC_LAMBDA=0) set(no_has_generic_lambdas HAS_GENERIC_LAMBDA=0)

View File

@ -20,6 +20,7 @@
#ifndef GNSS_SDR_RTKLIB_PVT_GS_H #ifndef GNSS_SDR_RTKLIB_PVT_GS_H
#define GNSS_SDR_RTKLIB_PVT_GS_H #define GNSS_SDR_RTKLIB_PVT_GS_H
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "rtklib.h" #include "rtklib.h"
#include <boost/date_time/gregorian/gregorian.hpp> #include <boost/date_time/gregorian/gregorian.hpp>
@ -36,10 +37,6 @@
#include <string> // for string #include <string> // for string
#include <sys/types.h> // for key_t #include <sys/types.h> // for key_t
#include <vector> // for vector #include <vector> // for vector
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup PVT /** \addtogroup PVT
* \{ */ * \{ */
@ -65,11 +62,7 @@ class Rtcm_Printer;
class Rtklib_Solver; class Rtklib_Solver;
class rtklib_pvt_gs; class rtklib_pvt_gs;
#if GNURADIO_USES_STD_POINTERS using rtklib_pvt_gs_sptr = gnss_shared_ptr<rtklib_pvt_gs>;
using rtklib_pvt_gs_sptr = std::shared_ptr<rtklib_pvt_gs>;
#else
using rtklib_pvt_gs_sptr = boost::shared_ptr<rtklib_pvt_gs>;
#endif
rtklib_pvt_gs_sptr rtklib_make_pvt_gs(uint32_t nchannels, rtklib_pvt_gs_sptr rtklib_make_pvt_gs(uint32_t nchannels,
const Pvt_Conf& conf_, const Pvt_Conf& conf_,

View File

@ -163,8 +163,8 @@ void GpsL1CaPcpsAcquisitionFineDoppler::set_state(int state)
acquisition_cc_->set_state(state); acquisition_cc_->set_state(state);
} }
#if GNURADIO_USES_STD_POINTERS
void GpsL1CaPcpsAcquisitionFineDoppler::connect(std::shared_ptr<gr::top_block> top_block) void GpsL1CaPcpsAcquisitionFineDoppler::connect(gnss_shared_ptr<gr::top_block> top_block)
{ {
if (top_block) if (top_block)
{ /* top_block is not null */ { /* top_block is not null */
@ -173,26 +173,7 @@ void GpsL1CaPcpsAcquisitionFineDoppler::connect(std::shared_ptr<gr::top_block> t
} }
void GpsL1CaPcpsAcquisitionFineDoppler::disconnect(std::shared_ptr<gr::top_block> top_block) void GpsL1CaPcpsAcquisitionFineDoppler::disconnect(gnss_shared_ptr<gr::top_block> top_block)
{
if (top_block)
{ /* top_block is not null */
};
// nothing to disconnect, now the tracking uses gr_sync_decimator
}
std::shared_ptr<gr::basic_block> GpsL1CaPcpsAcquisitionFineDoppler::get_left_block()
{
return acquisition_cc_;
}
std::shared_ptr<gr::basic_block> GpsL1CaPcpsAcquisitionFineDoppler::get_right_block()
{
return acquisition_cc_;
}
#else
void GpsL1CaPcpsAcquisitionFineDoppler::connect(boost::shared_ptr<gr::top_block> top_block)
{ {
if (top_block) if (top_block)
{ /* top_block is not null */ { /* top_block is not null */
@ -201,22 +182,13 @@ void GpsL1CaPcpsAcquisitionFineDoppler::connect(boost::shared_ptr<gr::top_block>
} }
void GpsL1CaPcpsAcquisitionFineDoppler::disconnect(boost::shared_ptr<gr::top_block> top_block) gnss_shared_ptr<gr::basic_block> GpsL1CaPcpsAcquisitionFineDoppler::get_left_block()
{
if (top_block)
{ /* top_block is not null */
};
// nothing to disconnect, now the tracking uses gr_sync_decimator
}
boost::shared_ptr<gr::basic_block> GpsL1CaPcpsAcquisitionFineDoppler::get_left_block()
{ {
return acquisition_cc_; return acquisition_cc_;
} }
boost::shared_ptr<gr::basic_block> GpsL1CaPcpsAcquisitionFineDoppler::get_right_block() gnss_shared_ptr<gr::basic_block> GpsL1CaPcpsAcquisitionFineDoppler::get_right_block()
{ {
return acquisition_cc_; return acquisition_cc_;
} }
#endif

View File

@ -29,12 +29,6 @@
#include <memory> #include <memory>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
using pcps_acquisition_fine_doppler_cc_sptr = std::shared_ptr<pcps_acquisition_fine_doppler_cc>;
#else
#include <boost/shared_ptr.hpp>
using pcps_acquisition_fine_doppler_cc_sptr = boost::shared_ptr<pcps_acquisition_fine_doppler_cc>;
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* \{ */ * \{ */
@ -42,6 +36,8 @@ using pcps_acquisition_fine_doppler_cc_sptr = boost::shared_ptr<pcps_acquisition
* \{ */ * \{ */
using pcps_acquisition_fine_doppler_cc_sptr = gnss_shared_ptr<pcps_acquisition_fine_doppler_cc>;
class ConfigurationInterface; class ConfigurationInterface;
/*! /*!
@ -76,17 +72,11 @@ public:
return item_size_; return item_size_;
} }
#if GNURADIO_USES_STD_POINTERS void connect(gnss_shared_ptr<gr::top_block> top_block) override;
void connect(std::shared_ptr<gr::top_block> top_block) override; void disconnect(gnss_shared_ptr<gr::top_block> top_block) override;
void disconnect(std::shared_ptr<gr::top_block> top_block) override; gnss_shared_ptr<gr::basic_block> get_left_block() override;
std::shared_ptr<gr::basic_block> get_left_block() override; gnss_shared_ptr<gr::basic_block> get_right_block() override;
std::shared_ptr<gr::basic_block> get_right_block() override;
#else
void connect(boost::shared_ptr<gr::top_block> top_block) override;
void disconnect(boost::shared_ptr<gr::top_block> top_block) override;
boost::shared_ptr<gr::basic_block> get_left_block() override;
boost::shared_ptr<gr::basic_block> get_right_block() override;
#endif
/*! /*!
* \brief Set acquisition/tracking common Gnss_Synchro object pointer * \brief Set acquisition/tracking common Gnss_Synchro object pointer
* to efficiently exchange synchronization data between acquisition and * to efficiently exchange synchronization data between acquisition and

View File

@ -37,10 +37,6 @@
#include <string> #include <string>
#include <utility> #include <utility>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* \{ */ * \{ */
@ -50,11 +46,7 @@
class galileo_e5a_noncoherentIQ_acquisition_caf_cc; class galileo_e5a_noncoherentIQ_acquisition_caf_cc;
#if GNURADIO_USES_STD_POINTERS using galileo_e5a_noncoherentIQ_acquisition_caf_cc_sptr = gnss_shared_ptr<galileo_e5a_noncoherentIQ_acquisition_caf_cc>;
using galileo_e5a_noncoherentIQ_acquisition_caf_cc_sptr = std::shared_ptr<galileo_e5a_noncoherentIQ_acquisition_caf_cc>;
#else
using galileo_e5a_noncoherentIQ_acquisition_caf_cc_sptr = boost::shared_ptr<galileo_e5a_noncoherentIQ_acquisition_caf_cc>;
#endif
galileo_e5a_noncoherentIQ_acquisition_caf_cc_sptr galileo_e5a_noncoherentIQ_make_acquisition_caf_cc( galileo_e5a_noncoherentIQ_acquisition_caf_cc_sptr galileo_e5a_noncoherentIQ_make_acquisition_caf_cc(
unsigned int sampled_ms, unsigned int sampled_ms,

View File

@ -31,10 +31,6 @@
#include <string> #include <string>
#include <utility> #include <utility>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* \{ */ * \{ */
@ -44,11 +40,7 @@
class galileo_pcps_8ms_acquisition_cc; class galileo_pcps_8ms_acquisition_cc;
#if GNURADIO_USES_STD_POINTERS using galileo_pcps_8ms_acquisition_cc_sptr = gnss_shared_ptr<galileo_pcps_8ms_acquisition_cc>;
using galileo_pcps_8ms_acquisition_cc_sptr = std::shared_ptr<galileo_pcps_8ms_acquisition_cc>;
#else
using galileo_pcps_8ms_acquisition_cc_sptr = boost::shared_ptr<galileo_pcps_8ms_acquisition_cc>;
#endif
galileo_pcps_8ms_acquisition_cc_sptr galileo_pcps_8ms_acquisition_cc_sptr
galileo_pcps_8ms_make_acquisition_cc(uint32_t sampled_ms, galileo_pcps_8ms_make_acquisition_cc(uint32_t sampled_ms,

View File

@ -71,11 +71,6 @@ namespace own = std;
namespace own = gsl; namespace own = gsl;
#endif #endif
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* Classes for GNSS signal acquisition * Classes for GNSS signal acquisition
* \{ */ * \{ */
@ -87,11 +82,7 @@ namespace own = gsl;
class Gnss_Synchro; class Gnss_Synchro;
class pcps_acquisition; class pcps_acquisition;
#if GNURADIO_USES_STD_POINTERS using pcps_acquisition_sptr = gnss_shared_ptr<pcps_acquisition>;
using pcps_acquisition_sptr = std::shared_ptr<pcps_acquisition>;
#else
using pcps_acquisition_sptr = boost::shared_ptr<pcps_acquisition>;
#endif
pcps_acquisition_sptr pcps_make_acquisition(const Acq_Conf& conf_); pcps_acquisition_sptr pcps_make_acquisition(const Acq_Conf& conf_);

View File

@ -55,10 +55,7 @@
#include <memory> #include <memory>
#include <string> #include <string>
#include <utility> #include <utility>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* \{ */ * \{ */
@ -68,11 +65,7 @@
class pcps_acquisition_fine_doppler_cc; class pcps_acquisition_fine_doppler_cc;
#if GNURADIO_USES_STD_POINTERS using pcps_acquisition_fine_doppler_cc_sptr = gnss_shared_ptr<pcps_acquisition_fine_doppler_cc>;
using pcps_acquisition_fine_doppler_cc_sptr = std::shared_ptr<pcps_acquisition_fine_doppler_cc>;
#else
using pcps_acquisition_fine_doppler_cc_sptr = boost::shared_ptr<pcps_acquisition_fine_doppler_cc>;
#endif
pcps_acquisition_fine_doppler_cc_sptr pcps_make_acquisition_fine_doppler_cc(const Acq_Conf& conf_); pcps_acquisition_fine_doppler_cc_sptr pcps_make_acquisition_fine_doppler_cc(const Acq_Conf& conf_);

View File

@ -47,10 +47,6 @@
#include <string> #include <string>
#include <utility> #include <utility>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* \{ */ * \{ */
@ -60,11 +56,7 @@
class pcps_assisted_acquisition_cc; class pcps_assisted_acquisition_cc;
#if GNURADIO_USES_STD_POINTERS using pcps_assisted_acquisition_cc_sptr = gnss_shared_ptr<pcps_assisted_acquisition_cc>;
using pcps_assisted_acquisition_cc_sptr = std::shared_ptr<pcps_assisted_acquisition_cc>;
#else
using pcps_assisted_acquisition_cc_sptr = boost::shared_ptr<pcps_assisted_acquisition_cc>;
#endif
pcps_assisted_acquisition_cc_sptr pcps_make_assisted_acquisition_cc( pcps_assisted_acquisition_cc_sptr pcps_make_assisted_acquisition_cc(
int32_t max_dwells, int32_t max_dwells,

View File

@ -36,10 +36,6 @@
#include <string> #include <string>
#include <utility> #include <utility>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* \{ */ * \{ */
@ -49,11 +45,7 @@
class pcps_cccwsr_acquisition_cc; class pcps_cccwsr_acquisition_cc;
#if GNURADIO_USES_STD_POINTERS using pcps_cccwsr_acquisition_cc_sptr = gnss_shared_ptr<pcps_cccwsr_acquisition_cc>;
using pcps_cccwsr_acquisition_cc_sptr = std::shared_ptr<pcps_cccwsr_acquisition_cc>;
#else
using pcps_cccwsr_acquisition_cc_sptr = boost::shared_ptr<pcps_cccwsr_acquisition_cc>;
#endif
pcps_cccwsr_acquisition_cc_sptr pcps_cccwsr_make_acquisition_cc( pcps_cccwsr_acquisition_cc_sptr pcps_cccwsr_make_acquisition_cc(
uint32_t sampled_ms, uint32_t sampled_ms,

View File

@ -53,10 +53,6 @@
#include <memory> // for weak_ptr #include <memory> // for weak_ptr
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* \{ */ * \{ */
@ -66,11 +62,7 @@
class pcps_opencl_acquisition_cc; class pcps_opencl_acquisition_cc;
#if GNURADIO_USES_STD_POINTERS using pcps_opencl_acquisition_cc_sptr = gnss_shared_ptr<pcps_opencl_acquisition_cc>;
typedef std::shared_ptr<pcps_opencl_acquisition_cc> pcps_opencl_acquisition_cc_sptr;
#else
typedef boost::shared_ptr<pcps_opencl_acquisition_cc> pcps_opencl_acquisition_cc_sptr;
#endif
pcps_opencl_acquisition_cc_sptr pcps_make_opencl_acquisition_cc( pcps_opencl_acquisition_cc_sptr pcps_make_opencl_acquisition_cc(
uint32_t sampled_ms, uint32_t sampled_ms,

View File

@ -53,10 +53,6 @@
#include <string> #include <string>
#include <utility> #include <utility>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* \{ */ * \{ */
@ -66,11 +62,7 @@
class pcps_quicksync_acquisition_cc; class pcps_quicksync_acquisition_cc;
#if GNURADIO_USES_STD_POINTERS using pcps_quicksync_acquisition_cc_sptr = gnss_shared_ptr<pcps_quicksync_acquisition_cc>;
using pcps_quicksync_acquisition_cc_sptr = std::shared_ptr<pcps_quicksync_acquisition_cc>;
#else
using pcps_quicksync_acquisition_cc_sptr = boost::shared_ptr<pcps_quicksync_acquisition_cc>;
#endif
pcps_quicksync_acquisition_cc_sptr pcps_quicksync_make_acquisition_cc( pcps_quicksync_acquisition_cc_sptr pcps_quicksync_make_acquisition_cc(
uint32_t folding_factor, uint32_t folding_factor,

View File

@ -50,10 +50,6 @@
#include <string> #include <string>
#include <utility> #include <utility>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Acquisition /** \addtogroup Acquisition
* \{ */ * \{ */
@ -63,11 +59,7 @@
class pcps_tong_acquisition_cc; class pcps_tong_acquisition_cc;
#if GNURADIO_USES_STD_POINTERS using pcps_tong_acquisition_cc_sptr = gnss_shared_ptr<pcps_tong_acquisition_cc>;
using pcps_tong_acquisition_cc_sptr = std::shared_ptr<pcps_tong_acquisition_cc>;
#else
using pcps_tong_acquisition_cc_sptr = boost::shared_ptr<pcps_tong_acquisition_cc>;
#endif
pcps_tong_acquisition_cc_sptr pcps_tong_make_acquisition_cc( pcps_tong_acquisition_cc_sptr pcps_tong_make_acquisition_cc(
uint32_t sampled_ms, uint32_t sampled_ms,

View File

@ -24,10 +24,6 @@
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <memory> #include <memory>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Channel /** \addtogroup Channel
* \{ */ * \{ */
@ -37,11 +33,7 @@
class channel_msg_receiver_cc; class channel_msg_receiver_cc;
#if GNURADIO_USES_STD_POINTERS using channel_msg_receiver_cc_sptr = gnss_shared_ptr<channel_msg_receiver_cc>;
using channel_msg_receiver_cc_sptr = std::shared_ptr<channel_msg_receiver_cc>;
#else
using channel_msg_receiver_cc_sptr = boost::shared_ptr<channel_msg_receiver_cc>;
#endif
channel_msg_receiver_cc_sptr channel_msg_receiver_make_cc(std::shared_ptr<ChannelFsm> channel_fsm, bool repeat); channel_msg_receiver_cc_sptr channel_msg_receiver_make_cc(std::shared_ptr<ChannelFsm> channel_fsm, bool repeat);

View File

@ -47,6 +47,11 @@ target_link_libraries(data_type_gr_blocks
Volk::volk Volk::volk
) )
target_include_directories(data_type_gr_blocks
PUBLIC
${CMAKE_SOURCE_DIR}/src/core/interfaces
)
if(GNURADIO_USES_STD_POINTERS) if(GNURADIO_USES_STD_POINTERS)
target_compile_definitions(data_type_gr_blocks target_compile_definitions(data_type_gr_blocks
PUBLIC -DGNURADIO_USES_STD_POINTERS=1 PUBLIC -DGNURADIO_USES_STD_POINTERS=1

View File

@ -20,12 +20,8 @@
#ifndef GNSS_SDR_INTERLEAVED_BYTE_TO_COMPLEX_BYTE_H #ifndef GNSS_SDR_INTERLEAVED_BYTE_TO_COMPLEX_BYTE_H
#define GNSS_SDR_INTERLEAVED_BYTE_TO_COMPLEX_BYTE_H #define GNSS_SDR_INTERLEAVED_BYTE_TO_COMPLEX_BYTE_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_decimator.h> #include <gnuradio/sync_decimator.h>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Data_Type /** \addtogroup Data_Type
* \{ */ * \{ */
@ -36,11 +32,7 @@
class interleaved_byte_to_complex_byte; class interleaved_byte_to_complex_byte;
#if GNURADIO_USES_STD_POINTERS using interleaved_byte_to_complex_byte_sptr = gnss_shared_ptr<interleaved_byte_to_complex_byte>;
using interleaved_byte_to_complex_byte_sptr = std::shared_ptr<interleaved_byte_to_complex_byte>;
#else
using interleaved_byte_to_complex_byte_sptr = boost::shared_ptr<interleaved_byte_to_complex_byte>;
#endif
interleaved_byte_to_complex_byte_sptr make_interleaved_byte_to_complex_byte(); interleaved_byte_to_complex_byte_sptr make_interleaved_byte_to_complex_byte();

View File

@ -20,12 +20,9 @@
#ifndef GNSS_SDR_INTERLEAVED_BYTE_TO_COMPLEX_SHORT_H #ifndef GNSS_SDR_INTERLEAVED_BYTE_TO_COMPLEX_SHORT_H
#define GNSS_SDR_INTERLEAVED_BYTE_TO_COMPLEX_SHORT_H #define GNSS_SDR_INTERLEAVED_BYTE_TO_COMPLEX_SHORT_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_decimator.h> #include <gnuradio/sync_decimator.h>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Data_Type /** \addtogroup Data_Type
* \{ */ * \{ */
@ -35,11 +32,7 @@
class interleaved_byte_to_complex_short; class interleaved_byte_to_complex_short;
#if GNURADIO_USES_STD_POINTERS using interleaved_byte_to_complex_short_sptr = gnss_shared_ptr<interleaved_byte_to_complex_short>;
using interleaved_byte_to_complex_short_sptr = std::shared_ptr<interleaved_byte_to_complex_short>;
#else
using interleaved_byte_to_complex_short_sptr = boost::shared_ptr<interleaved_byte_to_complex_short>;
#endif
interleaved_byte_to_complex_short_sptr make_interleaved_byte_to_complex_short(); interleaved_byte_to_complex_short_sptr make_interleaved_byte_to_complex_short();

View File

@ -20,12 +20,8 @@
#ifndef GNSS_SDR_INTERLEAVED_SHORT_TO_COMPLEX_SHORT_H #ifndef GNSS_SDR_INTERLEAVED_SHORT_TO_COMPLEX_SHORT_H
#define GNSS_SDR_INTERLEAVED_SHORT_TO_COMPLEX_SHORT_H #define GNSS_SDR_INTERLEAVED_SHORT_TO_COMPLEX_SHORT_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_decimator.h> #include <gnuradio/sync_decimator.h>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Data_Type /** \addtogroup Data_Type
* \{ */ * \{ */
@ -35,11 +31,7 @@
class interleaved_short_to_complex_short; class interleaved_short_to_complex_short;
#if GNURADIO_USES_STD_POINTERS using interleaved_short_to_complex_short_sptr = gnss_shared_ptr<interleaved_short_to_complex_short>;
using interleaved_short_to_complex_short_sptr = std::shared_ptr<interleaved_short_to_complex_short>;
#else
using interleaved_short_to_complex_short_sptr = boost::shared_ptr<interleaved_short_to_complex_short>;
#endif
interleaved_short_to_complex_short_sptr make_interleaved_short_to_complex_short(); interleaved_short_to_complex_short_sptr make_interleaved_short_to_complex_short();

View File

@ -52,6 +52,11 @@ target_link_libraries(input_filter_gr_blocks
Log4cpp::log4cpp Log4cpp::log4cpp
) )
target_include_directories(input_filter_gr_blocks
PUBLIC
${CMAKE_SOURCE_DIR}/src/core/interfaces
)
if(GNURADIO_USES_STD_POINTERS) if(GNURADIO_USES_STD_POINTERS)
target_compile_definitions(input_filter_gr_blocks target_compile_definitions(input_filter_gr_blocks
PUBLIC -DGNURADIO_USES_STD_POINTERS=1 PUBLIC -DGNURADIO_USES_STD_POINTERS=1

View File

@ -20,13 +20,9 @@
#ifndef GNSS_SDR_BEAMFORMER_H #ifndef GNSS_SDR_BEAMFORMER_H
#define GNSS_SDR_BEAMFORMER_H #define GNSS_SDR_BEAMFORMER_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Input_Filter /** \addtogroup Input_Filter
* \{ */ * \{ */
@ -36,11 +32,7 @@
class beamformer; class beamformer;
#if GNURADIO_USES_STD_POINTERS using beamformer_sptr = gnss_shared_ptr<beamformer>;
using beamformer_sptr = std::shared_ptr<beamformer>;
#else
using beamformer_sptr = boost::shared_ptr<beamformer>;
#endif
beamformer_sptr make_beamformer_sptr(); beamformer_sptr make_beamformer_sptr();

View File

@ -20,10 +20,7 @@
#ifndef GNSS_SDR_NOTCH_CC_H #ifndef GNSS_SDR_NOTCH_CC_H
#define GNSS_SDR_NOTCH_CC_H #define GNSS_SDR_NOTCH_CC_H
#if GNURADIO_USES_STD_POINTERS #include "gnss_block_interface.h"
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <gnuradio/fft/fft.h> #include <gnuradio/fft/fft.h>
#include <volk_gnsssdr/volk_gnsssdr_alloc.h> // for volk_gnsssdr::vector #include <volk_gnsssdr/volk_gnsssdr_alloc.h> // for volk_gnsssdr::vector
@ -38,11 +35,7 @@
class Notch; class Notch;
#if GNURADIO_USES_STD_POINTERS using notch_sptr = gnss_shared_ptr<Notch>;
using notch_sptr = std::shared_ptr<Notch>;
#else
using notch_sptr = boost::shared_ptr<Notch>;
#endif
notch_sptr make_notch_filter( notch_sptr make_notch_filter(
float pfa, float pfa,

View File

@ -20,10 +20,7 @@
#ifndef GNSS_SDR_NOTCH_LITE_CC_H #ifndef GNSS_SDR_NOTCH_LITE_CC_H
#define GNSS_SDR_NOTCH_LITE_CC_H #define GNSS_SDR_NOTCH_LITE_CC_H
#if GNURADIO_USES_STD_POINTERS #include "gnss_block_interface.h"
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <gnuradio/fft/fft.h> #include <gnuradio/fft/fft.h>
#include <volk_gnsssdr/volk_gnsssdr_alloc.h> // for volk_gnsssdr::vector #include <volk_gnsssdr/volk_gnsssdr_alloc.h> // for volk_gnsssdr::vector
@ -38,11 +35,7 @@
class NotchLite; class NotchLite;
#if GNURADIO_USES_STD_POINTERS using notch_lite_sptr = gnss_shared_ptr<NotchLite>;
using notch_lite_sptr = std::shared_ptr<NotchLite>;
#else
using notch_lite_sptr = boost::shared_ptr<NotchLite>;
#endif
notch_lite_sptr make_notch_filter_lite( notch_lite_sptr make_notch_filter_lite(
float p_c_factor, float p_c_factor,

View File

@ -20,11 +20,7 @@
#ifndef GNSS_SDR_PULSE_BLANKING_CC_H #ifndef GNSS_SDR_PULSE_BLANKING_CC_H
#define GNSS_SDR_PULSE_BLANKING_CC_H #define GNSS_SDR_PULSE_BLANKING_CC_H
#if GNURADIO_USES_STD_POINTERS #include "gnss_block_interface.h"
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <volk_gnsssdr/volk_gnsssdr_alloc.h> // for volk_gnsssdr::vector #include <volk_gnsssdr/volk_gnsssdr_alloc.h> // for volk_gnsssdr::vector
#include <cstdint> #include <cstdint>
@ -38,11 +34,7 @@
class pulse_blanking_cc; class pulse_blanking_cc;
#if GNURADIO_USES_STD_POINTERS using pulse_blanking_cc_sptr = gnss_shared_ptr<pulse_blanking_cc>;
using pulse_blanking_cc_sptr = std::shared_ptr<pulse_blanking_cc>;
#else
using pulse_blanking_cc_sptr = boost::shared_ptr<pulse_blanking_cc>;
#endif
pulse_blanking_cc_sptr make_pulse_blanking_cc( pulse_blanking_cc_sptr make_pulse_blanking_cc(
float pfa, float pfa,

View File

@ -21,11 +21,7 @@
#ifndef GNSS_SDR_BYTE_X2_TO_COMPLEX_BYTE_H #ifndef GNSS_SDR_BYTE_X2_TO_COMPLEX_BYTE_H
#define GNSS_SDR_BYTE_X2_TO_COMPLEX_BYTE_H #define GNSS_SDR_BYTE_X2_TO_COMPLEX_BYTE_H
#if GNURADIO_USES_STD_POINTERS #include "gnss_block_interface.h"
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
@ -34,14 +30,10 @@
/** \addtogroup Algorithm_libs algorithms_libs /** \addtogroup Algorithm_libs algorithms_libs
* \{ */ * \{ */
class byte_x2_to_complex_byte; class byte_x2_to_complex_byte;
#if GNURADIO_USES_STD_POINTERS using byte_x2_to_complex_byte_sptr = gnss_shared_ptr<byte_x2_to_complex_byte>;
using byte_x2_to_complex_byte_sptr = std::shared_ptr<byte_x2_to_complex_byte>;
#else
using byte_x2_to_complex_byte_sptr = boost::shared_ptr<byte_x2_to_complex_byte>;
#endif
byte_x2_to_complex_byte_sptr make_byte_x2_to_complex_byte(); byte_x2_to_complex_byte_sptr make_byte_x2_to_complex_byte();

View File

@ -21,12 +21,7 @@
#ifndef GNSS_SDR_COMPLEX_BYTE_TO_FLOAT_X2_H #ifndef GNSS_SDR_COMPLEX_BYTE_TO_FLOAT_X2_H
#define GNSS_SDR_COMPLEX_BYTE_TO_FLOAT_X2_H #define GNSS_SDR_COMPLEX_BYTE_TO_FLOAT_X2_H
#include "gnss_block_interface.h"
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
@ -38,11 +33,7 @@
class complex_byte_to_float_x2; class complex_byte_to_float_x2;
#if GNURADIO_USES_STD_POINTERS using complex_byte_to_float_x2_sptr = gnss_shared_ptr<complex_byte_to_float_x2>;
using complex_byte_to_float_x2_sptr = std::shared_ptr<complex_byte_to_float_x2>;
#else
using complex_byte_to_float_x2_sptr = boost::shared_ptr<complex_byte_to_float_x2>;
#endif
complex_byte_to_float_x2_sptr make_complex_byte_to_float_x2(); complex_byte_to_float_x2_sptr make_complex_byte_to_float_x2();

View File

@ -21,11 +21,7 @@
#ifndef GNSS_SDR_COMPLEX_FLOAT_TO_COMPLEX_BYTE_H #ifndef GNSS_SDR_COMPLEX_FLOAT_TO_COMPLEX_BYTE_H
#define GNSS_SDR_COMPLEX_FLOAT_TO_COMPLEX_BYTE_H #define GNSS_SDR_COMPLEX_FLOAT_TO_COMPLEX_BYTE_H
#if GNURADIO_USES_STD_POINTERS #include "gnss_block_interface.h"
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
@ -37,11 +33,7 @@
class complex_float_to_complex_byte; class complex_float_to_complex_byte;
#if GNURADIO_USES_STD_POINTERS using complex_float_to_complex_byte_sptr = gnss_shared_ptr<complex_float_to_complex_byte>;
using complex_float_to_complex_byte_sptr = std::shared_ptr<complex_float_to_complex_byte>;
#else
using complex_float_to_complex_byte_sptr = boost::shared_ptr<complex_float_to_complex_byte>;
#endif
complex_float_to_complex_byte_sptr make_complex_float_to_complex_byte(); complex_float_to_complex_byte_sptr make_complex_float_to_complex_byte();

View File

@ -21,11 +21,7 @@
#ifndef GNSS_SDR_CONJUGATE_CC_H #ifndef GNSS_SDR_CONJUGATE_CC_H
#define GNSS_SDR_CONJUGATE_CC_H #define GNSS_SDR_CONJUGATE_CC_H
#if GNURADIO_USES_STD_POINTERS #include "gnss_block_interface.h"
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
@ -37,11 +33,7 @@
class conjugate_cc; class conjugate_cc;
#if GNURADIO_USES_STD_POINTERS using conjugate_cc_sptr = gnss_shared_ptr<conjugate_cc>;
using conjugate_cc_sptr = std::shared_ptr<conjugate_cc>;
#else
using conjugate_cc_sptr = boost::shared_ptr<conjugate_cc>;
#endif
conjugate_cc_sptr make_conjugate_cc(); conjugate_cc_sptr make_conjugate_cc();

View File

@ -21,13 +21,9 @@
#ifndef GNSS_SDR_CONJUGATE_IC_H #ifndef GNSS_SDR_CONJUGATE_IC_H
#define GNSS_SDR_CONJUGATE_IC_H #define GNSS_SDR_CONJUGATE_IC_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Algorithms_Library /** \addtogroup Algorithms_Library
* \{ */ * \{ */
@ -37,11 +33,7 @@
class conjugate_ic; class conjugate_ic;
#if GNURADIO_USES_STD_POINTERS using conjugate_ic_sptr = gnss_shared_ptr<conjugate_ic>;
using conjugate_ic_sptr = std::shared_ptr<conjugate_ic>;
#else
using conjugate_ic_sptr = boost::shared_ptr<conjugate_ic>;
#endif
conjugate_ic_sptr make_conjugate_ic(); conjugate_ic_sptr make_conjugate_ic();

View File

@ -21,11 +21,7 @@
#ifndef GNSS_SDR_CONJUGATE_SC_H #ifndef GNSS_SDR_CONJUGATE_SC_H
#define GNSS_SDR_CONJUGATE_SC_H #define GNSS_SDR_CONJUGATE_SC_H
#if GNURADIO_USES_STD_POINTERS #include "gnss_block_interface.h"
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
@ -37,11 +33,7 @@
class conjugate_sc; class conjugate_sc;
#if GNURADIO_USES_STD_POINTERS using conjugate_sc_sptr = gnss_shared_ptr<conjugate_sc>;
using conjugate_sc_sptr = std::shared_ptr<conjugate_sc>;
#else
using conjugate_sc_sptr = boost::shared_ptr<conjugate_sc>;
#endif
conjugate_sc_sptr make_conjugate_sc(); conjugate_sc_sptr make_conjugate_sc();

View File

@ -21,12 +21,7 @@
#ifndef GNSS_SDR_CSHORT_TO_FLOAT_X2_H #ifndef GNSS_SDR_CSHORT_TO_FLOAT_X2_H
#define GNSS_SDR_CSHORT_TO_FLOAT_X2_H #define GNSS_SDR_CSHORT_TO_FLOAT_X2_H
#include "gnss_block_interface.h"
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
@ -38,11 +33,7 @@
class cshort_to_float_x2; class cshort_to_float_x2;
#if GNURADIO_USES_STD_POINTERS using cshort_to_float_x2_sptr = gnss_shared_ptr<cshort_to_float_x2>;
using cshort_to_float_x2_sptr = std::shared_ptr<cshort_to_float_x2>;
#else
using cshort_to_float_x2_sptr = boost::shared_ptr<cshort_to_float_x2>;
#endif
cshort_to_float_x2_sptr make_cshort_to_float_x2(); cshort_to_float_x2_sptr make_cshort_to_float_x2();

View File

@ -21,11 +21,7 @@
#define GNSS_SDR_SHORT_X2_TO_CSHORT_H #define GNSS_SDR_SHORT_X2_TO_CSHORT_H
#if GNURADIO_USES_STD_POINTERS #include "gnss_block_interface.h"
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
@ -37,11 +33,7 @@
class short_x2_to_cshort; class short_x2_to_cshort;
#if GNURADIO_USES_STD_POINTERS using short_x2_to_cshort_sptr = gnss_shared_ptr<short_x2_to_cshort>;
using short_x2_to_cshort_sptr = std::shared_ptr<short_x2_to_cshort>;
#else
using short_x2_to_cshort_sptr = boost::shared_ptr<short_x2_to_cshort>;
#endif
short_x2_to_cshort_sptr make_short_x2_to_cshort(); short_x2_to_cshort_sptr make_short_x2_to_cshort();

View File

@ -48,6 +48,11 @@ target_link_libraries(obs_gr_blocks
Matio::matio Matio::matio
) )
target_include_directories(obs_gr_blocks
PUBLIC
${CMAKE_SOURCE_DIR}/src/core/interfaces
)
if(GNURADIO_USES_STD_POINTERS) if(GNURADIO_USES_STD_POINTERS)
target_compile_definitions(obs_gr_blocks target_compile_definitions(obs_gr_blocks
PUBLIC -DGNURADIO_USES_STD_POINTERS=1 PUBLIC -DGNURADIO_USES_STD_POINTERS=1

View File

@ -23,6 +23,7 @@
#ifndef GNSS_SDR_HYBRID_OBSERVABLES_GS_H #ifndef GNSS_SDR_HYBRID_OBSERVABLES_GS_H
#define GNSS_SDR_HYBRID_OBSERVABLES_GS_H #define GNSS_SDR_HYBRID_OBSERVABLES_GS_H
#include "gnss_block_interface.h"
#include "obs_conf.h" #include "obs_conf.h"
#include <boost/circular_buffer.hpp> // for boost::circular_buffer #include <boost/circular_buffer.hpp> // for boost::circular_buffer
#include <gnuradio/block.h> // for block #include <gnuradio/block.h> // for block
@ -35,10 +36,6 @@
#include <string> // for std::string #include <string> // for std::string
#include <typeinfo> // for typeid #include <typeinfo> // for typeid
#include <vector> // for std::vector #include <vector> // for std::vector
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Observables /** \addtogroup Observables
* \{ */ * \{ */
@ -46,17 +43,14 @@
* GNU Radio blocks for the computation of GNSS observables * GNU Radio blocks for the computation of GNSS observables
* \{ */ * \{ */
class Gnss_Synchro; class Gnss_Synchro;
class hybrid_observables_gs; class hybrid_observables_gs;
template <class T> template <class T>
class Gnss_circular_deque; class Gnss_circular_deque;
#if GNURADIO_USES_STD_POINTERS using hybrid_observables_gs_sptr = gnss_shared_ptr<hybrid_observables_gs>;
using hybrid_observables_gs_sptr = std::shared_ptr<hybrid_observables_gs>;
#else
using hybrid_observables_gs_sptr = boost::shared_ptr<hybrid_observables_gs>;
#endif
hybrid_observables_gs_sptr hybrid_observables_gs_make(const Obs_Conf& conf_); hybrid_observables_gs_sptr hybrid_observables_gs_make(const Obs_Conf& conf_);

View File

@ -53,6 +53,11 @@ if(GNURADIO_USES_STD_POINTERS)
) )
endif() endif()
target_include_directories(resampler_gr_blocks
PUBLIC
${CMAKE_SOURCE_DIR}/src/core/interfaces
)
if(ENABLE_CLANG_TIDY) if(ENABLE_CLANG_TIDY)
if(CLANG_TIDY_EXE) if(CLANG_TIDY_EXE)
set_target_properties(resampler_gr_blocks set_target_properties(resampler_gr_blocks

View File

@ -22,13 +22,9 @@
#ifndef GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CB_H #ifndef GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CB_H
#define GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CB_H #define GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CB_H
#include "gnss_block_interface.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <cstdint> #include <cstdint>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Resampler /** \addtogroup Resampler
* \{ */ * \{ */
@ -39,11 +35,7 @@
class direct_resampler_conditioner_cb; class direct_resampler_conditioner_cb;
#if GNURADIO_USES_STD_POINTERS using direct_resampler_conditioner_cb_sptr = gnss_shared_ptr<direct_resampler_conditioner_cb>;
using direct_resampler_conditioner_cb_sptr = std::shared_ptr<direct_resampler_conditioner_cb>;
#else
using direct_resampler_conditioner_cb_sptr = boost::shared_ptr<direct_resampler_conditioner_cb>;
#endif
direct_resampler_conditioner_cb_sptr direct_resampler_make_conditioner_cb( direct_resampler_conditioner_cb_sptr direct_resampler_make_conditioner_cb(
double sample_freq_in, double sample_freq_in,

View File

@ -28,13 +28,9 @@
#ifndef GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CC_H #ifndef GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CC_H
#define GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CC_H #define GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CC_H
#include "gnss_block_interface.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <cstdint> #include <cstdint>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Resampler /** \addtogroup Resampler
* \{ */ * \{ */
@ -44,11 +40,7 @@
class direct_resampler_conditioner_cc; class direct_resampler_conditioner_cc;
#if GNURADIO_USES_STD_POINTERS using direct_resampler_conditioner_cc_sptr = gnss_shared_ptr<direct_resampler_conditioner_cc>;
using direct_resampler_conditioner_cc_sptr = std::shared_ptr<direct_resampler_conditioner_cc>;
#else
using direct_resampler_conditioner_cc_sptr = boost::shared_ptr<direct_resampler_conditioner_cc>;
#endif
direct_resampler_conditioner_cc_sptr direct_resampler_make_conditioner_cc( direct_resampler_conditioner_cc_sptr direct_resampler_make_conditioner_cc(
double sample_freq_in, double sample_freq_in,

View File

@ -22,13 +22,9 @@
#ifndef GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CS_H #ifndef GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CS_H
#define GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CS_H #define GNSS_SDR_DIRECT_RESAMPLER_CONDITIONER_CS_H
#include "gnss_block_interface.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <cstdint> #include <cstdint>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Resampler /** \addtogroup Resampler
* \{ */ * \{ */
@ -37,11 +33,8 @@
class direct_resampler_conditioner_cs; class direct_resampler_conditioner_cs;
#if GNURADIO_USES_STD_POINTERS
using direct_resampler_conditioner_cs_sptr = std::shared_ptr<direct_resampler_conditioner_cs>; using direct_resampler_conditioner_cs_sptr = gnss_shared_ptr<direct_resampler_conditioner_cs>;
#else
using direct_resampler_conditioner_cs_sptr = boost::shared_ptr<direct_resampler_conditioner_cs>;
#endif
direct_resampler_conditioner_cs_sptr direct_resampler_make_conditioner_cs( direct_resampler_conditioner_cs_sptr direct_resampler_make_conditioner_cs(
double sample_freq_in, double sample_freq_in,

View File

@ -72,11 +72,7 @@ public:
gr::basic_block_sptr get_right_block() override; gr::basic_block_sptr get_right_block() override;
private: private:
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> gen_source_;
std::shared_ptr<gr::block> gen_source_;
#else
boost::shared_ptr<gr::block> gen_source_;
#endif
gr::blocks::vector_to_stream::sptr vector_to_stream_; gr::blocks::vector_to_stream::sptr vector_to_stream_;
gr::blocks::file_sink::sptr file_sink_; gr::blocks::file_sink::sptr file_sink_;
std::string role_; std::string role_;

View File

@ -38,6 +38,11 @@ if(GNURADIO_USES_STD_POINTERS)
) )
endif() endif()
target_include_directories(signal_generator_gr_blocks
PUBLIC
${CMAKE_SOURCE_DIR}/src/core/interfaces
)
# Workaround for CentOS 7 # Workaround for CentOS 7
if((CMAKE_CXX_COMPILER_ID STREQUAL "GNU") AND if((CMAKE_CXX_COMPILER_ID STREQUAL "GNU") AND
(CMAKE_CXX_COMPILER_VERSION VERSION_LESS "5.0")) (CMAKE_CXX_COMPILER_VERSION VERSION_LESS "5.0"))

View File

@ -20,34 +20,16 @@
#ifndef GNSS_SDR_SIGNAL_GENERATOR_C_H #ifndef GNSS_SDR_SIGNAL_GENERATOR_C_H
#define GNSS_SDR_SIGNAL_GENERATOR_C_H #define GNSS_SDR_SIGNAL_GENERATOR_C_H
#include "gnss_block_interface.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <random> #include <random>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
class signal_generator_c; class signal_generator_c;
/* using signal_generator_c_sptr = gnss_shared_ptr<signal_generator_c>;
* We use std::shared_ptr's instead of raw pointers for all access
* to gr_blocks (and many other data structures). The shared_ptr gets
* us transparent reference counting, which greatly simplifies storage
* management issues.
*
* See https://www.boost.org/doc/libs/release/libs/smart_ptr/doc/html/smart_ptr.html
*
* As a convention, the _sptr suffix indicates a std::shared_ptr
*/
#if GNURADIO_USES_STD_POINTERS
using signal_generator_c_sptr = std::shared_ptr<signal_generator_c>;
#else
using signal_generator_c_sptr = boost::shared_ptr<signal_generator_c>;
#endif
/*! /*!
* \brief Return a shared_ptr to a new instance of gen_source. * \brief Return a shared_ptr to a new instance of gen_source.

View File

@ -27,14 +27,9 @@
#include <gnuradio/blocks/file_sink.h> #include <gnuradio/blocks/file_sink.h>
#include <gnuradio/blocks/null_sink.h> #include <gnuradio/blocks/null_sink.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <memory>
#include <stdexcept> #include <stdexcept>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -83,13 +78,8 @@ public:
private: private:
Gr_Complex_Ip_Packet_Source::sptr udp_gnss_rx_source_; Gr_Complex_Ip_Packet_Source::sptr udp_gnss_rx_source_;
#if GNURADIO_USES_STD_POINTERS std::vector<gnss_shared_ptr<gr::block>> null_sinks_;
std::vector<std::shared_ptr<gr::block>> null_sinks_; std::vector<gnss_shared_ptr<gr::block>> file_sink_;
std::vector<std::shared_ptr<gr::block>> file_sink_;
#else
std::vector<boost::shared_ptr<gr::block>> null_sinks_;
std::vector<boost::shared_ptr<gr::block>> file_sink_;
#endif
std::string role_; std::string role_;
std::string item_type_; std::string item_type_;

View File

@ -32,12 +32,7 @@
#include <gnuradio/hier_block2.h> #include <gnuradio/hier_block2.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <memory>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source Signal Source /** \addtogroup Signal_Source Signal Source
* Classes for Signal Source management. * Classes for Signal Source management.
@ -112,11 +107,7 @@ public:
private: private:
gr::blocks::file_source::sptr file_source_; gr::blocks::file_source::sptr file_source_;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> valve_;
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr sink_; gr::blocks::file_sink::sptr sink_;
gr::blocks::throttle::sptr throttle_; gr::blocks::throttle::sptr throttle_;

View File

@ -33,12 +33,8 @@
#include "concurrent_queue.h" #include "concurrent_queue.h"
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <memory>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -82,12 +78,7 @@ public:
private: private:
gr::iio::fmcomms2_source_f32c::sptr fmcomms2_source_f32c_; gr::iio::fmcomms2_source_f32c::sptr fmcomms2_source_f32c_;
gnss_shared_ptr<gr::block> valve_;
#if GNURADIO_USES_STD_POINTERS
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr file_sink_; gr::blocks::file_sink::sptr file_sink_;
std::string role_; std::string role_;

View File

@ -32,13 +32,8 @@
#include <gnuradio/hier_block2.h> #include <gnuradio/hier_block2.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <memory>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
@ -112,11 +107,7 @@ public:
private: private:
std::vector<gr::blocks::file_source::sptr> file_source_vec_; std::vector<gr::blocks::file_source::sptr> file_source_vec_;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> valve_;
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr sink_; gr::blocks::file_sink::sptr sink_;
std::vector<gr::blocks::throttle::sptr> throttle_vec_; std::vector<gr::blocks::throttle::sptr> throttle_vec_;
std::vector<std::string> filename_vec_; std::vector<std::string> filename_vec_;

View File

@ -32,12 +32,7 @@
#include <gnuradio/blocks/throttle.h> #include <gnuradio/blocks/throttle.h>
#include <gnuradio/hier_block2.h> #include <gnuradio/hier_block2.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <memory>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -109,11 +104,7 @@ public:
private: private:
gr::blocks::file_source::sptr file_source_; gr::blocks::file_source::sptr file_source_;
unpack_byte_2bit_samples_sptr unpack_byte_; unpack_byte_2bit_samples_sptr unpack_byte_;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> valve_;
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr sink_; gr::blocks::file_sink::sptr sink_;
gr::blocks::throttle::sptr throttle_; gr::blocks::throttle::sptr throttle_;
uint64_t samples_; uint64_t samples_;

View File

@ -31,16 +31,13 @@
#include <osmosdr/source.h> #include <osmosdr/source.h>
#include <stdexcept> #include <stdexcept>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
/** \addtogroup Signal_Source_adapters /** \addtogroup Signal_Source_adapters
* \{ */ * \{ */
class ConfigurationInterface; class ConfigurationInterface;
/*! /*!
@ -84,11 +81,7 @@ private:
void driver_instance(); void driver_instance();
osmosdr::source::sptr osmosdr_source_; osmosdr::source::sptr osmosdr_source_;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> valve_;
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr file_sink_; gr::blocks::file_sink::sptr file_sink_;
std::string role_; std::string role_;

View File

@ -32,12 +32,8 @@
#include "concurrent_queue.h" #include "concurrent_queue.h"
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <memory>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -83,11 +79,7 @@ public:
private: private:
gr::iio::pluto_source::sptr plutosdr_source_; gr::iio::pluto_source::sptr plutosdr_source_;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> valve_;
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr file_sink_; gr::blocks::file_sink::sptr file_sink_;
std::string role_; std::string role_;

View File

@ -28,13 +28,8 @@
#include <gnuradio/blocks/file_sink.h> #include <gnuradio/blocks/file_sink.h>
#include <gnuradio/blocks/float_to_complex.h> #include <gnuradio/blocks/float_to_complex.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <memory>
#include <stdexcept> #include <stdexcept>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
@ -89,11 +84,7 @@ private:
rtl_tcp_signal_source_c_sptr signal_source_; rtl_tcp_signal_source_c_sptr signal_source_;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> valve_;
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr file_sink_; gr::blocks::file_sink::sptr file_sink_;
std::string role_; std::string role_;

View File

@ -30,12 +30,7 @@
#include <gnuradio/hier_block2.h> #include <gnuradio/hier_block2.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <memory>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
@ -110,11 +105,7 @@ public:
private: private:
gr::blocks::file_source::sptr file_source_; gr::blocks::file_source::sptr file_source_;
unpack_intspir_1bit_samples_sptr unpack_intspir_; unpack_intspir_1bit_samples_sptr unpack_intspir_;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> valve_;
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr sink_; gr::blocks::file_sink::sptr sink_;
gr::blocks::throttle::sptr throttle_; gr::blocks::throttle::sptr throttle_;
std::string filename_; std::string filename_;

View File

@ -34,13 +34,8 @@
#include <gnuradio/hier_block2.h> #include <gnuradio/hier_block2.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <memory>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
@ -111,11 +106,7 @@ public:
private: private:
gr::blocks::file_source::sptr file_source_; gr::blocks::file_source::sptr file_source_;
gr::blocks::deinterleave::sptr deint_; gr::blocks::deinterleave::sptr deint_;
#if GNURADIO_USES_STD_POINTERS std::vector<gnss_shared_ptr<gr::block>> valve_vec_;
std::vector<std::shared_ptr<gr::block>> valve_vec_;
#else
std::vector<boost::shared_ptr<gr::block>> valve_vec_;
#endif
std::vector<gr::blocks::endian_swap::sptr> endian_vec_; std::vector<gr::blocks::endian_swap::sptr> endian_vec_;
std::vector<gr::blocks::null_sink::sptr> null_sinks_; std::vector<gr::blocks::null_sink::sptr> null_sinks_;
std::vector<unpack_spir_gss6450_samples_sptr> unpack_spir_vec_; std::vector<unpack_spir_gss6450_samples_sptr> unpack_spir_vec_;

View File

@ -33,12 +33,7 @@
#include <gnuradio/hier_block2.h> #include <gnuradio/hier_block2.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <memory>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -114,11 +109,7 @@ private:
gr::blocks::file_source::sptr file_source_; gr::blocks::file_source::sptr file_source_;
gr::blocks::interleaved_short_to_complex::sptr inter_shorts_to_cpx_; gr::blocks::interleaved_short_to_complex::sptr inter_shorts_to_cpx_;
unpack_byte_2bit_cpx_samples_sptr unpack_byte_; unpack_byte_2bit_cpx_samples_sptr unpack_byte_;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> valve_;
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr sink_; gr::blocks::file_sink::sptr sink_;
gr::blocks::throttle::sptr throttle_; gr::blocks::throttle::sptr throttle_;
std::string filename_; std::string filename_;

View File

@ -34,12 +34,7 @@
#include <gnuradio/hier_block2.h> #include <gnuradio/hier_block2.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <memory>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
@ -134,11 +129,7 @@ private:
gr::blocks::file_source::sptr file_source_; gr::blocks::file_source::sptr file_source_;
unpack_2bit_samples_sptr unpack_samples_; unpack_2bit_samples_sptr unpack_samples_;
gr::basic_block_sptr char_to_float_; gr::basic_block_sptr char_to_float_;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<gr::block> valve_;
std::shared_ptr<gr::block> valve_;
#else
boost::shared_ptr<gr::block> valve_;
#endif
gr::blocks::file_sink::sptr sink_; gr::blocks::file_sink::sptr sink_;
gr::blocks::throttle::sptr throttle_; gr::blocks::throttle::sptr throttle_;
std::string filename_; std::string filename_;

View File

@ -27,13 +27,8 @@
#include <gnuradio/uhd/usrp_source.h> #include <gnuradio/uhd/usrp_source.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <memory>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
@ -81,11 +76,8 @@ public:
private: private:
gr::uhd::usrp_source::sptr uhd_source_; gr::uhd::usrp_source::sptr uhd_source_;
#if GNURADIO_USES_STD_POINTERS
std::vector<std::shared_ptr<gr::block>> valve_; std::vector<gnss_shared_ptr<gr::block>> valve_;
#else
std::vector<boost::shared_ptr<gr::block>> valve_;
#endif
std::vector<gr::blocks::file_sink::sptr> file_sink_; std::vector<gr::blocks::file_sink::sptr> file_sink_;
std::vector<double> freq_; std::vector<double> freq_;
std::vector<double> gain_; std::vector<double> gain_;

View File

@ -22,6 +22,7 @@
#ifndef GNSS_SDR_GR_COMPLEX_IP_PACKET_SOURCE_H #ifndef GNSS_SDR_GR_COMPLEX_IP_PACKET_SOURCE_H
#define GNSS_SDR_GR_COMPLEX_IP_PACKET_SOURCE_H #define GNSS_SDR_GR_COMPLEX_IP_PACKET_SOURCE_H
#include "gnss_block_interface.h"
#include <boost/thread.hpp> #include <boost/thread.hpp>
#include <gnuradio/sync_block.h> #include <gnuradio/sync_block.h>
#include <arpa/inet.h> #include <arpa/inet.h>
@ -31,11 +32,6 @@
#include <pcap.h> #include <pcap.h>
#include <string> #include <string>
#include <sys/ioctl.h> #include <sys/ioctl.h>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -47,11 +43,7 @@
class Gr_Complex_Ip_Packet_Source : virtual public gr::sync_block class Gr_Complex_Ip_Packet_Source : virtual public gr::sync_block
{ {
public: public:
#if GNURADIO_USES_STD_POINTERS using sptr = gnss_shared_ptr<Gr_Complex_Ip_Packet_Source>;
typedef std::shared_ptr<Gr_Complex_Ip_Packet_Source> sptr;
#else
typedef boost::shared_ptr<Gr_Complex_Ip_Packet_Source> sptr;
#endif
static sptr make(std::string src_device, static sptr make(std::string src_device,
const std::string &origin_address, const std::string &origin_address,
int udp_port, int udp_port,

View File

@ -21,16 +21,12 @@
#define GNSS_SDR_LABSAT23_SOURCE_H #define GNSS_SDR_LABSAT23_SOURCE_H
#include "concurrent_queue.h" #include "concurrent_queue.h"
#include "gnss_block_interface.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstdint> #include <cstdint>
#include <fstream> #include <fstream>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -40,11 +36,7 @@
class labsat23_source; class labsat23_source;
#if GNURADIO_USES_STD_POINTERS using labsat23_source_sptr = gnss_shared_ptr<labsat23_source>;
using labsat23_source_sptr = std::shared_ptr<labsat23_source>;
#else
using labsat23_source_sptr = boost::shared_ptr<labsat23_source>;
#endif
labsat23_source_sptr labsat23_make_source_sptr( labsat23_source_sptr labsat23_make_source_sptr(
const char *signal_file_basename, const char *signal_file_basename,

View File

@ -27,6 +27,7 @@
#ifndef GNSS_SDR_RTL_TCP_SIGNAL_SOURCE_C_H #ifndef GNSS_SDR_RTL_TCP_SIGNAL_SOURCE_C_H
#define GNSS_SDR_RTL_TCP_SIGNAL_SOURCE_C_H #define GNSS_SDR_RTL_TCP_SIGNAL_SOURCE_C_H
#include "gnss_block_interface.h"
#include "rtl_tcp_dongle_info.h" #include "rtl_tcp_dongle_info.h"
#include <boost/array.hpp> #include <boost/array.hpp>
#include <boost/asio.hpp> #include <boost/asio.hpp>
@ -37,11 +38,6 @@
#include <cstdint> #include <cstdint>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
@ -52,11 +48,7 @@
class rtl_tcp_signal_source_c; class rtl_tcp_signal_source_c;
#if GNURADIO_USES_STD_POINTERS using rtl_tcp_signal_source_c_sptr = gnss_shared_ptr<rtl_tcp_signal_source_c>;
using rtl_tcp_signal_source_c_sptr = std::shared_ptr<rtl_tcp_signal_source_c>;
#else
using rtl_tcp_signal_source_c_sptr = boost::shared_ptr<rtl_tcp_signal_source_c>;
#endif
#if USE_BOOST_ASIO_IO_CONTEXT #if USE_BOOST_ASIO_IO_CONTEXT
using b_io_context = boost::asio::io_context; using b_io_context = boost::asio::io_context;

View File

@ -57,14 +57,10 @@
#ifndef GNSS_SDR_UNPACK_2BIT_SAMPLES_H #ifndef GNSS_SDR_UNPACK_2BIT_SAMPLES_H
#define GNSS_SDR_UNPACK_2BIT_SAMPLES_H #define GNSS_SDR_UNPACK_2BIT_SAMPLES_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_interpolator.h> #include <gnuradio/sync_interpolator.h>
#include <cstdint> #include <cstdint>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -74,11 +70,7 @@
class unpack_2bit_samples; class unpack_2bit_samples;
#if GNURADIO_USES_STD_POINTERS using unpack_2bit_samples_sptr = gnss_shared_ptr<unpack_2bit_samples>;
using unpack_2bit_samples_sptr = std::shared_ptr<unpack_2bit_samples>;
#else
using unpack_2bit_samples_sptr = boost::shared_ptr<unpack_2bit_samples>;
#endif
unpack_2bit_samples_sptr make_unpack_2bit_samples( unpack_2bit_samples_sptr make_unpack_2bit_samples(
bool big_endian_bytes, bool big_endian_bytes,

View File

@ -24,12 +24,8 @@
#ifndef GNSS_SDR_UNPACK_BYTE_2BIT_CPX_SAMPLES_H #ifndef GNSS_SDR_UNPACK_BYTE_2BIT_CPX_SAMPLES_H
#define GNSS_SDR_UNPACK_BYTE_2BIT_CPX_SAMPLES_H #define GNSS_SDR_UNPACK_BYTE_2BIT_CPX_SAMPLES_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_interpolator.h> #include <gnuradio/sync_interpolator.h>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -39,11 +35,7 @@
class unpack_byte_2bit_cpx_samples; class unpack_byte_2bit_cpx_samples;
#if GNURADIO_USES_STD_POINTERS using unpack_byte_2bit_cpx_samples_sptr = gnss_shared_ptr<unpack_byte_2bit_cpx_samples>;
using unpack_byte_2bit_cpx_samples_sptr = std::shared_ptr<unpack_byte_2bit_cpx_samples>;
#else
using unpack_byte_2bit_cpx_samples_sptr = boost::shared_ptr<unpack_byte_2bit_cpx_samples>;
#endif
unpack_byte_2bit_cpx_samples_sptr make_unpack_byte_2bit_cpx_samples(); unpack_byte_2bit_cpx_samples_sptr make_unpack_byte_2bit_cpx_samples();

View File

@ -20,12 +20,9 @@
#ifndef GNSS_SDR_UNPACK_BYTE_2BIT_SAMPLES_H #ifndef GNSS_SDR_UNPACK_BYTE_2BIT_SAMPLES_H
#define GNSS_SDR_UNPACK_BYTE_2BIT_SAMPLES_H #define GNSS_SDR_UNPACK_BYTE_2BIT_SAMPLES_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_interpolator.h> #include <gnuradio/sync_interpolator.h>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -34,11 +31,7 @@
class unpack_byte_2bit_samples; class unpack_byte_2bit_samples;
#if GNURADIO_USES_STD_POINTERS using unpack_byte_2bit_samples_sptr = gnss_shared_ptr<unpack_byte_2bit_samples>;
using unpack_byte_2bit_samples_sptr = std::shared_ptr<unpack_byte_2bit_samples>;
#else
using unpack_byte_2bit_samples_sptr = boost::shared_ptr<unpack_byte_2bit_samples>;
#endif
unpack_byte_2bit_samples_sptr make_unpack_byte_2bit_samples(); unpack_byte_2bit_samples_sptr make_unpack_byte_2bit_samples();

View File

@ -20,12 +20,8 @@
#ifndef GNSS_SDR_UNPACK_INTSPIR_1BIT_SAMPLES_H #ifndef GNSS_SDR_UNPACK_INTSPIR_1BIT_SAMPLES_H
#define GNSS_SDR_UNPACK_INTSPIR_1BIT_SAMPLES_H #define GNSS_SDR_UNPACK_INTSPIR_1BIT_SAMPLES_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_interpolator.h> #include <gnuradio/sync_interpolator.h>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
@ -36,11 +32,7 @@
class unpack_intspir_1bit_samples; class unpack_intspir_1bit_samples;
#if GNURADIO_USES_STD_POINTERS using unpack_intspir_1bit_samples_sptr = gnss_shared_ptr<unpack_intspir_1bit_samples>;
using unpack_intspir_1bit_samples_sptr = std::shared_ptr<unpack_intspir_1bit_samples>;
#else
using unpack_intspir_1bit_samples_sptr = boost::shared_ptr<unpack_intspir_1bit_samples>;
#endif
unpack_intspir_1bit_samples_sptr make_unpack_intspir_1bit_samples(); unpack_intspir_1bit_samples_sptr make_unpack_intspir_1bit_samples();

View File

@ -21,12 +21,8 @@
#ifndef GNSS_SDR_UNPACK_SPIR_GSS6450_SAMPLES_H #ifndef GNSS_SDR_UNPACK_SPIR_GSS6450_SAMPLES_H
#define GNSS_SDR_UNPACK_SPIR_GSS6450_SAMPLES_H #define GNSS_SDR_UNPACK_SPIR_GSS6450_SAMPLES_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_interpolator.h> #include <gnuradio/sync_interpolator.h>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -36,11 +32,7 @@
class unpack_spir_gss6450_samples; class unpack_spir_gss6450_samples;
#if GNURADIO_USES_STD_POINTERS using unpack_spir_gss6450_samples_sptr = gnss_shared_ptr<unpack_spir_gss6450_samples>;
using unpack_spir_gss6450_samples_sptr = std::shared_ptr<unpack_spir_gss6450_samples>;
#else
using unpack_spir_gss6450_samples_sptr = boost::shared_ptr<unpack_spir_gss6450_samples>;
#endif
unpack_spir_gss6450_samples_sptr make_unpack_spir_gss6450_samples(int adc_nbit_); unpack_spir_gss6450_samples_sptr make_unpack_spir_gss6450_samples(int adc_nbit_);

View File

@ -67,6 +67,7 @@ target_link_libraries(signal_source_libs
target_include_directories(signal_source_libs target_include_directories(signal_source_libs
PUBLIC PUBLIC
${CMAKE_SOURCE_DIR}/src/core/receiver ${CMAKE_SOURCE_DIR}/src/core/receiver
${CMAKE_SOURCE_DIR}/src/core/interfaces
) )
if(GNURADIO_USES_STD_POINTERS) if(GNURADIO_USES_STD_POINTERS)

View File

@ -42,33 +42,18 @@ Gnss_Sdr_Valve::Gnss_Sdr_Valve(size_t sizeof_stream_item,
} }
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(size_t sizeof_stream_item, uint64_t nitems, Concurrent_Queue<pmt::pmt_t>* queue, bool stop_flowgraph)
std::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(size_t sizeof_stream_item, uint64_t nitems, Concurrent_Queue<pmt::pmt_t>* queue, bool stop_flowgraph)
{ {
std::shared_ptr<Gnss_Sdr_Valve> valve_(new Gnss_Sdr_Valve(sizeof_stream_item, nitems, queue, stop_flowgraph)); gnss_shared_ptr<Gnss_Sdr_Valve> valve_(new Gnss_Sdr_Valve(sizeof_stream_item, nitems, queue, stop_flowgraph));
return valve_; return valve_;
} }
std::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(size_t sizeof_stream_item, uint64_t nitems, Concurrent_Queue<pmt::pmt_t>* queue) gnss_shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(size_t sizeof_stream_item, uint64_t nitems, Concurrent_Queue<pmt::pmt_t>* queue)
{ {
std::shared_ptr<Gnss_Sdr_Valve> valve_(new Gnss_Sdr_Valve(sizeof_stream_item, nitems, queue, true)); gnss_shared_ptr<Gnss_Sdr_Valve> valve_(new Gnss_Sdr_Valve(sizeof_stream_item, nitems, queue, true));
return valve_; return valve_;
} }
#else
boost::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(size_t sizeof_stream_item, uint64_t nitems, Concurrent_Queue<pmt::pmt_t>* queue, bool stop_flowgraph)
{
boost::shared_ptr<Gnss_Sdr_Valve> valve_(new Gnss_Sdr_Valve(sizeof_stream_item, nitems, queue, stop_flowgraph));
return valve_;
}
boost::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(size_t sizeof_stream_item, uint64_t nitems, Concurrent_Queue<pmt::pmt_t>* queue)
{
boost::shared_ptr<Gnss_Sdr_Valve> valve_(new Gnss_Sdr_Valve(sizeof_stream_item, nitems, queue, true));
return valve_;
}
#endif
void Gnss_Sdr_Valve::open_valve() void Gnss_Sdr_Valve::open_valve()

View File

@ -24,16 +24,12 @@
#define GNSS_SDR_GNSS_SDR_VALVE_H #define GNSS_SDR_GNSS_SDR_VALVE_H
#include "concurrent_queue.h" #include "concurrent_queue.h"
#include "gnss_block_interface.h"
#include <gnuradio/sync_block.h> // for sync_block #include <gnuradio/sync_block.h> // for sync_block
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <cstddef> // for size_t #include <cstddef> // for size_t
#include <cstdint> #include <cstdint>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Signal_Source /** \addtogroup Signal_Source
* \{ */ * \{ */
@ -43,29 +39,16 @@
class Gnss_Sdr_Valve; class Gnss_Sdr_Valve;
#if GNURADIO_USES_STD_POINTERS gnss_shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
std::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
size_t sizeof_stream_item, size_t sizeof_stream_item,
uint64_t nitems, uint64_t nitems,
Concurrent_Queue<pmt::pmt_t>* queue); Concurrent_Queue<pmt::pmt_t>* queue);
std::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve( gnss_shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
size_t sizeof_stream_item, size_t sizeof_stream_item,
uint64_t nitems, uint64_t nitems,
Concurrent_Queue<pmt::pmt_t>* queue, Concurrent_Queue<pmt::pmt_t>* queue,
bool stop_flowgraph); bool stop_flowgraph);
#else
boost::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
size_t sizeof_stream_item,
uint64_t nitems,
Concurrent_Queue<pmt::pmt_t>* queue);
boost::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
size_t sizeof_stream_item,
uint64_t nitems,
Concurrent_Queue<pmt::pmt_t>* queue,
bool stop_flowgraph);
#endif
/*! /*!
* \brief Implementation of a GNU Radio block that sends a STOP message to the * \brief Implementation of a GNU Radio block that sends a STOP message to the
@ -81,29 +64,17 @@ public:
gr_vector_void_star& output_items); gr_vector_void_star& output_items);
private: private:
#if GNURADIO_USES_STD_POINTERS friend gnss_shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
friend std::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
size_t sizeof_stream_item, size_t sizeof_stream_item,
uint64_t nitems, uint64_t nitems,
Concurrent_Queue<pmt::pmt_t>* queue); Concurrent_Queue<pmt::pmt_t>* queue);
friend std::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve( friend gnss_shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
size_t sizeof_stream_item, size_t sizeof_stream_item,
uint64_t nitems, uint64_t nitems,
Concurrent_Queue<pmt::pmt_t>* queue, Concurrent_Queue<pmt::pmt_t>* queue,
bool stop_flowgraph); bool stop_flowgraph);
#else
friend boost::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
size_t sizeof_stream_item,
uint64_t nitems,
Concurrent_Queue<pmt::pmt_t>* queue);
friend boost::shared_ptr<Gnss_Sdr_Valve> gnss_sdr_make_valve(
size_t sizeof_stream_item,
uint64_t nitems,
Concurrent_Queue<pmt::pmt_t>* queue,
bool stop_flowgraph);
#endif
Gnss_Sdr_Valve(size_t sizeof_stream_item, Gnss_Sdr_Valve(size_t sizeof_stream_item,
uint64_t nitems, uint64_t nitems,
Concurrent_Queue<pmt::pmt_t>* queue, bool stop_flowgraph); Concurrent_Queue<pmt::pmt_t>* queue, bool stop_flowgraph);

View File

@ -68,6 +68,11 @@ if(GNURADIO_USES_STD_POINTERS)
) )
endif() endif()
target_include_directories(telemetry_decoder_gr_blocks
PUBLIC
${CMAKE_SOURCE_DIR}/src/core/interfaces
)
if(has_rotl) if(has_rotl)
target_compile_definitions(telemetry_decoder_gr_blocks target_compile_definitions(telemetry_decoder_gr_blocks
PRIVATE -DCOMPILER_HAS_ROTL=1 PRIVATE -DCOMPILER_HAS_ROTL=1

View File

@ -24,6 +24,7 @@
#include "beidou_dnav_navigation_message.h" #include "beidou_dnav_navigation_message.h"
#include "gnss_block_interface.h"
#include "gnss_satellite.h" #include "gnss_satellite.h"
#include <boost/circular_buffer.hpp> #include <boost/circular_buffer.hpp>
#include <gnuradio/block.h> // for block #include <gnuradio/block.h> // for block
@ -32,12 +33,6 @@
#include <cstdint> #include <cstdint>
#include <fstream> #include <fstream>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Telemetry_Decoder /** \addtogroup Telemetry_Decoder
* \{ */ * \{ */
@ -47,11 +42,7 @@
class beidou_b1i_telemetry_decoder_gs; class beidou_b1i_telemetry_decoder_gs;
#if GNURADIO_USES_STD_POINTERS using beidou_b1i_telemetry_decoder_gs_sptr = gnss_shared_ptr<beidou_b1i_telemetry_decoder_gs>;
using beidou_b1i_telemetry_decoder_gs_sptr = std::shared_ptr<beidou_b1i_telemetry_decoder_gs>;
#else
using beidou_b1i_telemetry_decoder_gs_sptr = boost::shared_ptr<beidou_b1i_telemetry_decoder_gs>;
#endif
beidou_b1i_telemetry_decoder_gs_sptr beidou_b1i_make_telemetry_decoder_gs( beidou_b1i_telemetry_decoder_gs_sptr beidou_b1i_make_telemetry_decoder_gs(
const Gnss_Satellite &satellite, const Gnss_Satellite &satellite,

View File

@ -21,6 +21,7 @@
#define GNSS_SDR_BEIDOU_B3I_TELEMETRY_DECODER_GS_H #define GNSS_SDR_BEIDOU_B3I_TELEMETRY_DECODER_GS_H
#include "beidou_dnav_navigation_message.h" #include "beidou_dnav_navigation_message.h"
#include "gnss_block_interface.h"
#include "gnss_satellite.h" #include "gnss_satellite.h"
#include <boost/circular_buffer.hpp> #include <boost/circular_buffer.hpp>
#include <gnuradio/block.h> // for block #include <gnuradio/block.h> // for block
@ -29,11 +30,6 @@
#include <cstdint> #include <cstdint>
#include <fstream> #include <fstream>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Telemetry_Decoder /** \addtogroup Telemetry_Decoder
@ -44,13 +40,8 @@
class beidou_b3i_telemetry_decoder_gs; class beidou_b3i_telemetry_decoder_gs;
#if GNURADIO_USES_STD_POINTERS
using beidou_b3i_telemetry_decoder_gs_sptr = using beidou_b3i_telemetry_decoder_gs_sptr =
std::shared_ptr<beidou_b3i_telemetry_decoder_gs>; gnss_shared_ptr<beidou_b3i_telemetry_decoder_gs>;
#else
using beidou_b3i_telemetry_decoder_gs_sptr =
boost::shared_ptr<beidou_b3i_telemetry_decoder_gs>;
#endif
beidou_b3i_telemetry_decoder_gs_sptr beidou_b3i_make_telemetry_decoder_gs( beidou_b3i_telemetry_decoder_gs_sptr beidou_b3i_make_telemetry_decoder_gs(
const Gnss_Satellite &satellite, const Gnss_Satellite &satellite,

View File

@ -26,6 +26,7 @@
#include "galileo_fnav_message.h" #include "galileo_fnav_message.h"
#include "galileo_inav_message.h" #include "galileo_inav_message.h"
#include "gnss_block_interface.h"
#include "gnss_satellite.h" #include "gnss_satellite.h"
#include <boost/circular_buffer.hpp> #include <boost/circular_buffer.hpp>
#include <gnuradio/block.h> // for block #include <gnuradio/block.h> // for block
@ -35,11 +36,6 @@
#include <fstream> #include <fstream>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#include <memory> // for std::shared_ptr
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Telemetry_Decoder /** \addtogroup Telemetry_Decoder
* \{ */ * \{ */
@ -49,11 +45,7 @@
class galileo_telemetry_decoder_gs; class galileo_telemetry_decoder_gs;
#if GNURADIO_USES_STD_POINTERS using galileo_telemetry_decoder_gs_sptr = gnss_shared_ptr<galileo_telemetry_decoder_gs>;
using galileo_telemetry_decoder_gs_sptr = std::shared_ptr<galileo_telemetry_decoder_gs>;
#else
using galileo_telemetry_decoder_gs_sptr = boost::shared_ptr<galileo_telemetry_decoder_gs>;
#endif
galileo_telemetry_decoder_gs_sptr galileo_make_telemetry_decoder_gs( galileo_telemetry_decoder_gs_sptr galileo_make_telemetry_decoder_gs(
const Gnss_Satellite &satellite, const Gnss_Satellite &satellite,

View File

@ -24,6 +24,7 @@
#include "GLONASS_L1_L2_CA.h" #include "GLONASS_L1_L2_CA.h"
#include "glonass_gnav_navigation_message.h" #include "glonass_gnav_navigation_message.h"
#include "gnss_block_interface.h"
#include "gnss_satellite.h" #include "gnss_satellite.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include <boost/circular_buffer.hpp> #include <boost/circular_buffer.hpp>
@ -33,11 +34,6 @@
#include <cstdint> #include <cstdint>
#include <fstream> // for ofstream #include <fstream> // for ofstream
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory> // for std::shared_ptr
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Telemetry_Decoder /** \addtogroup Telemetry_Decoder
* \{ */ * \{ */
@ -47,11 +43,7 @@
class glonass_l1_ca_telemetry_decoder_gs; class glonass_l1_ca_telemetry_decoder_gs;
#if GNURADIO_USES_STD_POINTERS using glonass_l1_ca_telemetry_decoder_gs_sptr = gnss_shared_ptr<glonass_l1_ca_telemetry_decoder_gs>;
using glonass_l1_ca_telemetry_decoder_gs_sptr = std::shared_ptr<glonass_l1_ca_telemetry_decoder_gs>;
#else
using glonass_l1_ca_telemetry_decoder_gs_sptr = boost::shared_ptr<glonass_l1_ca_telemetry_decoder_gs>;
#endif
glonass_l1_ca_telemetry_decoder_gs_sptr glonass_l1_ca_make_telemetry_decoder_gs( glonass_l1_ca_telemetry_decoder_gs_sptr glonass_l1_ca_make_telemetry_decoder_gs(
const Gnss_Satellite &satellite, const Gnss_Satellite &satellite,

View File

@ -23,6 +23,7 @@
#include "GLONASS_L1_L2_CA.h" #include "GLONASS_L1_L2_CA.h"
#include "glonass_gnav_navigation_message.h" #include "glonass_gnav_navigation_message.h"
#include "gnss_block_interface.h"
#include "gnss_satellite.h" #include "gnss_satellite.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include <boost/circular_buffer.hpp> #include <boost/circular_buffer.hpp>
@ -32,11 +33,6 @@
#include <cstdint> #include <cstdint>
#include <fstream> #include <fstream>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory> // for std::shared_ptr
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Telemetry_Decoder /** \addtogroup Telemetry_Decoder
* \{ */ * \{ */
@ -46,11 +42,7 @@
class glonass_l2_ca_telemetry_decoder_gs; class glonass_l2_ca_telemetry_decoder_gs;
#if GNURADIO_USES_STD_POINTERS using glonass_l2_ca_telemetry_decoder_gs_sptr = gnss_shared_ptr<glonass_l2_ca_telemetry_decoder_gs>;
using glonass_l2_ca_telemetry_decoder_gs_sptr = std::shared_ptr<glonass_l2_ca_telemetry_decoder_gs>;
#else
using glonass_l2_ca_telemetry_decoder_gs_sptr = boost::shared_ptr<glonass_l2_ca_telemetry_decoder_gs>;
#endif
glonass_l2_ca_telemetry_decoder_gs_sptr glonass_l2_ca_make_telemetry_decoder_gs( glonass_l2_ca_telemetry_decoder_gs_sptr glonass_l2_ca_make_telemetry_decoder_gs(
const Gnss_Satellite &satellite, const Gnss_Satellite &satellite,

View File

@ -21,6 +21,7 @@
#define GNSS_SDR_GPS_L1_CA_TELEMETRY_DECODER_GS_H #define GNSS_SDR_GPS_L1_CA_TELEMETRY_DECODER_GS_H
#include "GPS_L1_CA.h" #include "GPS_L1_CA.h"
#include "gnss_block_interface.h"
#include "gnss_satellite.h" #include "gnss_satellite.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "gps_navigation_message.h" #include "gps_navigation_message.h"
@ -31,11 +32,6 @@
#include <cstdint> // for int32_t #include <cstdint> // for int32_t
#include <fstream> // for ofstream #include <fstream> // for ofstream
#include <string> // for string #include <string> // for string
#if GNURADIO_USES_STD_POINTERS
#include <memory> // for std::shared_ptr
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Telemetry_Decoder /** \addtogroup Telemetry_Decoder
* \{ */ * \{ */
@ -46,11 +42,7 @@
class gps_l1_ca_telemetry_decoder_gs; class gps_l1_ca_telemetry_decoder_gs;
#if GNURADIO_USES_STD_POINTERS using gps_l1_ca_telemetry_decoder_gs_sptr = gnss_shared_ptr<gps_l1_ca_telemetry_decoder_gs>;
using gps_l1_ca_telemetry_decoder_gs_sptr = std::shared_ptr<gps_l1_ca_telemetry_decoder_gs>;
#else
using gps_l1_ca_telemetry_decoder_gs_sptr = boost::shared_ptr<gps_l1_ca_telemetry_decoder_gs>;
#endif
gps_l1_ca_telemetry_decoder_gs_sptr gps_l1_ca_make_telemetry_decoder_gs( gps_l1_ca_telemetry_decoder_gs_sptr gps_l1_ca_make_telemetry_decoder_gs(
const Gnss_Satellite &satellite, const Gnss_Satellite &satellite,

View File

@ -20,6 +20,7 @@
#define GNSS_SDR_GPS_L2C_TELEMETRY_DECODER_GS_H #define GNSS_SDR_GPS_L2C_TELEMETRY_DECODER_GS_H
#include "gnss_block_interface.h"
#include "gnss_satellite.h" #include "gnss_satellite.h"
#include "gps_cnav_navigation_message.h" #include "gps_cnav_navigation_message.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
@ -27,11 +28,6 @@
#include <cstdint> #include <cstdint>
#include <fstream> #include <fstream>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory> // for std::shared_ptr
#else
#include <boost/shared_ptr.hpp>
#endif
extern "C" extern "C"
{ {
@ -43,13 +39,10 @@ extern "C"
/** \addtogroup Telemetry_Decoder_gnuradio_blocks /** \addtogroup Telemetry_Decoder_gnuradio_blocks
* \{ */ * \{ */
class gps_l2c_telemetry_decoder_gs; class gps_l2c_telemetry_decoder_gs;
#if GNURADIO_USES_STD_POINTERS using gps_l2c_telemetry_decoder_gs_sptr = gnss_shared_ptr<gps_l2c_telemetry_decoder_gs>;
using gps_l2c_telemetry_decoder_gs_sptr = std::shared_ptr<gps_l2c_telemetry_decoder_gs>;
#else
using gps_l2c_telemetry_decoder_gs_sptr = boost::shared_ptr<gps_l2c_telemetry_decoder_gs>;
#endif
gps_l2c_telemetry_decoder_gs_sptr gps_l2c_make_telemetry_decoder_gs( gps_l2c_telemetry_decoder_gs_sptr gps_l2c_make_telemetry_decoder_gs(
const Gnss_Satellite &satellite, const Gnss_Satellite &satellite,

View File

@ -20,7 +20,8 @@
#define GNSS_SDR_GPS_L5_TELEMETRY_DECODER_GS_H #define GNSS_SDR_GPS_L5_TELEMETRY_DECODER_GS_H
#include "GPS_L5.h" // for GPS_L5I_NH_CODE_LENGTH #include "GPS_L5.h" // for GPS_L5I_NH_CODE_LENGTH
#include "gnss_block_interface.h"
#include "gnss_satellite.h" // for Gnss_Satellite #include "gnss_satellite.h" // for Gnss_Satellite
#include "gps_cnav_navigation_message.h" // for Gps_CNAV_Navigation_Message #include "gps_cnav_navigation_message.h" // for Gps_CNAV_Navigation_Message
#include <boost/circular_buffer.hpp> #include <boost/circular_buffer.hpp>
@ -29,30 +30,21 @@
#include <cstdint> #include <cstdint>
#include <fstream> #include <fstream>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory> // for std::shared_ptr
#else
#include <boost/shared_ptr.hpp>
#endif
extern "C" extern "C"
{ {
#include "cnav_msg.h" #include "cnav_msg.h"
} }
/** \addtogroup Telemetry_Decoder /** \addtogroup Telemetry_Decoder
* \{ */ * \{ */
/** \addtogroup Telemetry_Decoder_gnuradio_blocks /** \addtogroup Telemetry_Decoder_gnuradio_blocks
* \{ */ * \{ */
class gps_l5_telemetry_decoder_gs; class gps_l5_telemetry_decoder_gs;
#if GNURADIO_USES_STD_POINTERS using gps_l5_telemetry_decoder_gs_sptr = gnss_shared_ptr<gps_l5_telemetry_decoder_gs>;
using gps_l5_telemetry_decoder_gs_sptr = std::shared_ptr<gps_l5_telemetry_decoder_gs>;
#else
using gps_l5_telemetry_decoder_gs_sptr = boost::shared_ptr<gps_l5_telemetry_decoder_gs>;
#endif
gps_l5_telemetry_decoder_gs_sptr gps_l5_make_telemetry_decoder_gs( gps_l5_telemetry_decoder_gs_sptr gps_l5_make_telemetry_decoder_gs(
const Gnss_Satellite &satellite, const Gnss_Satellite &satellite,

View File

@ -20,6 +20,7 @@
#ifndef GNSS_SDR_SBAS_L1_TELEMETRY_DECODER_GS_H #ifndef GNSS_SDR_SBAS_L1_TELEMETRY_DECODER_GS_H
#define GNSS_SDR_SBAS_L1_TELEMETRY_DECODER_GS_H #define GNSS_SDR_SBAS_L1_TELEMETRY_DECODER_GS_H
#include "gnss_block_interface.h"
#include "gnss_satellite.h" #include "gnss_satellite.h"
#include <boost/crc.hpp> // for crc_optimal #include <boost/crc.hpp> // for crc_optimal
#include <gnuradio/block.h> #include <gnuradio/block.h>
@ -32,11 +33,6 @@
#include <string> #include <string>
#include <utility> // for pair #include <utility> // for pair
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#include <memory> // for std::shared_ptr
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Telemetry_Decoder /** \addtogroup Telemetry_Decoder
* \{ */ * \{ */
@ -48,11 +44,7 @@ class Viterbi_Decoder;
class sbas_l1_telemetry_decoder_gs; class sbas_l1_telemetry_decoder_gs;
#if GNURADIO_USES_STD_POINTERS using sbas_l1_telemetry_decoder_gs_sptr = gnss_shared_ptr<sbas_l1_telemetry_decoder_gs>;
using sbas_l1_telemetry_decoder_gs_sptr = std::shared_ptr<sbas_l1_telemetry_decoder_gs>;
#else
using sbas_l1_telemetry_decoder_gs_sptr = boost::shared_ptr<sbas_l1_telemetry_decoder_gs>;
#endif
sbas_l1_telemetry_decoder_gs_sptr sbas_l1_make_telemetry_decoder_gs( sbas_l1_telemetry_decoder_gs_sptr sbas_l1_make_telemetry_decoder_gs(
const Gnss_Satellite &satellite, const Gnss_Satellite &satellite,

View File

@ -103,6 +103,11 @@ if(GNURADIO_USES_STD_POINTERS)
) )
endif() endif()
target_include_directories(tracking_gr_blocks
PUBLIC
${CMAKE_SOURCE_DIR}/src/core/interfaces
)
if(ENABLE_CUDA) if(ENABLE_CUDA)
if(CMAKE_VERSION VERSION_GREATER 3.11) if(CMAKE_VERSION VERSION_GREATER 3.11)
target_include_directories(tracking_gr_blocks target_include_directories(tracking_gr_blocks

View File

@ -24,6 +24,7 @@
#include "cpu_multicorrelator_real_codes.h" #include "cpu_multicorrelator_real_codes.h"
#include "dll_pll_conf.h" #include "dll_pll_conf.h"
#include "exponential_smoother.h" #include "exponential_smoother.h"
#include "gnss_block_interface.h"
#include "tracking_FLL_PLL_filter.h" // for PLL/FLL filter #include "tracking_FLL_PLL_filter.h" // for PLL/FLL filter
#include "tracking_loop_filter.h" // for DLL filter #include "tracking_loop_filter.h" // for DLL filter
#include <boost/circular_buffer.hpp> #include <boost/circular_buffer.hpp>
@ -38,11 +39,6 @@
#include <string> // for string #include <string> // for string
#include <typeinfo> // for typeid #include <typeinfo> // for typeid
#include <utility> // for pair #include <utility> // for pair
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -54,12 +50,7 @@
class Gnss_Synchro; class Gnss_Synchro;
class dll_pll_veml_tracking; class dll_pll_veml_tracking;
#if GNURADIO_USES_STD_POINTERS using dll_pll_veml_tracking_sptr = gnss_shared_ptr<dll_pll_veml_tracking>;
using dll_pll_veml_tracking_sptr = std::shared_ptr<dll_pll_veml_tracking>;
#else
using dll_pll_veml_tracking_sptr = boost::shared_ptr<dll_pll_veml_tracking>;
#endif
dll_pll_veml_tracking_sptr dll_pll_veml_make_tracking(const Dll_Pll_Conf &conf_); dll_pll_veml_tracking_sptr dll_pll_veml_make_tracking(const Dll_Pll_Conf &conf_);

View File

@ -23,6 +23,7 @@
#include "dll_pll_conf_fpga.h" #include "dll_pll_conf_fpga.h"
#include "exponential_smoother.h" #include "exponential_smoother.h"
#include "gnss_block_interface.h"
#include "tracking_FLL_PLL_filter.h" // for PLL/FLL filter #include "tracking_FLL_PLL_filter.h" // for PLL/FLL filter
#include "tracking_loop_filter.h" // for DLL filter #include "tracking_loop_filter.h" // for DLL filter
#include <boost/circular_buffer.hpp> #include <boost/circular_buffer.hpp>
@ -38,10 +39,6 @@
#include <string> // for string #include <string> // for string
#include <typeinfo> // for typeid #include <typeinfo> // for typeid
#include <utility> // for pair #include <utility> // for pair
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -53,11 +50,7 @@ class Fpga_Multicorrelator_8sc;
class Gnss_Synchro; class Gnss_Synchro;
class dll_pll_veml_tracking_fpga; class dll_pll_veml_tracking_fpga;
#if GNURADIO_USES_STD_POINTERS using dll_pll_veml_tracking_fpga_sptr = gnss_shared_ptr<dll_pll_veml_tracking_fpga>;
using dll_pll_veml_tracking_fpga_sptr = std::shared_ptr<dll_pll_veml_tracking_fpga>;
#else
using dll_pll_veml_tracking_fpga_sptr = boost::shared_ptr<dll_pll_veml_tracking_fpga>;
#endif
dll_pll_veml_tracking_fpga_sptr dll_pll_veml_make_tracking_fpga(const Dll_Pll_Conf_Fpga &conf_); dll_pll_veml_tracking_fpga_sptr dll_pll_veml_make_tracking_fpga(const Dll_Pll_Conf_Fpga &conf_);

View File

@ -29,6 +29,7 @@
#define GNSS_SDR_GALILEO_E1_TCP_CONNECTOR_TRACKING_CC_H #define GNSS_SDR_GALILEO_E1_TCP_CONNECTOR_TRACKING_CC_H
#include "cpu_multicorrelator.h" #include "cpu_multicorrelator.h"
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "tcp_communication.h" #include "tcp_communication.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
@ -36,11 +37,6 @@
#include <fstream> #include <fstream>
#include <map> #include <map>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -50,11 +46,7 @@
class Galileo_E1_Tcp_Connector_Tracking_cc; class Galileo_E1_Tcp_Connector_Tracking_cc;
#if GNURADIO_USES_STD_POINTERS using galileo_e1_tcp_connector_tracking_cc_sptr = gnss_shared_ptr<Galileo_E1_Tcp_Connector_Tracking_cc>;
using galileo_e1_tcp_connector_tracking_cc_sptr = std::shared_ptr<Galileo_E1_Tcp_Connector_Tracking_cc>;
#else
using galileo_e1_tcp_connector_tracking_cc_sptr = boost::shared_ptr<Galileo_E1_Tcp_Connector_Tracking_cc>;
#endif
galileo_e1_tcp_connector_tracking_cc_sptr galileo_e1_tcp_connector_tracking_cc_sptr
galileo_e1_tcp_connector_make_tracking_cc( galileo_e1_tcp_connector_make_tracking_cc(

View File

@ -33,6 +33,7 @@
#include "tracking_FLL_PLL_filter.h" #include "tracking_FLL_PLL_filter.h"
// #include "tracking_loop_filter.h" // #include "tracking_loop_filter.h"
#include "cpu_multicorrelator.h" #include "cpu_multicorrelator.h"
#include "gnss_block_interface.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <volk_gnsssdr/volk_gnsssdr_alloc.h> // for volk_gnsssdr::vector #include <volk_gnsssdr/volk_gnsssdr_alloc.h> // for volk_gnsssdr::vector
@ -40,11 +41,6 @@
#include <fstream> #include <fstream>
#include <map> #include <map>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -54,11 +50,7 @@
class glonass_l1_ca_dll_pll_c_aid_tracking_cc; class glonass_l1_ca_dll_pll_c_aid_tracking_cc;
#if GNURADIO_USES_STD_POINTERS using glonass_l1_ca_dll_pll_c_aid_tracking_cc_sptr = gnss_shared_ptr<glonass_l1_ca_dll_pll_c_aid_tracking_cc>;
using glonass_l1_ca_dll_pll_c_aid_tracking_cc_sptr = std::shared_ptr<glonass_l1_ca_dll_pll_c_aid_tracking_cc>;
#else
using glonass_l1_ca_dll_pll_c_aid_tracking_cc_sptr = boost::shared_ptr<glonass_l1_ca_dll_pll_c_aid_tracking_cc>;
#endif
glonass_l1_ca_dll_pll_c_aid_tracking_cc_sptr glonass_l1_ca_dll_pll_c_aid_tracking_cc_sptr
glonass_l1_ca_dll_pll_c_aid_make_tracking_cc( glonass_l1_ca_dll_pll_c_aid_make_tracking_cc(

View File

@ -30,6 +30,7 @@
#include "cpu_multicorrelator_16sc.h" #include "cpu_multicorrelator_16sc.h"
#include "glonass_l1_signal_processing.h" #include "glonass_l1_signal_processing.h"
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "tracking_2nd_DLL_filter.h" #include "tracking_2nd_DLL_filter.h"
#include "tracking_FLL_PLL_filter.h" #include "tracking_FLL_PLL_filter.h"
@ -40,11 +41,6 @@
#include <fstream> #include <fstream>
#include <map> #include <map>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
@ -55,11 +51,7 @@
class glonass_l1_ca_dll_pll_c_aid_tracking_sc; class glonass_l1_ca_dll_pll_c_aid_tracking_sc;
#if GNURADIO_USES_STD_POINTERS using glonass_l1_ca_dll_pll_c_aid_tracking_sc_sptr = gnss_shared_ptr<glonass_l1_ca_dll_pll_c_aid_tracking_sc>;
using glonass_l1_ca_dll_pll_c_aid_tracking_sc_sptr = std::shared_ptr<glonass_l1_ca_dll_pll_c_aid_tracking_sc>;
#else
using glonass_l1_ca_dll_pll_c_aid_tracking_sc_sptr = boost::shared_ptr<glonass_l1_ca_dll_pll_c_aid_tracking_sc>;
#endif
glonass_l1_ca_dll_pll_c_aid_tracking_sc_sptr glonass_l1_ca_dll_pll_c_aid_tracking_sc_sptr
glonass_l1_ca_dll_pll_c_aid_make_tracking_sc( glonass_l1_ca_dll_pll_c_aid_make_tracking_sc(

View File

@ -29,6 +29,7 @@
#define GNSS_SDR_GLONASS_L1_CA_DLL_PLL_TRACKING_CC_H #define GNSS_SDR_GLONASS_L1_CA_DLL_PLL_TRACKING_CC_H
#include "cpu_multicorrelator.h" #include "cpu_multicorrelator.h"
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "tracking_2nd_DLL_filter.h" #include "tracking_2nd_DLL_filter.h"
#include "tracking_2nd_PLL_filter.h" #include "tracking_2nd_PLL_filter.h"
@ -37,11 +38,6 @@
#include <fstream> #include <fstream>
#include <map> #include <map>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
@ -52,11 +48,7 @@
class Glonass_L1_Ca_Dll_Pll_Tracking_cc; class Glonass_L1_Ca_Dll_Pll_Tracking_cc;
#if GNURADIO_USES_STD_POINTERS using glonass_l1_ca_dll_pll_tracking_cc_sptr = gnss_shared_ptr<Glonass_L1_Ca_Dll_Pll_Tracking_cc>;
using glonass_l1_ca_dll_pll_tracking_cc_sptr = std::shared_ptr<Glonass_L1_Ca_Dll_Pll_Tracking_cc>;
#else
using glonass_l1_ca_dll_pll_tracking_cc_sptr = boost::shared_ptr<Glonass_L1_Ca_Dll_Pll_Tracking_cc>;
#endif
glonass_l1_ca_dll_pll_tracking_cc_sptr glonass_l1_ca_dll_pll_tracking_cc_sptr
glonass_l1_ca_dll_pll_make_tracking_cc( glonass_l1_ca_dll_pll_make_tracking_cc(

View File

@ -27,6 +27,7 @@
#define GNSS_SDR_GLONASS_L2_CA_DLL_PLL_C_AID_TRACKING_CC_H #define GNSS_SDR_GLONASS_L2_CA_DLL_PLL_C_AID_TRACKING_CC_H
#include "cpu_multicorrelator.h" #include "cpu_multicorrelator.h"
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "tracking_2nd_DLL_filter.h" #include "tracking_2nd_DLL_filter.h"
#include "tracking_FLL_PLL_filter.h" #include "tracking_FLL_PLL_filter.h"
@ -37,11 +38,6 @@
#include <fstream> #include <fstream>
#include <map> #include <map>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -51,11 +47,7 @@
class glonass_l2_ca_dll_pll_c_aid_tracking_cc; class glonass_l2_ca_dll_pll_c_aid_tracking_cc;
#if GNURADIO_USES_STD_POINTERS using glonass_l2_ca_dll_pll_c_aid_tracking_cc_sptr = gnss_shared_ptr<glonass_l2_ca_dll_pll_c_aid_tracking_cc>;
using glonass_l2_ca_dll_pll_c_aid_tracking_cc_sptr = std::shared_ptr<glonass_l2_ca_dll_pll_c_aid_tracking_cc>;
#else
using glonass_l2_ca_dll_pll_c_aid_tracking_cc_sptr = boost::shared_ptr<glonass_l2_ca_dll_pll_c_aid_tracking_cc>;
#endif
glonass_l2_ca_dll_pll_c_aid_tracking_cc_sptr glonass_l2_ca_dll_pll_c_aid_tracking_cc_sptr
glonass_l2_ca_dll_pll_c_aid_make_tracking_cc( glonass_l2_ca_dll_pll_c_aid_make_tracking_cc(

View File

@ -28,6 +28,7 @@
#include "cpu_multicorrelator_16sc.h" #include "cpu_multicorrelator_16sc.h"
#include "glonass_l2_signal_processing.h" #include "glonass_l2_signal_processing.h"
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "tracking_2nd_DLL_filter.h" #include "tracking_2nd_DLL_filter.h"
#include "tracking_FLL_PLL_filter.h" #include "tracking_FLL_PLL_filter.h"
@ -37,11 +38,6 @@
#include <fstream> #include <fstream>
#include <map> #include <map>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -51,12 +47,7 @@
class glonass_l2_ca_dll_pll_c_aid_tracking_sc; class glonass_l2_ca_dll_pll_c_aid_tracking_sc;
#if GNURADIO_USES_STD_POINTERS using glonass_l2_ca_dll_pll_c_aid_tracking_sc_sptr = gnss_shared_ptr<glonass_l2_ca_dll_pll_c_aid_tracking_sc>;
using glonass_l2_ca_dll_pll_c_aid_tracking_sc_sptr = std::shared_ptr<glonass_l2_ca_dll_pll_c_aid_tracking_sc>;
#else
using glonass_l2_ca_dll_pll_c_aid_tracking_sc_sptr = boost::shared_ptr<glonass_l2_ca_dll_pll_c_aid_tracking_sc>;
#endif
glonass_l2_ca_dll_pll_c_aid_tracking_sc_sptr glonass_l2_ca_dll_pll_c_aid_tracking_sc_sptr
glonass_l2_ca_dll_pll_c_aid_make_tracking_sc( glonass_l2_ca_dll_pll_c_aid_make_tracking_sc(

View File

@ -27,6 +27,7 @@
#define GNSS_SDR_GLONASS_L2_CA_DLL_PLL_TRACKING_CC_H #define GNSS_SDR_GLONASS_L2_CA_DLL_PLL_TRACKING_CC_H
#include "cpu_multicorrelator.h" #include "cpu_multicorrelator.h"
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "tracking_2nd_DLL_filter.h" #include "tracking_2nd_DLL_filter.h"
#include "tracking_2nd_PLL_filter.h" #include "tracking_2nd_PLL_filter.h"
@ -35,11 +36,6 @@
#include <fstream> #include <fstream>
#include <map> #include <map>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -49,11 +45,7 @@
class Glonass_L2_Ca_Dll_Pll_Tracking_cc; class Glonass_L2_Ca_Dll_Pll_Tracking_cc;
#if GNURADIO_USES_STD_POINTERS using glonass_l2_ca_dll_pll_tracking_cc_sptr = gnss_shared_ptr<Glonass_L2_Ca_Dll_Pll_Tracking_cc>;
using glonass_l2_ca_dll_pll_tracking_cc_sptr = std::shared_ptr<Glonass_L2_Ca_Dll_Pll_Tracking_cc>;
#else
using glonass_l2_ca_dll_pll_tracking_cc_sptr = boost::shared_ptr<Glonass_L2_Ca_Dll_Pll_Tracking_cc>;
#endif
glonass_l2_ca_dll_pll_tracking_cc_sptr glonass_l2_ca_dll_pll_tracking_cc_sptr
glonass_l2_ca_dll_pll_make_tracking_cc( glonass_l2_ca_dll_pll_make_tracking_cc(

View File

@ -26,6 +26,7 @@
#define GNSS_SDR_GPS_L1_CA_DLL_PLL_TRACKING_GPU_CC_H #define GNSS_SDR_GPS_L1_CA_DLL_PLL_TRACKING_GPU_CC_H
#include "cuda_multicorrelator.h" #include "cuda_multicorrelator.h"
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "tracking_2nd_DLL_filter.h" #include "tracking_2nd_DLL_filter.h"
#include "tracking_FLL_PLL_filter.h" #include "tracking_FLL_PLL_filter.h"
@ -34,11 +35,6 @@
#include <map> #include <map>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -48,13 +44,7 @@
class Gps_L1_Ca_Dll_Pll_Tracking_GPU_cc; class Gps_L1_Ca_Dll_Pll_Tracking_GPU_cc;
#if GNURADIO_USES_STD_POINTERS using gps_l1_ca_dll_pll_tracking_gpu_cc_sptr = gnss_shared_ptr<Gps_L1_Ca_Dll_Pll_Tracking_GPU_cc>;
typedef std::shared_ptr<Gps_L1_Ca_Dll_Pll_Tracking_GPU_cc>
gps_l1_ca_dll_pll_tracking_gpu_cc_sptr;
#else
typedef boost::shared_ptr<Gps_L1_Ca_Dll_Pll_Tracking_GPU_cc>
gps_l1_ca_dll_pll_tracking_gpu_cc_sptr;
#endif
gps_l1_ca_dll_pll_tracking_gpu_cc_sptr gps_l1_ca_dll_pll_tracking_gpu_cc_sptr
gps_l1_ca_dll_pll_make_tracking_gpu_cc( gps_l1_ca_dll_pll_make_tracking_gpu_cc(

View File

@ -35,6 +35,7 @@
#include "bayesian_estimation.h" #include "bayesian_estimation.h"
#include "cpu_multicorrelator_real_codes.h" #include "cpu_multicorrelator_real_codes.h"
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "tracking_2nd_DLL_filter.h" #include "tracking_2nd_DLL_filter.h"
#include "tracking_2nd_PLL_filter.h" #include "tracking_2nd_PLL_filter.h"
@ -44,11 +45,6 @@
#include <fstream> #include <fstream>
#include <map> #include <map>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -58,11 +54,7 @@
class Gps_L1_Ca_Kf_Tracking_cc; class Gps_L1_Ca_Kf_Tracking_cc;
#if GNURADIO_USES_STD_POINTERS using gps_l1_ca_kf_tracking_cc_sptr = gnss_shared_ptr<Gps_L1_Ca_Kf_Tracking_cc>;
using gps_l1_ca_kf_tracking_cc_sptr = std::shared_ptr<Gps_L1_Ca_Kf_Tracking_cc>;
#else
using gps_l1_ca_kf_tracking_cc_sptr = boost::shared_ptr<Gps_L1_Ca_Kf_Tracking_cc>;
#endif
gps_l1_ca_kf_tracking_cc_sptr gps_l1_ca_kf_tracking_cc_sptr
gps_l1_ca_kf_make_tracking_cc(uint32_t order, gps_l1_ca_kf_make_tracking_cc(uint32_t order,

View File

@ -27,6 +27,7 @@
#define GNSS_SDR_GPS_L1_CA_TCP_CONNECTOR_TRACKING_CC_H #define GNSS_SDR_GPS_L1_CA_TCP_CONNECTOR_TRACKING_CC_H
#include "cpu_multicorrelator.h" #include "cpu_multicorrelator.h"
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "tcp_communication.h" #include "tcp_communication.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
@ -34,11 +35,6 @@
#include <fstream> #include <fstream>
#include <map> #include <map>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Tracking /** \addtogroup Tracking
* \{ */ * \{ */
@ -48,11 +44,7 @@
class Gps_L1_Ca_Tcp_Connector_Tracking_cc; class Gps_L1_Ca_Tcp_Connector_Tracking_cc;
#if GNURADIO_USES_STD_POINTERS using gps_l1_ca_tcp_connector_tracking_cc_sptr = gnss_shared_ptr<Gps_L1_Ca_Tcp_Connector_Tracking_cc>;
using gps_l1_ca_tcp_connector_tracking_cc_sptr = std::shared_ptr<Gps_L1_Ca_Tcp_Connector_Tracking_cc>;
#else
using gps_l1_ca_tcp_connector_tracking_cc_sptr = boost::shared_ptr<Gps_L1_Ca_Tcp_Connector_Tracking_cc>;
#endif
gps_l1_ca_tcp_connector_tracking_cc_sptr gps_l1_ca_tcp_connector_tracking_cc_sptr
gps_l1_ca_tcp_connector_make_tracking_cc( gps_l1_ca_tcp_connector_make_tracking_cc(

View File

@ -29,6 +29,7 @@
#include <gnuradio/top_block.h> #include <gnuradio/top_block.h>
#include <cassert> #include <cassert>
#include <string> #include <string>
#include <utility> // for std::forward
/** \addtogroup Core /** \addtogroup Core
* \{ */ * \{ */
@ -36,6 +37,27 @@
* \{ */ * \{ */
#if GNURADIO_USES_STD_POINTERS
#include <memory>
template <typename T>
using gnss_shared_ptr = std::shared_ptr<T>;
template <typename C, typename... Args>
gnss_shared_ptr<C> gnss_make_shared(Args &&... args)
{
return std::make_shared<C>(std::forward<Args>(args)...);
}
#else
#include <boost/make_shared.hpp>
#include <boost/shared_ptr.hpp>
template <typename T>
using gnss_shared_ptr = boost::shared_ptr<T>;
template <typename C, typename... Args>
gnss_shared_ptr<C> gnss_make_shared(Args &&... args)
{
return boost::make_shared<C>(std::forward<Args>(args)...);
}
#endif
/*! /*!
* \brief This abstract class represents an interface to GNSS blocks. * \brief This abstract class represents an interface to GNSS blocks.
* *

View File

@ -87,6 +87,11 @@ if(GNURADIO_USES_STD_POINTERS)
) )
endif() endif()
target_include_directories(core_libs
PUBLIC
${CMAKE_SOURCE_DIR}/src/core/interfaces
)
if(USE_GENERIC_LAMBDAS) if(USE_GENERIC_LAMBDAS)
set(has_generic_lambdas HAS_GENERIC_LAMBDA=1) set(has_generic_lambdas HAS_GENERIC_LAMBDA=1)
set(no_has_generic_lambdas HAS_GENERIC_LAMBDA=0) set(no_has_generic_lambdas HAS_GENERIC_LAMBDA=0)

View File

@ -21,16 +21,13 @@
#ifndef GNSS_SDR_CHANNEL_STATUS_MSG_RECEIVER_CC_H #ifndef GNSS_SDR_CHANNEL_STATUS_MSG_RECEIVER_CC_H
#define GNSS_SDR_CHANNEL_STATUS_MSG_RECEIVER_CC_H #define GNSS_SDR_CHANNEL_STATUS_MSG_RECEIVER_CC_H
#include "gnss_block_interface.h"
#include "gnss_synchro.h" #include "gnss_synchro.h"
#include "monitor_pvt.h" #include "monitor_pvt.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <map> #include <map>
#include <memory> #include <memory>
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Core /** \addtogroup Core
* \{ */ * \{ */
@ -40,11 +37,7 @@
class channel_status_msg_receiver; class channel_status_msg_receiver;
#if GNURADIO_USES_STD_POINTERS using channel_status_msg_receiver_sptr = gnss_shared_ptr<channel_status_msg_receiver>;
using channel_status_msg_receiver_sptr = std::shared_ptr<channel_status_msg_receiver>;
#else
using channel_status_msg_receiver_sptr = boost::shared_ptr<channel_status_msg_receiver>;
#endif
channel_status_msg_receiver_sptr channel_status_msg_receiver_make(); channel_status_msg_receiver_sptr channel_status_msg_receiver_make();

View File

@ -22,15 +22,11 @@
#ifndef GNSS_SDR_GNSS_SDR_FPGA_SAMPLE_COUNTER_H #ifndef GNSS_SDR_GNSS_SDR_FPGA_SAMPLE_COUNTER_H
#define GNSS_SDR_GNSS_SDR_FPGA_SAMPLE_COUNTER_H #define GNSS_SDR_GNSS_SDR_FPGA_SAMPLE_COUNTER_H
#include "gnss_block_interface.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
#include <cstdint> #include <cstdint>
#include <string> #include <string>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Core /** \addtogroup Core
* \{ */ * \{ */
@ -40,11 +36,7 @@
class gnss_sdr_fpga_sample_counter; class gnss_sdr_fpga_sample_counter;
#if GNURADIO_USES_STD_POINTERS using gnss_sdr_fpga_sample_counter_sptr = gnss_shared_ptr<gnss_sdr_fpga_sample_counter>;
using gnss_sdr_fpga_sample_counter_sptr = std::shared_ptr<gnss_sdr_fpga_sample_counter>;
#else
using gnss_sdr_fpga_sample_counter_sptr = boost::shared_ptr<gnss_sdr_fpga_sample_counter>;
#endif
gnss_sdr_fpga_sample_counter_sptr gnss_sdr_make_fpga_sample_counter(double _fs, int32_t _interval_ms); gnss_sdr_fpga_sample_counter_sptr gnss_sdr_make_fpga_sample_counter(double _fs, int32_t _interval_ms);

View File

@ -21,15 +21,11 @@
#ifndef GNSS_SDR_GNSS_SDR_SAMPLE_COUNTER_H #ifndef GNSS_SDR_GNSS_SDR_SAMPLE_COUNTER_H
#define GNSS_SDR_GNSS_SDR_SAMPLE_COUNTER_H #define GNSS_SDR_GNSS_SDR_SAMPLE_COUNTER_H
#include "gnss_block_interface.h"
#include <gnuradio/sync_decimator.h> #include <gnuradio/sync_decimator.h>
#include <gnuradio/types.h> // for gr_vector_const_void_star #include <gnuradio/types.h> // for gr_vector_const_void_star
#include <cstddef> // for size_t #include <cstddef> // for size_t
#include <cstdint> #include <cstdint>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Core /** \addtogroup Core
* \{ */ * \{ */
@ -40,11 +36,7 @@
class gnss_sdr_sample_counter; class gnss_sdr_sample_counter;
#if GNURADIO_USES_STD_POINTERS using gnss_sdr_sample_counter_sptr = gnss_shared_ptr<gnss_sdr_sample_counter>;
using gnss_sdr_sample_counter_sptr = std::shared_ptr<gnss_sdr_sample_counter>;
#else
using gnss_sdr_sample_counter_sptr = boost::shared_ptr<gnss_sdr_sample_counter>;
#endif
gnss_sdr_sample_counter_sptr gnss_sdr_make_sample_counter( gnss_sdr_sample_counter_sptr gnss_sdr_make_sample_counter(
double _fs, double _fs,

View File

@ -60,6 +60,7 @@ get_filename_component(PROTO_INCLUDE_HEADERS ${PROTO_HDRS} DIRECTORY)
target_include_directories(core_monitor target_include_directories(core_monitor
PUBLIC PUBLIC
SYSTEM ${PROTO_INCLUDE_HEADERS} SYSTEM ${PROTO_INCLUDE_HEADERS}
${CMAKE_SOURCE_DIR}/src/core/interfaces
PRIVATE PRIVATE
${CMAKE_SOURCE_DIR}/src/algorithms/libs # for gnss_sdr_make_unique ${CMAKE_SOURCE_DIR}/src/algorithms/libs # for gnss_sdr_make_unique
) )

View File

@ -23,17 +23,13 @@
#ifndef GNSS_SDR_GNSS_SYNCHRO_MONITOR_H #ifndef GNSS_SDR_GNSS_SYNCHRO_MONITOR_H
#define GNSS_SDR_GNSS_SYNCHRO_MONITOR_H #define GNSS_SDR_GNSS_SYNCHRO_MONITOR_H
#include "gnss_block_interface.h"
#include "gnss_synchro_udp_sink.h" #include "gnss_synchro_udp_sink.h"
#include <gnuradio/block.h> #include <gnuradio/block.h>
#include <gnuradio/runtime_types.h> // for gr_vector_void_star #include <gnuradio/runtime_types.h> // for gr_vector_void_star
#include <memory> #include <memory>
#include <string> #include <string>
#include <vector> #include <vector>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
/** \addtogroup Core /** \addtogroup Core
* \{ */ * \{ */
@ -44,11 +40,7 @@
class gnss_synchro_monitor; class gnss_synchro_monitor;
#if GNURADIO_USES_STD_POINTERS using gnss_synchro_monitor_sptr = gnss_shared_ptr<gnss_synchro_monitor>;
using gnss_synchro_monitor_sptr = std::shared_ptr<gnss_synchro_monitor>;
#else
using gnss_synchro_monitor_sptr = boost::shared_ptr<gnss_synchro_monitor>;
#endif
gnss_synchro_monitor_sptr gnss_synchro_make_monitor(int n_channels, gnss_synchro_monitor_sptr gnss_synchro_make_monitor(int n_channels,
int decimation_factor, int decimation_factor,

View File

@ -69,6 +69,10 @@ if(ENABLE_FPGA)
target_compile_definitions(core_receiver PUBLIC -DENABLE_FPGA=1) target_compile_definitions(core_receiver PUBLIC -DENABLE_FPGA=1)
endif() endif()
if(GNURADIO_USES_STD_POINTERS)
target_compile_definitions(core_receiver PUBLIC -DGNURADIO_USES_STD_POINTERS=1)
endif()
if(ENABLE_RAW_UDP) if(ENABLE_RAW_UDP)
target_compile_definitions(core_receiver PRIVATE -DRAW_UDP=1) target_compile_definitions(core_receiver PRIVATE -DRAW_UDP=1)
endif() endif()

View File

@ -26,6 +26,7 @@
#include "galileo_e5a_pcps_acquisition.h" #include "galileo_e5a_pcps_acquisition.h"
#include "glonass_l1_ca_pcps_acquisition.h" #include "glonass_l1_ca_pcps_acquisition.h"
#include "glonass_l2_ca_pcps_acquisition.h" #include "glonass_l2_ca_pcps_acquisition.h"
#include "gnss_block_interface.h"
#include "gnss_sdr_valve.h" #include "gnss_sdr_valve.h"
#include "gnuplot_i.h" #include "gnuplot_i.h"
#include "gps_l1_ca_pcps_acquisition.h" #include "gps_l1_ca_pcps_acquisition.h"
@ -44,11 +45,6 @@
#include <pmt/pmt.h> #include <pmt/pmt.h>
#include <thread> #include <thread>
#include <utility> #include <utility>
#if GNURADIO_USES_STD_POINTERS
#include <memory>
#else
#include <boost/shared_ptr.hpp>
#endif
#if HAS_GENERIC_LAMBDA #if HAS_GENERIC_LAMBDA
#else #else
@ -110,11 +106,7 @@ DEFINE_bool(acq_test_dump, false, "Dump the results of an acquisition block into
// ######## GNURADIO BLOCK MESSAGE RECEVER ######### // ######## GNURADIO BLOCK MESSAGE RECEVER #########
class AcqPerfTest_msg_rx; class AcqPerfTest_msg_rx;
#if GNURADIO_USES_STD_POINTERS using AcqPerfTest_msg_rx_sptr = gnss_shared_ptr<AcqPerfTest_msg_rx>;
using AcqPerfTest_msg_rx_sptr = std::shared_ptr<AcqPerfTest_msg_rx>;
#else
using AcqPerfTest_msg_rx_sptr = boost::shared_ptr<AcqPerfTest_msg_rx>;
#endif
AcqPerfTest_msg_rx_sptr AcqPerfTest_msg_rx_make(Concurrent_Queue<int>& queue); AcqPerfTest_msg_rx_sptr AcqPerfTest_msg_rx_make(Concurrent_Queue<int>& queue);

View File

@ -47,19 +47,12 @@
#else #else
#include <gnuradio/analog/sig_source_c.h> #include <gnuradio/analog/sig_source_c.h>
#endif #endif
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
// ######## GNURADIO BLOCK MESSAGE RECEVER ######### // ######## GNURADIO BLOCK MESSAGE RECEVER #########
class GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx; class GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx;
#if GNURADIO_USES_STD_POINTERS using GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr = gnss_shared_ptr<GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx>;
using GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr = std::shared_ptr<GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx>;
#else
using GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr = boost::shared_ptr<GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx>;
#endif
GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx_make(Concurrent_Queue<int>& queue); GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr GalileoE1Pcps8msAmbiguousAcquisitionGSoC2013Test_msg_rx_make(Concurrent_Queue<int>& queue);

View File

@ -45,19 +45,11 @@
#else #else
#include <gnuradio/analog/sig_source_c.h> #include <gnuradio/analog/sig_source_c.h>
#endif #endif
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
// ######## GNURADIO BLOCK MESSAGE RECEVER ######### // ######## GNURADIO BLOCK MESSAGE RECEVER #########
class GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx; class GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx;
#if GNURADIO_USES_STD_POINTERS using GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr = gnss_shared_ptr<GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx>;
using GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr = std::shared_ptr<GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx>;
#else
using GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr = boost::shared_ptr<GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx>;
#endif
GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx_make(Concurrent_Queue<int>& queue); GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx_sptr GalileoE1PcpsAmbiguousAcquisitionGSoC2013Test_msg_rx_make(Concurrent_Queue<int>& queue);

View File

@ -55,18 +55,11 @@
#else #else
#include <gnuradio/analog/sig_source_c.h> #include <gnuradio/analog/sig_source_c.h>
#endif #endif
#if GNURADIO_USES_STD_POINTERS
#else
#include <boost/shared_ptr.hpp>
#endif
// ######## GNURADIO BLOCK MESSAGE RECEVER ######### // ######## GNURADIO BLOCK MESSAGE RECEVER #########
class GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx; class GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx;
#if GNURADIO_USES_STD_POINTERS
using GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx_sptr = std::shared_ptr<GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx>; using GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx_sptr = gnss_shared_ptr<GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx>;
#else
using GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx_sptr = boost::shared_ptr<GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx>;
#endif
GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx_sptr GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx_make(Concurrent_Queue<int>& queue); GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx_sptr GalileoE1PcpsAmbiguousAcquisitionGSoCTest_msg_rx_make(Concurrent_Queue<int>& queue);

Some files were not shown because too many files have changed in this diff Show More