mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2025-01-30 02:44:50 +00:00
Improve includes with IWYU
Rtcm class moved to PVT/libs
This commit is contained in:
parent
809097f481
commit
6eb81f52ee
@ -26,6 +26,7 @@ set(PVT_LIB_SOURCES
|
|||||||
rinex_printer.cc
|
rinex_printer.cc
|
||||||
nmea_printer.cc
|
nmea_printer.cc
|
||||||
rtcm_printer.cc
|
rtcm_printer.cc
|
||||||
|
rtcm.cc
|
||||||
geojson_printer.cc
|
geojson_printer.cc
|
||||||
rtklib_solver.cc
|
rtklib_solver.cc
|
||||||
pvt_conf.cc
|
pvt_conf.cc
|
||||||
@ -41,6 +42,7 @@ set(PVT_LIB_HEADERS
|
|||||||
rinex_printer.h
|
rinex_printer.h
|
||||||
nmea_printer.h
|
nmea_printer.h
|
||||||
rtcm_printer.h
|
rtcm_printer.h
|
||||||
|
rtcm.h
|
||||||
geojson_printer.h
|
geojson_printer.h
|
||||||
rtklib_solver.h
|
rtklib_solver.h
|
||||||
pvt_conf.h
|
pvt_conf.h
|
||||||
@ -59,10 +61,10 @@ target_link_libraries(pvt_libs
|
|||||||
PUBLIC
|
PUBLIC
|
||||||
Armadillo::armadillo
|
Armadillo::armadillo
|
||||||
Boost::date_time
|
Boost::date_time
|
||||||
algorithms_libs
|
|
||||||
algorithms_libs_rtklib
|
algorithms_libs_rtklib
|
||||||
core_system_parameters
|
core_system_parameters
|
||||||
PRIVATE
|
PRIVATE
|
||||||
|
algorithms_libs
|
||||||
Boost::filesystem
|
Boost::filesystem
|
||||||
Boost::system
|
Boost::system
|
||||||
Gflags::gflags
|
Gflags::gflags
|
||||||
@ -72,13 +74,20 @@ target_link_libraries(pvt_libs
|
|||||||
|
|
||||||
target_include_directories(pvt_libs
|
target_include_directories(pvt_libs
|
||||||
PUBLIC
|
PUBLIC
|
||||||
${CMAKE_SOURCE_DIR}/src/algorithms/libs
|
|
||||||
${CMAKE_SOURCE_DIR}/src/algorithms/libs/rtklib
|
|
||||||
${CMAKE_SOURCE_DIR}/src/core/receiver
|
${CMAKE_SOURCE_DIR}/src/core/receiver
|
||||||
)
|
)
|
||||||
|
|
||||||
target_compile_definitions(pvt_libs PRIVATE -DGNSS_SDR_VERSION="${VERSION}")
|
target_compile_definitions(pvt_libs PRIVATE -DGNSS_SDR_VERSION="${VERSION}")
|
||||||
|
|
||||||
|
if(OS_IS_MACOSX)
|
||||||
|
if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") # not AppleClang
|
||||||
|
target_compile_definitions(pvt_libs
|
||||||
|
PUBLIC
|
||||||
|
-DBOOST_ASIO_HAS_STD_STRING_VIEW
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
if(ENABLE_CLANG_TIDY)
|
if(ENABLE_CLANG_TIDY)
|
||||||
if(CLANG_TIDY_EXE)
|
if(CLANG_TIDY_EXE)
|
||||||
set_target_properties(pvt_libs
|
set_target_properties(pvt_libs
|
||||||
|
@ -40,7 +40,6 @@
|
|||||||
#include <cmath> // for std::fmod
|
#include <cmath> // for std::fmod
|
||||||
#include <cstdlib> // for strtol
|
#include <cstdlib> // for strtol
|
||||||
#include <sstream> // for std::stringstream
|
#include <sstream> // for std::stringstream
|
||||||
#include <thread>
|
|
||||||
|
|
||||||
|
|
||||||
Rtcm::Rtcm(uint16_t port)
|
Rtcm::Rtcm(uint16_t port)
|
@ -43,7 +43,9 @@
|
|||||||
#include <boost/date_time/posix_time/posix_time.hpp>
|
#include <boost/date_time/posix_time/posix_time.hpp>
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <bitset>
|
#include <bitset>
|
||||||
|
#include <cstddef> // for size_t
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
|
#include <cstring> // for memcpy
|
||||||
#include <deque>
|
#include <deque>
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <memory>
|
#include <memory>
|
@ -30,6 +30,7 @@ target_link_libraries(channel_adapters
|
|||||||
PUBLIC
|
PUBLIC
|
||||||
Gnuradio::runtime
|
Gnuradio::runtime
|
||||||
channel_libs
|
channel_libs
|
||||||
|
core_system_parameters
|
||||||
PRIVATE
|
PRIVATE
|
||||||
Gflags::gflags
|
Gflags::gflags
|
||||||
Glog::glog
|
Glog::glog
|
||||||
|
@ -31,12 +31,13 @@
|
|||||||
|
|
||||||
#include "channel.h"
|
#include "channel.h"
|
||||||
#include "acquisition_interface.h"
|
#include "acquisition_interface.h"
|
||||||
|
#include "channel_fsm.h"
|
||||||
#include "configuration_interface.h"
|
#include "configuration_interface.h"
|
||||||
#include "gnss_sdr_flags.h"
|
#include "gnss_sdr_flags.h"
|
||||||
#include "telemetry_decoder_interface.h"
|
#include "telemetry_decoder_interface.h"
|
||||||
#include "tracking_interface.h"
|
#include "tracking_interface.h"
|
||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <cstdint>
|
#include <cstring> // for memcpy
|
||||||
#include <utility>
|
#include <utility>
|
||||||
|
|
||||||
|
|
||||||
@ -204,8 +205,7 @@ void Channel::stop_channel()
|
|||||||
LOG(WARNING) << "Invalid channel event";
|
LOG(WARNING) << "Invalid channel event";
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
DLOG(INFO)
|
DLOG(INFO) << "Channel stop_channel()";
|
||||||
<< "Channel stop_channel()";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -35,7 +35,6 @@
|
|||||||
#ifndef GNSS_SDR_CHANNEL_H_
|
#ifndef GNSS_SDR_CHANNEL_H_
|
||||||
#define GNSS_SDR_CHANNEL_H_
|
#define GNSS_SDR_CHANNEL_H_
|
||||||
|
|
||||||
#include "channel_fsm.h"
|
|
||||||
#include "channel_interface.h"
|
#include "channel_interface.h"
|
||||||
#include "channel_msg_receiver_cc.h"
|
#include "channel_msg_receiver_cc.h"
|
||||||
#include "gnss_signal.h"
|
#include "gnss_signal.h"
|
||||||
@ -52,6 +51,7 @@ class ConfigurationInterface;
|
|||||||
class AcquisitionInterface;
|
class AcquisitionInterface;
|
||||||
class TrackingInterface;
|
class TrackingInterface;
|
||||||
class TelemetryDecoderInterface;
|
class TelemetryDecoderInterface;
|
||||||
|
class ChannelFsm;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
* \brief This class represents a GNSS channel. It wraps an AcquisitionInterface,
|
* \brief This class represents a GNSS channel. It wraps an AcquisitionInterface,
|
||||||
|
@ -40,7 +40,6 @@ set(GNSS_SPLIBS_SOURCES
|
|||||||
conjugate_ic.cc
|
conjugate_ic.cc
|
||||||
gnss_sdr_create_directory.cc
|
gnss_sdr_create_directory.cc
|
||||||
geofunctions.cc
|
geofunctions.cc
|
||||||
rtcm.cc
|
|
||||||
)
|
)
|
||||||
|
|
||||||
set(GNSS_SPLIBS_HEADERS
|
set(GNSS_SPLIBS_HEADERS
|
||||||
@ -66,7 +65,6 @@ set(GNSS_SPLIBS_HEADERS
|
|||||||
gnss_sdr_create_directory.h
|
gnss_sdr_create_directory.h
|
||||||
gnss_circular_deque.h
|
gnss_circular_deque.h
|
||||||
geofunctions.h
|
geofunctions.h
|
||||||
rtcm.h
|
|
||||||
)
|
)
|
||||||
|
|
||||||
if(ENABLE_FPGA)
|
if(ENABLE_FPGA)
|
||||||
@ -114,20 +112,18 @@ target_link_libraries(algorithms_libs
|
|||||||
Gflags::gflags
|
Gflags::gflags
|
||||||
Gnuradio::runtime
|
Gnuradio::runtime
|
||||||
Gnuradio::blocks
|
Gnuradio::blocks
|
||||||
Volk::volk ${ORC_LIBRARIES}
|
|
||||||
Volkgnsssdr::volkgnsssdr
|
|
||||||
core_system_parameters
|
|
||||||
${OPT_LIBRARIES}
|
${OPT_LIBRARIES}
|
||||||
PRIVATE
|
PRIVATE
|
||||||
|
core_system_parameters
|
||||||
|
Volk::volk ${ORC_LIBRARIES}
|
||||||
|
Volkgnsssdr::volkgnsssdr
|
||||||
Boost::filesystem
|
Boost::filesystem
|
||||||
Gflags::gflags
|
|
||||||
Glog::glog
|
Glog::glog
|
||||||
)
|
)
|
||||||
|
|
||||||
target_include_directories(algorithms_libs
|
target_include_directories(algorithms_libs
|
||||||
PUBLIC
|
PUBLIC
|
||||||
${CMAKE_SOURCE_DIR}/src/core/interfaces
|
${CMAKE_SOURCE_DIR}/src/core/interfaces
|
||||||
${CMAKE_SOURCE_DIR}/src/core/receiver
|
|
||||||
)
|
)
|
||||||
|
|
||||||
target_compile_definitions(algorithms_libs
|
target_compile_definitions(algorithms_libs
|
||||||
@ -139,15 +135,6 @@ set_property(TARGET algorithms_libs
|
|||||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
|
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
|
||||||
)
|
)
|
||||||
|
|
||||||
if(OS_IS_MACOSX)
|
|
||||||
if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") # not AppleClang
|
|
||||||
target_compile_definitions(algorithms_libs
|
|
||||||
PUBLIC
|
|
||||||
-DBOOST_ASIO_HAS_STD_STRING_VIEW
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if(ENABLE_CLANG_TIDY)
|
if(ENABLE_CLANG_TIDY)
|
||||||
if(CLANG_TIDY_EXE)
|
if(CLANG_TIDY_EXE)
|
||||||
set_target_properties(algorithms_libs
|
set_target_properties(algorithms_libs
|
||||||
|
@ -31,7 +31,10 @@
|
|||||||
|
|
||||||
#include "byte_x2_to_complex_byte.h"
|
#include "byte_x2_to_complex_byte.h"
|
||||||
#include <gnuradio/io_signature.h>
|
#include <gnuradio/io_signature.h>
|
||||||
#include <volk/volk.h>
|
#include <volk_gnsssdr/volk_gnsssdr.h>
|
||||||
|
#include <algorithm> // for max
|
||||||
|
#include <complex> // for complex
|
||||||
|
#include <cstdint> // for int8_t
|
||||||
|
|
||||||
|
|
||||||
byte_x2_to_complex_byte_sptr make_byte_x2_to_complex_byte()
|
byte_x2_to_complex_byte_sptr make_byte_x2_to_complex_byte()
|
||||||
@ -44,7 +47,7 @@ byte_x2_to_complex_byte::byte_x2_to_complex_byte() : sync_block("byte_x2_to_comp
|
|||||||
gr::io_signature::make(2, 2, sizeof(int8_t)), // int8_t, defined in stdint.h and included in volk.h (signed char)
|
gr::io_signature::make(2, 2, sizeof(int8_t)), // int8_t, defined in stdint.h and included in volk.h (signed char)
|
||||||
gr::io_signature::make(1, 1, sizeof(lv_8sc_t))) // lv_8sc_t is a Volk's typedef for std::complex<signed char>
|
gr::io_signature::make(1, 1, sizeof(lv_8sc_t))) // lv_8sc_t is a Volk's typedef for std::complex<signed char>
|
||||||
{
|
{
|
||||||
const int alignment_multiple = volk_get_alignment() / sizeof(lv_8sc_t);
|
const int alignment_multiple = volk_gnsssdr_get_alignment() / sizeof(lv_8sc_t);
|
||||||
set_alignment(std::max(1, alignment_multiple));
|
set_alignment(std::max(1, alignment_multiple));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -34,6 +34,7 @@
|
|||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
#include <gnuradio/sync_block.h>
|
#include <gnuradio/sync_block.h>
|
||||||
|
#include <gnuradio/types.h> // for gr_vector_const_void_star
|
||||||
|
|
||||||
class byte_x2_to_complex_byte;
|
class byte_x2_to_complex_byte;
|
||||||
|
|
||||||
@ -49,10 +50,9 @@ class byte_x2_to_complex_byte : public gr::sync_block
|
|||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
friend byte_x2_to_complex_byte_sptr make_byte_x2_to_complex_byte();
|
friend byte_x2_to_complex_byte_sptr make_byte_x2_to_complex_byte();
|
||||||
|
|
||||||
public:
|
|
||||||
byte_x2_to_complex_byte();
|
byte_x2_to_complex_byte();
|
||||||
|
|
||||||
|
public:
|
||||||
int work(int noutput_items,
|
int work(int noutput_items,
|
||||||
gr_vector_const_void_star &input_items,
|
gr_vector_const_void_star &input_items,
|
||||||
gr_vector_void_star &output_items);
|
gr_vector_void_star &output_items);
|
||||||
|
@ -32,6 +32,7 @@
|
|||||||
#include "complex_byte_to_float_x2.h"
|
#include "complex_byte_to_float_x2.h"
|
||||||
#include <gnuradio/io_signature.h>
|
#include <gnuradio/io_signature.h>
|
||||||
#include <volk/volk.h>
|
#include <volk/volk.h>
|
||||||
|
#include <algorithm> // for max
|
||||||
|
|
||||||
|
|
||||||
complex_byte_to_float_x2_sptr make_complex_byte_to_float_x2()
|
complex_byte_to_float_x2_sptr make_complex_byte_to_float_x2()
|
||||||
|
@ -34,6 +34,7 @@
|
|||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
#include <gnuradio/sync_block.h>
|
#include <gnuradio/sync_block.h>
|
||||||
|
#include <gnuradio/types.h> // for gr_vector_const_void_star
|
||||||
|
|
||||||
class complex_byte_to_float_x2;
|
class complex_byte_to_float_x2;
|
||||||
|
|
||||||
@ -49,10 +50,9 @@ class complex_byte_to_float_x2 : public gr::sync_block
|
|||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
friend complex_byte_to_float_x2_sptr make_complex_byte_to_float_x2();
|
friend complex_byte_to_float_x2_sptr make_complex_byte_to_float_x2();
|
||||||
|
|
||||||
public:
|
|
||||||
complex_byte_to_float_x2();
|
complex_byte_to_float_x2();
|
||||||
|
|
||||||
|
public:
|
||||||
int work(int noutput_items,
|
int work(int noutput_items,
|
||||||
gr_vector_const_void_star &input_items,
|
gr_vector_const_void_star &input_items,
|
||||||
gr_vector_void_star &output_items);
|
gr_vector_void_star &output_items);
|
||||||
|
@ -32,7 +32,7 @@
|
|||||||
#include "complex_float_to_complex_byte.h"
|
#include "complex_float_to_complex_byte.h"
|
||||||
#include <gnuradio/io_signature.h>
|
#include <gnuradio/io_signature.h>
|
||||||
#include <volk_gnsssdr/volk_gnsssdr.h>
|
#include <volk_gnsssdr/volk_gnsssdr.h>
|
||||||
|
#include <algorithm> // for max
|
||||||
|
|
||||||
complex_float_to_complex_byte_sptr make_complex_float_to_complex_byte()
|
complex_float_to_complex_byte_sptr make_complex_float_to_complex_byte()
|
||||||
{
|
{
|
||||||
|
@ -33,6 +33,8 @@
|
|||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
#include <gnuradio/sync_block.h>
|
#include <gnuradio/sync_block.h>
|
||||||
|
#include <gnuradio/types.h> // for gr_vector_const_void_star
|
||||||
|
|
||||||
|
|
||||||
class complex_float_to_complex_byte;
|
class complex_float_to_complex_byte;
|
||||||
|
|
||||||
@ -47,10 +49,9 @@ class complex_float_to_complex_byte : public gr::sync_block
|
|||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
friend complex_float_to_complex_byte_sptr make_complex_float_to_complex_byte();
|
friend complex_float_to_complex_byte_sptr make_complex_float_to_complex_byte();
|
||||||
|
|
||||||
public:
|
|
||||||
complex_float_to_complex_byte();
|
complex_float_to_complex_byte();
|
||||||
|
|
||||||
|
public:
|
||||||
int work(int noutput_items,
|
int work(int noutput_items,
|
||||||
gr_vector_const_void_star &input_items,
|
gr_vector_const_void_star &input_items,
|
||||||
gr_vector_void_star &output_items);
|
gr_vector_void_star &output_items);
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
#include "conjugate_cc.h"
|
#include "conjugate_cc.h"
|
||||||
#include <gnuradio/io_signature.h>
|
#include <gnuradio/io_signature.h>
|
||||||
#include <volk/volk.h>
|
#include <volk/volk.h>
|
||||||
|
#include <algorithm> // for max
|
||||||
|
|
||||||
|
|
||||||
conjugate_cc_sptr make_conjugate_cc()
|
conjugate_cc_sptr make_conjugate_cc()
|
||||||
|
@ -33,6 +33,7 @@
|
|||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
#include <gnuradio/sync_block.h>
|
#include <gnuradio/sync_block.h>
|
||||||
|
#include <gnuradio/types.h> // for gr_vector_const_void_star
|
||||||
|
|
||||||
class conjugate_cc;
|
class conjugate_cc;
|
||||||
|
|
||||||
@ -48,10 +49,9 @@ class conjugate_cc : public gr::sync_block
|
|||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
friend conjugate_cc_sptr make_conjugate_cc();
|
friend conjugate_cc_sptr make_conjugate_cc();
|
||||||
|
|
||||||
public:
|
|
||||||
conjugate_cc();
|
conjugate_cc();
|
||||||
|
|
||||||
|
public:
|
||||||
int work(int noutput_items,
|
int work(int noutput_items,
|
||||||
gr_vector_const_void_star &input_items,
|
gr_vector_const_void_star &input_items,
|
||||||
gr_vector_void_star &output_items);
|
gr_vector_void_star &output_items);
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
#include "conjugate_ic.h"
|
#include "conjugate_ic.h"
|
||||||
#include <gnuradio/io_signature.h>
|
#include <gnuradio/io_signature.h>
|
||||||
#include <volk_gnsssdr/volk_gnsssdr.h>
|
#include <volk_gnsssdr/volk_gnsssdr.h>
|
||||||
|
#include <algorithm> // for max
|
||||||
|
|
||||||
|
|
||||||
conjugate_ic_sptr make_conjugate_ic()
|
conjugate_ic_sptr make_conjugate_ic()
|
||||||
|
@ -33,6 +33,7 @@
|
|||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
#include <gnuradio/sync_block.h>
|
#include <gnuradio/sync_block.h>
|
||||||
|
#include <gnuradio/types.h> // for gr_vector_const_void_star
|
||||||
|
|
||||||
class conjugate_ic;
|
class conjugate_ic;
|
||||||
|
|
||||||
@ -48,10 +49,9 @@ class conjugate_ic : public gr::sync_block
|
|||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
friend conjugate_ic_sptr make_conjugate_ic();
|
friend conjugate_ic_sptr make_conjugate_ic();
|
||||||
|
|
||||||
public:
|
|
||||||
conjugate_ic();
|
conjugate_ic();
|
||||||
|
|
||||||
|
public:
|
||||||
int work(int noutput_items,
|
int work(int noutput_items,
|
||||||
gr_vector_const_void_star &input_items,
|
gr_vector_const_void_star &input_items,
|
||||||
gr_vector_void_star &output_items);
|
gr_vector_void_star &output_items);
|
||||||
|
@ -31,7 +31,7 @@
|
|||||||
#include "conjugate_sc.h"
|
#include "conjugate_sc.h"
|
||||||
#include <gnuradio/io_signature.h>
|
#include <gnuradio/io_signature.h>
|
||||||
#include <volk_gnsssdr/volk_gnsssdr.h>
|
#include <volk_gnsssdr/volk_gnsssdr.h>
|
||||||
|
#include <algorithm> // for max
|
||||||
|
|
||||||
conjugate_sc_sptr make_conjugate_sc()
|
conjugate_sc_sptr make_conjugate_sc()
|
||||||
{
|
{
|
||||||
|
@ -33,6 +33,7 @@
|
|||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
#include <gnuradio/sync_block.h>
|
#include <gnuradio/sync_block.h>
|
||||||
|
#include <gnuradio/types.h> // for gr_vector_const_void_star
|
||||||
|
|
||||||
class conjugate_sc;
|
class conjugate_sc;
|
||||||
|
|
||||||
@ -48,10 +49,9 @@ class conjugate_sc : public gr::sync_block
|
|||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
friend conjugate_sc_sptr make_conjugate_sc();
|
friend conjugate_sc_sptr make_conjugate_sc();
|
||||||
|
|
||||||
public:
|
|
||||||
conjugate_sc();
|
conjugate_sc();
|
||||||
|
|
||||||
|
public:
|
||||||
int work(int noutput_items,
|
int work(int noutput_items,
|
||||||
gr_vector_const_void_star &input_items,
|
gr_vector_const_void_star &input_items,
|
||||||
gr_vector_void_star &output_items);
|
gr_vector_void_star &output_items);
|
||||||
|
@ -32,6 +32,7 @@
|
|||||||
#include "cshort_to_float_x2.h"
|
#include "cshort_to_float_x2.h"
|
||||||
#include <gnuradio/io_signature.h>
|
#include <gnuradio/io_signature.h>
|
||||||
#include <volk/volk.h>
|
#include <volk/volk.h>
|
||||||
|
#include <algorithm> // for max
|
||||||
|
|
||||||
|
|
||||||
cshort_to_float_x2_sptr make_cshort_to_float_x2()
|
cshort_to_float_x2_sptr make_cshort_to_float_x2()
|
||||||
|
@ -34,6 +34,7 @@
|
|||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
#include <gnuradio/sync_block.h>
|
#include <gnuradio/sync_block.h>
|
||||||
|
#include <gnuradio/types.h> // for gr_vector_const_void_star
|
||||||
|
|
||||||
class cshort_to_float_x2;
|
class cshort_to_float_x2;
|
||||||
|
|
||||||
@ -49,10 +50,9 @@ class cshort_to_float_x2 : public gr::sync_block
|
|||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
friend cshort_to_float_x2_sptr make_cshort_to_float_x2();
|
friend cshort_to_float_x2_sptr make_cshort_to_float_x2();
|
||||||
|
|
||||||
public:
|
|
||||||
cshort_to_float_x2();
|
cshort_to_float_x2();
|
||||||
|
|
||||||
|
public:
|
||||||
int work(int noutput_items,
|
int work(int noutput_items,
|
||||||
gr_vector_const_void_star &input_items,
|
gr_vector_const_void_star &input_items,
|
||||||
gr_vector_void_star &output_items);
|
gr_vector_void_star &output_items);
|
||||||
|
@ -35,8 +35,10 @@
|
|||||||
#include <glog/logging.h>
|
#include <glog/logging.h>
|
||||||
#include <gnuradio/gr_complex.h>
|
#include <gnuradio/gr_complex.h>
|
||||||
#include <volk/volk_complex.h>
|
#include <volk/volk_complex.h>
|
||||||
|
#include <cstdint> // for int8_t
|
||||||
#include <ostream> // for operator<<
|
#include <ostream> // for operator<<
|
||||||
|
|
||||||
|
|
||||||
Pass_Through::Pass_Through(ConfigurationInterface* configuration, const std::string& role,
|
Pass_Through::Pass_Through(ConfigurationInterface* configuration, const std::string& role,
|
||||||
unsigned int in_streams,
|
unsigned int in_streams,
|
||||||
unsigned int out_streams) : role_(role),
|
unsigned int out_streams) : role_(role),
|
||||||
|
@ -31,8 +31,9 @@
|
|||||||
|
|
||||||
#include "short_x2_to_cshort.h"
|
#include "short_x2_to_cshort.h"
|
||||||
#include <gnuradio/io_signature.h>
|
#include <gnuradio/io_signature.h>
|
||||||
#include <volk/volk.h>
|
#include <volk_gnsssdr/volk_gnsssdr.h>
|
||||||
|
#include <algorithm> // for max
|
||||||
|
#include <complex> // for complex
|
||||||
|
|
||||||
short_x2_to_cshort_sptr make_short_x2_to_cshort()
|
short_x2_to_cshort_sptr make_short_x2_to_cshort()
|
||||||
{
|
{
|
||||||
@ -44,7 +45,7 @@ short_x2_to_cshort::short_x2_to_cshort() : sync_block("short_x2_to_cshort",
|
|||||||
gr::io_signature::make(2, 2, sizeof(int16_t)),
|
gr::io_signature::make(2, 2, sizeof(int16_t)),
|
||||||
gr::io_signature::make(1, 1, sizeof(lv_16sc_t)))
|
gr::io_signature::make(1, 1, sizeof(lv_16sc_t)))
|
||||||
{
|
{
|
||||||
const int alignment_multiple = volk_get_alignment() / sizeof(lv_16sc_t);
|
const int alignment_multiple = volk_gnsssdr_get_alignment() / sizeof(lv_16sc_t);
|
||||||
set_alignment(std::max(1, alignment_multiple));
|
set_alignment(std::max(1, alignment_multiple));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -61,7 +62,6 @@ int short_x2_to_cshort::work(int noutput_items,
|
|||||||
int16_t imag_part;
|
int16_t imag_part;
|
||||||
for (int number = 0; number < noutput_items; number++)
|
for (int number = 0; number < noutput_items; number++)
|
||||||
{
|
{
|
||||||
// lv_cmake(r, i) defined at volk/volk_complex.h
|
|
||||||
real_part = *in0++;
|
real_part = *in0++;
|
||||||
imag_part = *in1++;
|
imag_part = *in1++;
|
||||||
*out++ = lv_cmake(real_part, imag_part);
|
*out++ = lv_cmake(real_part, imag_part);
|
||||||
|
@ -34,6 +34,7 @@
|
|||||||
|
|
||||||
#include <boost/shared_ptr.hpp>
|
#include <boost/shared_ptr.hpp>
|
||||||
#include <gnuradio/sync_block.h>
|
#include <gnuradio/sync_block.h>
|
||||||
|
#include <gnuradio/types.h> // for gr_vector_const_void_star
|
||||||
|
|
||||||
class short_x2_to_cshort;
|
class short_x2_to_cshort;
|
||||||
|
|
||||||
@ -48,10 +49,9 @@ class short_x2_to_cshort : public gr::sync_block
|
|||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
friend short_x2_to_cshort_sptr make_short_x2_to_cshort();
|
friend short_x2_to_cshort_sptr make_short_x2_to_cshort();
|
||||||
|
|
||||||
public:
|
|
||||||
short_x2_to_cshort();
|
short_x2_to_cshort();
|
||||||
|
|
||||||
|
public:
|
||||||
int work(int noutput_items,
|
int work(int noutput_items,
|
||||||
gr_vector_const_void_star &input_items,
|
gr_vector_const_void_star &input_items,
|
||||||
gr_vector_void_star &output_items);
|
gr_vector_void_star &output_items);
|
||||||
|
Loading…
Reference in New Issue
Block a user