mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2026-04-21 14:21:26 +00:00
Fix low-impact performance inefficiency defects detected by Coverity Scan 2024.6
Reduce defect noise so other defects are easier spotted
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
#include "pvt_conf.h" // for Pvt_Conf
|
||||
#include "rtklib_rtkpos.h" // for rtkfree, rtkinit
|
||||
#include <iostream> // for std::cout
|
||||
#include <utility> // for std::move
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
#else
|
||||
@@ -62,7 +63,7 @@ Rtklib_Pvt::Rtklib_Pvt(const ConfigurationInterface* configuration,
|
||||
const std::string default_rtcm_dump_devname("/dev/pts/1");
|
||||
DLOG(INFO) << "role " << role;
|
||||
pvt_output_parameters.dump = configuration->property(role + ".dump", false);
|
||||
pvt_output_parameters.dump_filename = configuration->property(role + ".dump_filename", default_dump_filename);
|
||||
pvt_output_parameters.dump_filename = configuration->property(role + ".dump_filename", std::move(default_dump_filename));
|
||||
pvt_output_parameters.dump_mat = configuration->property(role + ".dump_mat", true);
|
||||
|
||||
pvt_output_parameters.rtk_trace_level = configuration->property(role + ".rtk_trace_level"s, 0);
|
||||
@@ -87,7 +88,7 @@ Rtklib_Pvt::Rtklib_Pvt(const ConfigurationInterface* configuration,
|
||||
|
||||
// NMEA Printer settings
|
||||
pvt_output_parameters.flag_nmea_tty_port = configuration->property(role + ".flag_nmea_tty_port", false);
|
||||
pvt_output_parameters.nmea_dump_filename = configuration->property(role + ".nmea_dump_filename", default_nmea_dump_filename);
|
||||
pvt_output_parameters.nmea_dump_filename = configuration->property(role + ".nmea_dump_filename", std::move(default_nmea_dump_filename));
|
||||
pvt_output_parameters.nmea_dump_devname = configuration->property(role + ".nmea_dump_devname", default_nmea_dump_devname);
|
||||
|
||||
// RINEX version
|
||||
@@ -126,7 +127,7 @@ Rtklib_Pvt::Rtklib_Pvt(const ConfigurationInterface* configuration,
|
||||
#endif
|
||||
// RTCM Printer settings
|
||||
pvt_output_parameters.flag_rtcm_tty_port = configuration->property(role + ".flag_rtcm_tty_port", false);
|
||||
pvt_output_parameters.rtcm_dump_devname = configuration->property(role + ".rtcm_dump_devname", default_rtcm_dump_devname);
|
||||
pvt_output_parameters.rtcm_dump_devname = configuration->property(role + ".rtcm_dump_devname", std::move(default_rtcm_dump_devname));
|
||||
pvt_output_parameters.flag_rtcm_server = configuration->property(role + ".flag_rtcm_server", false);
|
||||
pvt_output_parameters.rtcm_tcp_port = configuration->property(role + ".rtcm_tcp_port", 2101);
|
||||
pvt_output_parameters.rtcm_station_id = configuration->property(role + ".rtcm_station_id", 1234);
|
||||
@@ -157,7 +158,7 @@ Rtklib_Pvt::Rtklib_Pvt(const ConfigurationInterface* configuration,
|
||||
|
||||
// Advanced Nativation Protocol Printer settings
|
||||
pvt_output_parameters.an_output_enabled = configuration->property(role + ".an_output_enabled", pvt_output_parameters.an_output_enabled);
|
||||
pvt_output_parameters.an_dump_devname = configuration->property(role + ".an_dump_devname", default_nmea_dump_devname);
|
||||
pvt_output_parameters.an_dump_devname = configuration->property(role + ".an_dump_devname", std::move(default_nmea_dump_devname));
|
||||
if (pvt_output_parameters.an_output_enabled && pvt_output_parameters.flag_nmea_tty_port)
|
||||
{
|
||||
if (pvt_output_parameters.nmea_dump_devname == pvt_output_parameters.an_dump_devname)
|
||||
@@ -496,7 +497,7 @@ Rtklib_Pvt::Rtklib_Pvt(const ConfigurationInterface* configuration,
|
||||
// Settings 1
|
||||
int positioning_mode = -1;
|
||||
const std::string default_pos_mode("Single");
|
||||
const std::string positioning_mode_str = configuration->property(role + ".positioning_mode", default_pos_mode); // (PMODE_XXX) see src/algorithms/libs/rtklib/rtklib.h
|
||||
const std::string positioning_mode_str = configuration->property(role + ".positioning_mode", std::move(default_pos_mode)); // (PMODE_XXX) see src/algorithms/libs/rtklib/rtklib.h
|
||||
if (positioning_mode_str == "Single")
|
||||
{
|
||||
positioning_mode = PMODE_SINGLE;
|
||||
@@ -581,7 +582,7 @@ Rtklib_Pvt::Rtklib_Pvt(const ConfigurationInterface* configuration,
|
||||
}
|
||||
|
||||
const std::string default_iono_model("OFF");
|
||||
const std::string iono_model_str = configuration->property(role + ".iono_model", default_iono_model); /* (IONOOPT_XXX) see src/algorithms/libs/rtklib/rtklib.h */
|
||||
const std::string iono_model_str = configuration->property(role + ".iono_model", std::move(default_iono_model)); /* (IONOOPT_XXX) see src/algorithms/libs/rtklib/rtklib.h */
|
||||
int iono_model = -1;
|
||||
if (iono_model_str == "OFF")
|
||||
{
|
||||
@@ -620,7 +621,7 @@ Rtklib_Pvt::Rtklib_Pvt(const ConfigurationInterface* configuration,
|
||||
|
||||
const std::string default_trop_model("OFF");
|
||||
int trop_model = -1;
|
||||
const std::string trop_model_str = configuration->property(role + ".trop_model", default_trop_model); /* (TROPOPT_XXX) see src/algorithms/libs/rtklib/rtklib.h */
|
||||
const std::string trop_model_str = configuration->property(role + ".trop_model", std::move(default_trop_model)); /* (TROPOPT_XXX) see src/algorithms/libs/rtklib/rtklib.h */
|
||||
if (trop_model_str == "OFF")
|
||||
{
|
||||
trop_model = TROPOPT_OFF;
|
||||
@@ -698,7 +699,7 @@ Rtklib_Pvt::Rtklib_Pvt(const ConfigurationInterface* configuration,
|
||||
|
||||
// Settings 2
|
||||
const std::string default_gps_ar("Continuous");
|
||||
const std::string integer_ambiguity_resolution_gps_str = configuration->property(role + ".AR_GPS", default_gps_ar); /* Integer Ambiguity Resolution mode for GPS (0:off,1:continuous,2:instantaneous,3:fix and hold,4:ppp-ar) */
|
||||
const std::string integer_ambiguity_resolution_gps_str = configuration->property(role + ".AR_GPS", std::move(default_gps_ar)); /* Integer Ambiguity Resolution mode for GPS (0:off,1:continuous,2:instantaneous,3:fix and hold,4:ppp-ar) */
|
||||
int integer_ambiguity_resolution_gps = -1;
|
||||
if (integer_ambiguity_resolution_gps_str == "OFF")
|
||||
{
|
||||
@@ -882,7 +883,7 @@ Rtklib_Pvt::Rtklib_Pvt(const ConfigurationInterface* configuration,
|
||||
pvt_output_parameters.xml_output_path = configuration->property(role + ".xml_output_path", default_output_path);
|
||||
pvt_output_parameters.nmea_output_file_path = configuration->property(role + ".nmea_output_file_path", default_output_path);
|
||||
pvt_output_parameters.rtcm_output_file_path = configuration->property(role + ".rtcm_output_file_path", default_output_path);
|
||||
pvt_output_parameters.has_output_file_path = configuration->property(role + ".has_output_file_path", default_output_path);
|
||||
pvt_output_parameters.has_output_file_path = configuration->property(role + ".has_output_file_path", std::move(default_output_path));
|
||||
|
||||
// Read PVT MONITOR Configuration
|
||||
pvt_output_parameters.monitor_enabled = configuration->property(role + ".enable_monitor", false);
|
||||
|
||||
@@ -3342,7 +3342,7 @@ std::vector<std::string> Rtcm::print_IGM01(const Galileo_HAS_data& has_data)
|
||||
{
|
||||
rtcm_message_queue->push(message);
|
||||
}
|
||||
msgs.push_back(message);
|
||||
msgs.push_back(std::move(message));
|
||||
}
|
||||
return msgs;
|
||||
}
|
||||
@@ -3366,7 +3366,7 @@ std::vector<std::string> Rtcm::print_IGM02(const Galileo_HAS_data& has_data)
|
||||
{
|
||||
rtcm_message_queue->push(message);
|
||||
}
|
||||
msgs.push_back(message);
|
||||
msgs.push_back(std::move(message));
|
||||
}
|
||||
return msgs;
|
||||
}
|
||||
@@ -3390,7 +3390,7 @@ std::vector<std::string> Rtcm::print_IGM03(const Galileo_HAS_data& has_data)
|
||||
{
|
||||
rtcm_message_queue->push(message);
|
||||
}
|
||||
msgs.push_back(message);
|
||||
msgs.push_back(std::move(message));
|
||||
}
|
||||
return msgs;
|
||||
}
|
||||
@@ -3416,7 +3416,7 @@ std::vector<std::string> Rtcm::print_IGM05(const Galileo_HAS_data& has_data)
|
||||
{
|
||||
rtcm_message_queue->push(message);
|
||||
}
|
||||
msgs.push_back(message);
|
||||
msgs.push_back(std::move(message));
|
||||
}
|
||||
}
|
||||
return msgs;
|
||||
|
||||
@@ -311,7 +311,7 @@ bool Rtklib_Solver::save_matfile() const
|
||||
// WRITE MAT FILE
|
||||
mat_t *matfp;
|
||||
matvar_t *matvar;
|
||||
std::string filename = dump_filename;
|
||||
std::string filename = std::move(dump_filename);
|
||||
filename.erase(filename.length() - 4, 4);
|
||||
filename.append(".mat");
|
||||
matfp = Mat_CreateVer(filename.c_str(), nullptr, MAT_FT_MAT73);
|
||||
|
||||
@@ -58,10 +58,10 @@ GalileoE1Pcps8msAmbiguousAcquisition::GalileoE1Pcps8msAmbiguousAcquisition(
|
||||
{
|
||||
const std::string default_item_type("gr_complex");
|
||||
const std::string default_dump_filename("./acquisition.dat");
|
||||
item_type_ = configuration_->property(role_ + ".item_type", default_item_type);
|
||||
item_type_ = configuration_->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int64_t fs_in_deprecated = configuration_->property("GNSS-SDR.internal_fs_hz", 4000000);
|
||||
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
dump_filename_ = configuration_->property(role_ + ".dump_filename", default_dump_filename);
|
||||
dump_filename_ = configuration_->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
if (FLAGS_doppler_max != 0)
|
||||
|
||||
@@ -49,10 +49,10 @@ GalileoE1PcpsCccwsrAmbiguousAcquisition::GalileoE1PcpsCccwsrAmbiguousAcquisition
|
||||
{
|
||||
const std::string default_item_type("gr_complex");
|
||||
const std::string default_dump_filename("./acquisition.dat");
|
||||
item_type_ = configuration_->property(role_ + ".item_type", default_item_type);
|
||||
item_type_ = configuration_->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int64_t fs_in_deprecated = configuration_->property("GNSS-SDR.internal_fs_hz", 4000000);
|
||||
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
dump_filename_ = configuration_->property(role_ + ".dump_filename", default_dump_filename);
|
||||
dump_filename_ = configuration_->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
if (FLAGS_doppler_max != 0)
|
||||
|
||||
@@ -58,10 +58,10 @@ GalileoE1PcpsQuickSyncAmbiguousAcquisition::GalileoE1PcpsQuickSyncAmbiguousAcqui
|
||||
{
|
||||
const std::string default_item_type("gr_complex");
|
||||
const std::string default_dump_filename("./acquisition.dat");
|
||||
item_type_ = configuration_->property(role + ".item_type", default_item_type);
|
||||
item_type_ = configuration_->property(role + ".item_type", std::move(default_item_type));
|
||||
int64_t fs_in_deprecated = configuration_->property("GNSS-SDR.internal_fs_hz", 4000000);
|
||||
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
dump_filename_ = configuration_->property(role + ".dump_filename", default_dump_filename);
|
||||
dump_filename_ = configuration_->property(role + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
if (FLAGS_doppler_max != 0)
|
||||
|
||||
@@ -63,10 +63,10 @@ GalileoE1PcpsTongAmbiguousAcquisition::GalileoE1PcpsTongAmbiguousAcquisition(
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
item_type_ = configuration_->property(role_ + ".item_type", default_item_type);
|
||||
item_type_ = configuration_->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int64_t fs_in_deprecated = configuration_->property("GNSS-SDR.internal_fs_hz", 4000000);
|
||||
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
dump_filename_ = configuration_->property(role_ + ".dump_filename", default_dump_filename);
|
||||
dump_filename_ = configuration_->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
if (sampled_ms_ % 4 != 0)
|
||||
{
|
||||
|
||||
@@ -67,8 +67,8 @@ GalileoE5aNoncoherentIQAcquisitionCaf::GalileoE5aNoncoherentIQAcquisitionCaf(
|
||||
{
|
||||
const std::string default_item_type("gr_complex");
|
||||
const std::string default_dump_filename("./acquisition.dat");
|
||||
item_type_ = configuration_->property(role_ + ".item_type", default_item_type);
|
||||
dump_filename_ = configuration_->property(role_ + ".dump_filename", default_dump_filename);
|
||||
item_type_ = configuration_->property(role_ + ".item_type", std::move(default_item_type));
|
||||
dump_filename_ = configuration_->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
int64_t fs_in_deprecated = configuration_->property("GNSS-SDR.internal_fs_hz", 32000000);
|
||||
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
|
||||
|
||||
@@ -53,7 +53,7 @@ GpsL1CaPcpsAcquisitionFineDoppler::GpsL1CaPcpsAcquisitionFineDoppler(
|
||||
std::string default_dump_filename = "./acquisition.mat";
|
||||
Acq_Conf acq_parameters = Acq_Conf();
|
||||
|
||||
item_type_ = configuration->property(role_ + ".item_type", default_item_type);
|
||||
item_type_ = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int64_t fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
fs_in_ = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
acq_parameters.fs_in = fs_in_;
|
||||
|
||||
@@ -51,7 +51,7 @@ GpsL1CaPcpsAssistedAcquisition::GpsL1CaPcpsAssistedAcquisition(
|
||||
const std::string default_item_type("gr_complex");
|
||||
std::string default_dump_filename = "./data/acquisition.dat";
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
item_type_ = configuration->property(role_ + ".item_type", default_item_type);
|
||||
item_type_ = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int64_t fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
fs_in_ = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
|
||||
|
||||
@@ -59,7 +59,7 @@ GpsL1CaPcpsQuickSyncAcquisition::GpsL1CaPcpsQuickSyncAcquisition(
|
||||
{
|
||||
const std::string default_item_type("gr_complex");
|
||||
std::string default_dump_filename = "./data/acquisition.dat";
|
||||
item_type_ = configuration_->property(role_ + ".item_type", default_item_type);
|
||||
item_type_ = configuration_->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int64_t fs_in_deprecated = configuration_->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
|
||||
|
||||
@@ -63,7 +63,7 @@ GpsL1CaPcpsTongAcquisition::GpsL1CaPcpsTongAcquisition(
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
item_type_ = configuration_->property(role_ + ".item_type", default_item_type);
|
||||
item_type_ = configuration_->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int64_t fs_in_deprecated = configuration_->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
fs_in_ = configuration_->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
dump_filename_ = configuration_->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
@@ -145,7 +145,7 @@ pcps_acquisition::pcps_acquisition(const Acq_Conf& conf_)
|
||||
{
|
||||
const std::string dump_filename_ = d_dump_filename.substr(d_dump_filename.find_last_of('/') + 1);
|
||||
dump_path = d_dump_filename.substr(0, d_dump_filename.find_last_of('/'));
|
||||
d_dump_filename = dump_filename_;
|
||||
d_dump_filename = std::move(dump_filename_);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -39,8 +39,8 @@ ByteToShort::ByteToShort(const ConfigurationInterface* configuration,
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", default_input_item_type);
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", std::move(default_input_item_type));
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
gr_char_to_short_ = gr::blocks::char_to_short::make();
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ CshortToGrComplex::CshortToGrComplex(const ConfigurationInterface* configuration
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
cshort_to_gr_complex_ = make_cshort_to_gr_complex();
|
||||
|
||||
DLOG(INFO) << "data_type_adapter_(" << cshort_to_gr_complex_->unique_id() << ")";
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include "ibyte_to_cbyte.h"
|
||||
#include "configuration_interface.h"
|
||||
#include <volk/volk.h>
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -41,8 +42,8 @@ IbyteToCbyte::IbyteToCbyte(const ConfigurationInterface* configuration,
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", default_input_item_type);
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", std::move(default_input_item_type));
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
ibyte_to_cbyte_ = make_interleaved_byte_to_complex_byte();
|
||||
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
#include "ibyte_to_complex.h"
|
||||
#include "configuration_interface.h"
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -38,8 +39,8 @@ IbyteToComplex::IbyteToComplex(const ConfigurationInterface* configuration, cons
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", default_input_item_type);
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", std::move(default_input_item_type));
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
gr_interleaved_char_to_complex_ = gr::blocks::interleaved_char_to_complex::make();
|
||||
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include "ibyte_to_cshort.h"
|
||||
#include "configuration_interface.h"
|
||||
#include <volk/volk.h>
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -40,8 +41,8 @@ IbyteToCshort::IbyteToCshort(const ConfigurationInterface* configuration,
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", default_input_item_type);
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", std::move(default_input_item_type));
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
interleaved_byte_to_complex_short_ = make_interleaved_byte_to_complex_short();
|
||||
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
|
||||
#include "ishort_to_complex.h"
|
||||
#include "configuration_interface.h"
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -38,8 +39,8 @@ IshortToComplex::IshortToComplex(const ConfigurationInterface* configuration,
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", default_input_item_type);
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", std::move(default_input_item_type));
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
gr_interleaved_short_to_complex_ = gr::blocks::interleaved_short_to_complex::make();
|
||||
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include "ishort_to_cshort.h"
|
||||
#include "configuration_interface.h"
|
||||
#include <volk/volk.h>
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -40,8 +41,8 @@ IshortToCshort::IshortToCshort(const ConfigurationInterface* configuration,
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", default_input_item_type);
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", std::move(default_input_item_type));
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
interleaved_short_to_complex_short_ = make_interleaved_short_to_complex_short();
|
||||
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include "beamformer.h"
|
||||
#include "configuration_interface.h"
|
||||
#include <gnuradio/blocks/file_sink.h>
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -35,8 +36,8 @@ BeamformerFilter::BeamformerFilter(
|
||||
{
|
||||
const std::string default_item_type("gr_complex");
|
||||
const std::string default_dump_file("./input_filter.dat");
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_file);
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_file));
|
||||
DLOG(INFO) << "role " << role_;
|
||||
if (item_type_ == "gr_complex")
|
||||
{
|
||||
|
||||
@@ -153,14 +153,14 @@ void FirFilter::init()
|
||||
|
||||
const int number_of_taps = config_->property(role_ + ".number_of_taps", default_number_of_taps);
|
||||
const unsigned int number_of_bands = config_->property(role_ + ".number_of_bands", default_number_of_bands);
|
||||
const std::string filter_type = config_->property(role_ + ".filter_type", default_filter_type);
|
||||
const std::string filter_type = config_->property(role_ + ".filter_type", std::move(default_filter_type));
|
||||
const int grid_density = config_->property(role_ + ".grid_density", default_grid_density);
|
||||
|
||||
input_item_type_ = config_->property(role_ + ".input_item_type", default_input_item_type);
|
||||
output_item_type_ = config_->property(role_ + ".output_item_type", default_output_item_type);
|
||||
taps_item_type_ = config_->property(role_ + ".taps_item_type", default_taps_item_type);
|
||||
input_item_type_ = config_->property(role_ + ".input_item_type", std::move(default_input_item_type));
|
||||
output_item_type_ = config_->property(role_ + ".output_item_type", std::move(default_output_item_type));
|
||||
taps_item_type_ = config_->property(role_ + ".taps_item_type", std::move(default_taps_item_type));
|
||||
dump_ = config_->property(role_ + ".dump", false);
|
||||
dump_filename_ = config_->property(role_ + ".dump_filename", default_dump_filename);
|
||||
dump_filename_ = config_->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
std::vector<double> bands;
|
||||
std::vector<double> ampl;
|
||||
@@ -194,7 +194,7 @@ void FirFilter::init()
|
||||
// It calculates the optimal (in the Chebyshev/minimax sense) FIR filter
|
||||
// impulse response given a set of band edges, the desired response on
|
||||
// those bands, and the weight given to the error in those bands.
|
||||
const std::vector<double> taps_d = gr::filter::pm_remez(number_of_taps - 1, bands, ampl, error_w, filter_type, grid_density);
|
||||
const std::vector<double> taps_d = gr::filter::pm_remez(number_of_taps - 1, bands, ampl, error_w, std::move(filter_type), grid_density);
|
||||
taps_ = std::vector<float>(taps_d.begin(), taps_d.end());
|
||||
}
|
||||
|
||||
|
||||
@@ -55,12 +55,12 @@ FreqXlatingFirFilter::FreqXlatingFirFilter(const ConfigurationInterface* configu
|
||||
|
||||
const int number_of_taps = configuration->property(role_ + ".number_of_taps", default_number_of_taps);
|
||||
const unsigned int number_of_bands = configuration->property(role_ + ".number_of_bands", default_number_of_bands);
|
||||
const std::string filter_type = configuration->property(role_ + ".filter_type", default_filter_type);
|
||||
const std::string filter_type = configuration->property(role_ + ".filter_type", std::move(default_filter_type));
|
||||
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", default_input_item_type);
|
||||
output_item_type_ = configuration->property(role_ + ".output_item_type", default_output_item_type);
|
||||
taps_item_type_ = configuration->property(role_ + ".taps_item_type", default_taps_item_type);
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
input_item_type_ = configuration->property(role_ + ".input_item_type", std::move(default_input_item_type));
|
||||
output_item_type_ = configuration->property(role_ + ".output_item_type", std::move(default_output_item_type));
|
||||
taps_item_type_ = configuration->property(role_ + ".taps_item_type", std::move(default_taps_item_type));
|
||||
intermediate_freq_ = configuration->property(role_ + ".IF", default_intermediate_freq);
|
||||
sampling_freq_ = configuration->property(role_ + ".sampling_frequency", default_sampling_freq);
|
||||
decimation_factor_ = configuration->property(role_ + ".decimation_factor", default_decimation_factor);
|
||||
@@ -97,7 +97,7 @@ FreqXlatingFirFilter::FreqXlatingFirFilter(const ConfigurationInterface* configu
|
||||
}
|
||||
|
||||
const int grid_density = configuration->property(role_ + ".grid_density", default_grid_density);
|
||||
const std::vector<double> taps_d = gr::filter::pm_remez(number_of_taps - 1, bands, ampl, error_w, filter_type, grid_density);
|
||||
const std::vector<double> taps_d = gr::filter::pm_remez(number_of_taps - 1, bands, ampl, error_w, std::move(filter_type), grid_density);
|
||||
taps_ = std::vector<float>(taps_d.begin(), taps_d.end());
|
||||
}
|
||||
else
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
#include "configuration_interface.h"
|
||||
#include "notch_cc.h"
|
||||
#include <boost/lexical_cast.hpp>
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -49,8 +50,8 @@ NotchFilter::NotchFilter(const ConfigurationInterface* configuration,
|
||||
const int n_segments_est = configuration->property(role + ".segments_est", default_n_segments_est);
|
||||
const int n_segments_reset = configuration->property(role + ".segments_reset", default_n_segments_reset);
|
||||
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_file);
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_file));
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
if (item_type_ == "gr_complex")
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
#include "notch_lite_cc.h"
|
||||
#include <boost/lexical_cast.hpp>
|
||||
#include <algorithm> // for max
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -53,8 +54,8 @@ NotchFilterLite::NotchFilterLite(const ConfigurationInterface* configuration,
|
||||
const int n_segments_est = configuration->property(role + ".segments_est", default_n_segments_est);
|
||||
const int n_segments_reset = configuration->property(role + ".segments_reset", default_n_segments_reset);
|
||||
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_file);
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_file));
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
|
||||
int n_segments_coeff = static_cast<int>((samp_freq / coeff_rate) / static_cast<float>(length_));
|
||||
n_segments_coeff = std::max(1, n_segments_coeff);
|
||||
|
||||
@@ -52,8 +52,8 @@ PulseBlankingFilter::PulseBlankingFilter(const ConfigurationInterface* configura
|
||||
const double if_aux = configuration->property(role_ + ".if", default_if);
|
||||
const double if_ = configuration->property(role_ + ".IF", if_aux);
|
||||
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
item_type_ = configuration->property(role_ + ".item_type", default_item_type);
|
||||
dump_filename_ = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
item_type_ = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
dump_ = configuration->property(role_ + ".dump", false);
|
||||
|
||||
DLOG(INFO) << "role " << role_;
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
#include <volk/volk_complex.h>
|
||||
#include <cstdint> // for int8_t
|
||||
#include <ostream> // for operator<<
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -39,7 +40,7 @@ Pass_Through::Pass_Through(const ConfigurationInterface* configuration,
|
||||
inverted_spectrum(configuration->property(role + ".inverted_spectrum", false))
|
||||
{
|
||||
const std::string default_item_type("gr_complex");
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
|
||||
if (item_type_ == "float")
|
||||
{
|
||||
|
||||
@@ -236,7 +236,7 @@ void read_results(std::vector<volk_gnsssdr_test_results_t> *results, std::string
|
||||
kernel_result.config_name = std::string(single_kernel_result[0]);
|
||||
kernel_result.best_arch_u = std::string(single_kernel_result[1]);
|
||||
kernel_result.best_arch_a = std::string(single_kernel_result[2]);
|
||||
results->push_back(kernel_result);
|
||||
results->push_back(std::move(kernel_result));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -237,7 +237,7 @@ std::vector<std::string> split_signature(const std::string &protokernel_signatur
|
||||
}
|
||||
}
|
||||
// Get the last one to the end of the string
|
||||
signature_tokens.push_back(token);
|
||||
signature_tokens.push_back(std::move(token));
|
||||
return signature_tokens;
|
||||
}
|
||||
|
||||
@@ -262,7 +262,7 @@ static void get_signatures_from_name(std::vector<volk_gnsssdr_type_t> &inputsig,
|
||||
std::string token = toked[token_index];
|
||||
try
|
||||
{
|
||||
type = volk_gnsssdr_type_from_string(token);
|
||||
type = volk_gnsssdr_type_from_string(std::move(token));
|
||||
if (side == SIDE_NAME) side = SIDE_OUTPUT; // if this is the first one after the name...
|
||||
|
||||
if (side == SIDE_INPUT)
|
||||
@@ -627,7 +627,7 @@ bool run_volk_gnsssdr_tests(volk_gnsssdr_func_desc_t desc,
|
||||
memcpy(arch_inbuff, inbuffs[j], vlen * inputsig[j].size * (inputsig[j].is_complex ? 2 : 1));
|
||||
arch_buffs.push_back(arch_inbuff);
|
||||
}
|
||||
test_data.push_back(arch_buffs);
|
||||
test_data.push_back(std::move(arch_buffs));
|
||||
}
|
||||
|
||||
std::vector<volk_gnsssdr_type_t> both_sigs;
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
#include "gnss_sdr_flags.h"
|
||||
#include "obs_conf.h"
|
||||
#include <ostream> // for operator<<
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -37,7 +38,7 @@ HybridObservables::HybridObservables(const ConfigurationInterface* configuration
|
||||
dump_mat_(configuration->property(role + ".dump_mat", true))
|
||||
{
|
||||
const std::string default_dump_filename("./observables.dat");
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_filename);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
Obs_Conf conf{};
|
||||
conf.dump = dump_;
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
#include <cmath>
|
||||
#include <cstdint>
|
||||
#include <limits>
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -46,8 +47,8 @@ DirectResamplerConditioner::DirectResamplerConditioner(
|
||||
const std::string default_dump_file("./resampler.dat");
|
||||
const double fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000.0);
|
||||
const double fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_file);
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_file));
|
||||
sample_freq_in_ = configuration->property(role_ + ".sample_freq_in", 4000000.0);
|
||||
sample_freq_out_ = configuration->property(role_ + ".sample_freq_out", fs_in);
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
#include <gnuradio/blocks/file_sink.h>
|
||||
#include <cmath>
|
||||
#include <limits>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
@@ -42,8 +43,8 @@ MmseResamplerConditioner::MmseResamplerConditioner(
|
||||
const std::string default_dump_file("./resampler.dat");
|
||||
const double fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000.0);
|
||||
const double fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_file);
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_file));
|
||||
sample_freq_in_ = configuration->property(role_ + ".sample_freq_in", 4000000.0);
|
||||
sample_freq_out_ = configuration->property(role_ + ".sample_freq_out", fs_in);
|
||||
|
||||
|
||||
@@ -47,8 +47,8 @@ SignalGenerator::SignalGenerator(const ConfigurationInterface* configuration,
|
||||
const std::string default_system("G");
|
||||
const std::string default_signal("1C");
|
||||
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_file);
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_file));
|
||||
|
||||
const unsigned int fs_in = configuration->property("SignalSource.fs_hz", static_cast<unsigned>(4e6));
|
||||
const bool data_flag = configuration->property("SignalSource.data_flag", false);
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
#include "configuration_interface.h"
|
||||
#include "gnss_sdr_string_literals.h"
|
||||
#include <iostream>
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -45,20 +46,20 @@ CustomUDPSignalSource::CustomUDPSignalSource(const ConfigurationInterface* confi
|
||||
// DUMP PARAMETERS
|
||||
const std::string default_dump_file("./data/signal_source.dat");
|
||||
const std::string default_item_type("gr_complex");
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_file);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_file));
|
||||
|
||||
// network PARAMETERS
|
||||
const std::string default_capture_device("eth0");
|
||||
const std::string default_address("127.0.0.1");
|
||||
const int default_port = 1234;
|
||||
const std::string address = configuration->property(role + ".origin_address", default_address);
|
||||
std::string capture_device = configuration->property(role + ".capture_device", default_capture_device);
|
||||
const std::string address = configuration->property(role + ".origin_address", std::move(default_address));
|
||||
std::string capture_device = configuration->property(role + ".capture_device", std::move(default_capture_device));
|
||||
int port = configuration->property(role + ".port", default_port);
|
||||
int payload_bytes = configuration->property(role + ".payload_bytes", 1024);
|
||||
|
||||
const std::string default_sample_type("cbyte");
|
||||
const std::string sample_type = configuration->property(role + ".sample_type", default_sample_type);
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
const std::string sample_type = configuration->property(role + ".sample_type", std::move(default_sample_type));
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
|
||||
udp_gnss_rx_source_ = Gr_Complex_Ip_Packet_Source::make(capture_device,
|
||||
address,
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
#include "labsat23_source.h"
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -43,12 +44,12 @@ LabsatSignalSource::LabsatSignalSource(const ConfigurationInterface* configurati
|
||||
const std::string default_item_type("gr_complex");
|
||||
const std::string default_dump_file("./labsat_output.dat");
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_file);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_file));
|
||||
|
||||
const int64_t sampling_frequency_deprecated = configuration->property(role + ".sampling_frequency", static_cast<int64_t>(16368000));
|
||||
const int64_t throttle_frequency_sps = configuration->property(role + ".throttle_frequency_sps", static_cast<int64_t>(sampling_frequency_deprecated));
|
||||
|
||||
std::string channels_to_read = configuration->property(role + ".selected_channel", default_item_type);
|
||||
std::string channels_to_read = configuration->property(role + ".selected_channel", std::move(default_item_type));
|
||||
std::stringstream ss(channels_to_read);
|
||||
int found;
|
||||
while (ss.good())
|
||||
@@ -69,7 +70,7 @@ LabsatSignalSource::LabsatSignalSource(const ConfigurationInterface* configurati
|
||||
}
|
||||
|
||||
const std::string default_filename("./example_capture.LS3");
|
||||
filename_ = configuration->property(role + ".filename", default_filename);
|
||||
filename_ = configuration->property(role + ".filename", std::move(default_filename));
|
||||
|
||||
const bool digital_io_enabled = configuration->property(role + ".digital_io_enabled", false);
|
||||
|
||||
|
||||
@@ -54,7 +54,7 @@ MultichannelFileSignalSource::MultichannelFileSignalSource(const ConfigurationIn
|
||||
filename_vec_.push_back(configuration->property(role + ".filename" + std::to_string(n), default_filename));
|
||||
}
|
||||
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
repeat_ = configuration->property(role + ".repeat", false);
|
||||
enable_throttle_control_ = configuration->property(role + ".enable_throttle_control", false);
|
||||
|
||||
|
||||
@@ -55,13 +55,13 @@ RtlTcpSignalSource::RtlTcpSignalSource(const ConfigurationInterface* configurati
|
||||
// DUMP PARAMETERS
|
||||
const std::string default_dump_file("./data/signal_source.dat");
|
||||
const std::string default_item_type("gr_complex");
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_file);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_file));
|
||||
|
||||
// rtl_tcp PARAMETERS
|
||||
const std::string default_address("127.0.0.1");
|
||||
const int16_t default_port = 1234;
|
||||
item_type_ = configuration->property(role + ".item_type", default_item_type);
|
||||
address_ = configuration->property(role + ".address", default_address);
|
||||
item_type_ = configuration->property(role + ".item_type", std::move(default_item_type));
|
||||
address_ = configuration->property(role + ".address", std::move(default_address));
|
||||
port_ = configuration->property(role + ".port", default_port);
|
||||
|
||||
if (item_type_ == "short")
|
||||
|
||||
@@ -56,8 +56,8 @@ SpirGSS6450FileSignalSource::SpirGSS6450FileSignalSource(const ConfigurationInte
|
||||
{
|
||||
const std::string default_filename("./my_capture.dat");
|
||||
const std::string default_dump_filename("./my_capture_dump.dat");
|
||||
filename_ = configuration->property(role + ".filename", default_filename);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_filename);
|
||||
filename_ = configuration->property(role + ".filename", std::move(default_filename));
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_filename));
|
||||
|
||||
const int64_t bytes_seek = configuration->property(role + ".bytes_to_skip", static_cast<int64_t>(65536));
|
||||
const double sample_size_byte = static_cast<double>(adc_bits_) / 4.0;
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
|
||||
#include "sbas_l1_telemetry_decoder.h"
|
||||
#include "configuration_interface.h"
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -35,7 +36,7 @@ SbasL1TelemetryDecoder::SbasL1TelemetryDecoder(
|
||||
dump_(configuration->property(role + ".dump", false))
|
||||
{
|
||||
const std::string default_dump_filename("./navigation.dat");
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_filename);
|
||||
dump_filename_ = configuration->property(role + ".dump_filename", std::move(default_dump_filename));
|
||||
// make telemetry decoder object
|
||||
telemetry_decoder_ = sbas_l1_make_telemetry_decoder_gs(satellite_, dump_); // TODO fix me
|
||||
DLOG(INFO) << "role " << role;
|
||||
|
||||
@@ -16,19 +16,20 @@
|
||||
*/
|
||||
|
||||
#include "tlm_conf.h"
|
||||
#include <utility>
|
||||
|
||||
|
||||
void Tlm_Conf::SetFromConfiguration(const ConfigurationInterface *configuration,
|
||||
const std::string &role)
|
||||
{
|
||||
const std::string default_dumpname("telemetry");
|
||||
dump_filename = configuration->property(role + ".dump_filename", default_dumpname);
|
||||
dump_filename = configuration->property(role + ".dump_filename", std::move(default_dumpname));
|
||||
dump = configuration->property(role + ".dump", false);
|
||||
dump_mat = configuration->property(role + ".dump_mat", dump);
|
||||
remove_dat = configuration->property(role + ".remove_dat", false);
|
||||
dump_crc_stats = configuration->property(role + ".dump_crc_stats", false);
|
||||
const std::string default_crc_stats_dumpname("telemetry_crc_stats");
|
||||
dump_crc_stats_filename = configuration->property(role + ".dump_crc_stats_filename", default_crc_stats_dumpname);
|
||||
dump_crc_stats_filename = configuration->property(role + ".dump_crc_stats_filename", std::move(default_crc_stats_dumpname));
|
||||
enable_navdata_monitor = configuration->property("NavDataMonitor.enable_monitor", false);
|
||||
if (configuration->property("Channels_1B.count", 0) > 0)
|
||||
{
|
||||
|
||||
@@ -46,7 +46,7 @@ GalileoE1TcpConnectorTracking::GalileoE1TcpConnectorTracking(
|
||||
{
|
||||
// ################# CONFIGURATION PARAMETERS ########################
|
||||
const std::string default_item_type("gr_complex");
|
||||
std::string item_type = configuration->property(role_ + ".item_type", default_item_type);
|
||||
std::string item_type = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
int fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
bool dump = configuration->property(role_ + ".dump", false);
|
||||
@@ -79,7 +79,7 @@ GalileoE1TcpConnectorTracking::GalileoE1TcpConnectorTracking(
|
||||
float very_early_late_space_chips = configuration->property(role_ + ".very_early_late_space_chips", static_cast<float>(0.5));
|
||||
size_t port_ch0 = configuration->property(role_ + ".port_ch0", 2060);
|
||||
const std::string default_dump_filename("./track_ch");
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
const auto vector_length = static_cast<int>(std::round(fs_in / (GALILEO_E1_CODE_CHIP_RATE_CPS / GALILEO_E1_B_CODE_LENGTH_CHIPS)));
|
||||
|
||||
// ################# MAKE TRACKING GNURadio object ###################
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#include "GLONASS_L1_L2_CA.h"
|
||||
#include "configuration_interface.h"
|
||||
#include "gnss_sdr_flags.h"
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -48,7 +49,7 @@ GlonassL1CaDllPllCAidTracking::GlonassL1CaDllPllCAidTracking(
|
||||
{
|
||||
// ################# CONFIGURATION PARAMETERS ########################
|
||||
const std::string default_item_type("gr_complex");
|
||||
item_type_ = configuration->property(role_ + ".item_type", default_item_type);
|
||||
item_type_ = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
int fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
bool dump = configuration->property(role_ + ".dump", false);
|
||||
@@ -83,7 +84,7 @@ GlonassL1CaDllPllCAidTracking::GlonassL1CaDllPllCAidTracking(
|
||||
|
||||
float early_late_space_chips = configuration->property(role_ + ".early_late_space_chips", static_cast<float>(0.5));
|
||||
const std::string default_dump_filename("./track_ch");
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
const auto vector_length = static_cast<int>(std::round(fs_in / (GLONASS_L1_CA_CODE_RATE_CPS / GLONASS_L1_CA_CODE_LENGTH_CHIPS)));
|
||||
|
||||
// ################# MAKE TRACKING GNURadio object ###################
|
||||
|
||||
@@ -26,6 +26,7 @@
|
||||
#include "GLONASS_L1_L2_CA.h"
|
||||
#include "configuration_interface.h"
|
||||
#include "gnss_sdr_flags.h"
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -47,7 +48,7 @@ GlonassL1CaDllPllTracking::GlonassL1CaDllPllTracking(
|
||||
{
|
||||
// ################# CONFIGURATION PARAMETERS ########################
|
||||
const std::string default_item_type("gr_complex");
|
||||
std::string item_type = configuration->property(role_ + ".item_type", default_item_type);
|
||||
std::string item_type = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
int fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
bool dump = configuration->property(role_ + ".dump", false);
|
||||
@@ -78,7 +79,7 @@ GlonassL1CaDllPllTracking::GlonassL1CaDllPllTracking(
|
||||
#endif
|
||||
float early_late_space_chips = configuration->property(role_ + ".early_late_space_chips", static_cast<float>(0.5));
|
||||
const std::string default_dump_filename("./track_ch");
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
const auto vector_length = static_cast<int>(std::round(fs_in / (GLONASS_L1_CA_CODE_RATE_CPS / GLONASS_L1_CA_CODE_LENGTH_CHIPS)));
|
||||
|
||||
// ################# MAKE TRACKING GNURadio object ###################
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
#include "GLONASS_L1_L2_CA.h"
|
||||
#include "configuration_interface.h"
|
||||
#include "gnss_sdr_flags.h"
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -46,7 +47,7 @@ GlonassL2CaDllPllCAidTracking::GlonassL2CaDllPllCAidTracking(
|
||||
{
|
||||
// ################# CONFIGURATION PARAMETERS ########################
|
||||
const std::string default_item_type("gr_complex");
|
||||
item_type_ = configuration->property(role_ + ".item_type", default_item_type);
|
||||
item_type_ = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
int fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
bool dump = configuration->property(role_ + ".dump", false);
|
||||
@@ -81,7 +82,7 @@ GlonassL2CaDllPllCAidTracking::GlonassL2CaDllPllCAidTracking(
|
||||
|
||||
float early_late_space_chips = configuration->property(role_ + ".early_late_space_chips", static_cast<float>(0.5));
|
||||
const std::string default_dump_filename("./track_ch");
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
const auto vector_length = static_cast<int>(std::round(fs_in / (GLONASS_L2_CA_CODE_RATE_CPS / GLONASS_L2_CA_CODE_LENGTH_CHIPS)));
|
||||
|
||||
// ################# MAKE TRACKING GNURadio object ###################
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
#include "GLONASS_L1_L2_CA.h"
|
||||
#include "configuration_interface.h"
|
||||
#include "gnss_sdr_flags.h"
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -45,7 +46,7 @@ GlonassL2CaDllPllTracking::GlonassL2CaDllPllTracking(
|
||||
{
|
||||
// ################# CONFIGURATION PARAMETERS ########################
|
||||
const std::string default_item_type("gr_complex");
|
||||
std::string item_type = configuration->property(role_ + ".item_type", default_item_type);
|
||||
std::string item_type = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
int fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
bool dump = configuration->property(role_ + ".dump", false);
|
||||
@@ -75,7 +76,7 @@ GlonassL2CaDllPllTracking::GlonassL2CaDllPllTracking(
|
||||
#endif
|
||||
float early_late_space_chips = configuration->property(role_ + ".early_late_space_chips", static_cast<float>(0.5));
|
||||
const std::string default_dump_filename("./track_ch");
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
const auto vector_length = static_cast<int>(std::round(fs_in / (GLONASS_L2_CA_CODE_RATE_CPS / GLONASS_L2_CA_CODE_LENGTH_CHIPS)));
|
||||
|
||||
// ################# MAKE TRACKING GNURadio object ###################
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include "GPS_L1_CA.h"
|
||||
#include "configuration_interface.h"
|
||||
#include "gnss_sdr_flags.h"
|
||||
#include <utility>
|
||||
|
||||
#if USE_GLOG_AND_GFLAGS
|
||||
#include <glog/logging.h>
|
||||
@@ -49,7 +50,7 @@ GpsL1CaGaussianTracking::GpsL1CaGaussianTracking(
|
||||
{
|
||||
// ################# CONFIGURATION PARAMETERS ########################
|
||||
const std::string default_item_type("gr_complex");
|
||||
std::string item_type = configuration->property(role_ + ".item_type", default_item_type);
|
||||
std::string item_type = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int order = configuration->property(role_ + ".order", 2);
|
||||
int fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
int fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
@@ -68,7 +69,7 @@ GpsL1CaGaussianTracking::GpsL1CaGaussianTracking(
|
||||
#endif
|
||||
float early_late_space_chips = configuration->property(role_ + ".early_late_space_chips", static_cast<float>(0.5));
|
||||
const std::string default_dump_filename("./track_ch");
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
const auto vector_length = static_cast<int>(std::round(fs_in / (GPS_L1_CA_CODE_RATE_CPS / GPS_L1_CA_CODE_LENGTH_CHIPS)));
|
||||
|
||||
bool bce_run = configuration->property(role_ + ".bce_run", false);
|
||||
|
||||
@@ -46,14 +46,14 @@ GpsL1CaTcpConnectorTracking::GpsL1CaTcpConnectorTracking(
|
||||
{
|
||||
// ################# CONFIGURATION PARAMETERS ########################
|
||||
const std::string default_item_type("gr_complex");
|
||||
std::string item_type = configuration->property(role_ + ".item_type", default_item_type);
|
||||
std::string item_type = configuration->property(role_ + ".item_type", std::move(default_item_type));
|
||||
int fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 2048000);
|
||||
int fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
|
||||
bool dump = configuration->property(role_ + ".dump", false);
|
||||
float early_late_space_chips = configuration->property(role_ + ".early_late_space_chips", static_cast<float>(0.5));
|
||||
size_t port_ch0 = configuration->property(role_ + ".port_ch0", 2060);
|
||||
const std::string default_dump_filename("./track_ch");
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", default_dump_filename);
|
||||
std::string dump_filename = configuration->property(role_ + ".dump_filename", std::move(default_dump_filename));
|
||||
const auto vector_length = static_cast<int>(std::round(fs_in / (GPS_L1_CA_CODE_RATE_CPS / GPS_L1_CA_CODE_LENGTH_CHIPS)));
|
||||
|
||||
// ################# MAKE TRACKING GNURadio object ###################
|
||||
|
||||
Reference in New Issue
Block a user