diff --git a/src/algorithms/PVT/libs/rinex_printer.cc b/src/algorithms/PVT/libs/rinex_printer.cc index 6df948d5b..ceb62548f 100644 --- a/src/algorithms/PVT/libs/rinex_printer.cc +++ b/src/algorithms/PVT/libs/rinex_printer.cc @@ -5602,29 +5602,9 @@ void Rinex_Printer::log_rinex_nav(std::fstream& out, const std::mapsecond.E1B_DVS); - if (E1B_DVS == "1") - { - LOG(WARNING) << "Navigation data without guarantee"; - } - E1B_DVS = "0"; // *************** CHANGE THIS WHEN GALILEO SIGNAL IS VALID std::string SVhealth_str = E5B_HS + std::to_string(galileo_ephemeris_iter->second.E5b_DVS) + "11" + "1" + std::string(E1B_DVS) + std::string(E1B_HS) + std::to_string(galileo_ephemeris_iter->second.E1B_DVS); - SVhealth_str = "000000000"; // *************** CHANGE THIS WHEN GALILEO SIGNAL IS VALID int32_t SVhealth = Rinex_Printer::toInt(SVhealth_str, 9); line += Rinex_Printer::doub2for(static_cast(SVhealth), 18, 2); line += std::string(1, ' '); diff --git a/src/algorithms/signal_source/adapters/fifo_signal_source.cc b/src/algorithms/signal_source/adapters/fifo_signal_source.cc index 47b4620d5..7ffac8e5b 100644 --- a/src/algorithms/signal_source/adapters/fifo_signal_source.cc +++ b/src/algorithms/signal_source/adapters/fifo_signal_source.cc @@ -31,10 +31,10 @@ FifoSignalSource::FifoSignalSource(ConfigurationInterface const* configuration, [[maybe_unused]] Concurrent_Queue* queue) : SignalSourceBase(configuration, role, "Fifo_Signal_Source"s), item_size_(sizeof(gr_complex)), // currenty output item size is always gr_complex - fifo_reader_(FifoReader::make(configuration->property(role + ".filename"s, "../data/example_capture.dat"s), - configuration->property(role + ".sample_type"s, "ishort"s))), + fifo_reader_(FifoReader::make(configuration->property(role + ".filename", "../data/example_capture.dat"s), + configuration->property(role + ".sample_type", "ishort"s))), dump_(configuration->property(role + ".dump", false)), - dump_filename_(configuration->property(role + ".dump_filename"s, "./data/signal_source.dat"s)) + dump_filename_(configuration->property(role + ".dump_filename", "./data/signal_source.dat"s)) { if (dump_) { diff --git a/src/algorithms/signal_source/adapters/zmq_signal_source.cc b/src/algorithms/signal_source/adapters/zmq_signal_source.cc index 00a6f57e5..5d51434ff 100644 --- a/src/algorithms/signal_source/adapters/zmq_signal_source.cc +++ b/src/algorithms/signal_source/adapters/zmq_signal_source.cc @@ -27,9 +27,9 @@ ZmqSignalSource::ZmqSignalSource(const ConfigurationInterface* configuration, unsigned int /* out_stream [[maybe_unused]] */, Concurrent_Queue* /* queue [[maybe_unused]] */) : SignalSourceBase(configuration, role, "ZMQ_Signal_Source"s), - d_item_size(decode_item_type(configuration->property(role + ".item_type"s, "gr_complex"s), nullptr, true)), - d_dump_filename(configuration->property(role + ".dump_filename"s, "data/zmq_dump.dat"s)), - d_dump(configuration->property(role + ".dump"s, false)) + d_item_size(decode_item_type(configuration->property(role + ".item_type", "gr_complex"s), nullptr, true)), + d_dump_filename(configuration->property(role + ".dump_filename", "data/zmq_dump.dat"s)), + d_dump(configuration->property(role + ".dump", false)) { auto vlen = configuration->property(role + ".vlen"s, 1); auto pass_tags = configuration->property(role + ".pass_tags"s, false); diff --git a/src/core/libs/galileo_e6_has_msg_receiver.cc b/src/core/libs/galileo_e6_has_msg_receiver.cc index 6b4c326d2..a18bc23cc 100644 --- a/src/core/libs/galileo_e6_has_msg_receiver.cc +++ b/src/core/libs/galileo_e6_has_msg_receiver.cc @@ -681,6 +681,8 @@ void galileo_e6_has_msg_receiver::read_MT1_body(const std::string& message_body) d_HAS_data.satellite_submask = std::vector(d_HAS_data.Nsys_sub); d_HAS_data.delta_clock_correction_clock_subset = std::vector>(d_HAS_data.Nsys_sub, std::vector()); + const std::string str_one("1"); + const std::string str_zero("0"); for (uint8_t i = 0; i < d_HAS_data.Nsys_sub; i++) { d_HAS_data.gnss_id_clock_subset[i] = read_has_message_body_uint8(message.substr(0, HAS_MSG_ID_CLOCK_SUBSET_LENGTH)); @@ -711,11 +713,11 @@ void galileo_e6_has_msg_receiver::read_MT1_body(const std::string& message_body) { if ((aux & mask_value) >= 1) { - binary.insert(0, "1"); + binary.insert(0, str_one); } else { - binary.insert(0, "0"); + binary.insert(0, str_zero); } aux <<= 1; } diff --git a/src/core/system_parameters/galileo_has_data.cc b/src/core/system_parameters/galileo_has_data.cc index f3bb628cd..447d9faef 100644 --- a/src/core/system_parameters/galileo_has_data.cc +++ b/src/core/system_parameters/galileo_has_data.cc @@ -76,16 +76,20 @@ std::vector Galileo_HAS_data::get_PRNs_in_submask(uint8_t nsys) const uint64_t sat_submask = satellite_submask[nsys]; // convert into string std::string sat_submask_str(""); + sat_submask_str.reserve(number_sats_this_gnss_id); uint64_t aux = 1; + const std::string one_str("1"); + const std::string zero_str("0"); + for (int k = 0; k < number_sats_this_gnss_id - 1; k++) { if ((aux & sat_submask) >= 1) { - sat_submask_str.insert(0, "1"); + sat_submask_str.insert(0, one_str); } else { - sat_submask_str.insert(0, "0"); + sat_submask_str.insert(0, zero_str); } aux <<= 1; } diff --git a/src/core/system_parameters/gnss_satellite.cc b/src/core/system_parameters/gnss_satellite.cc index b2390c90c..5c89ede73 100644 --- a/src/core/system_parameters/gnss_satellite.cc +++ b/src/core/system_parameters/gnss_satellite.cc @@ -30,9 +30,9 @@ Gnss_Satellite::Gnss_Satellite(const std::string& system_, uint32_t PRN_) void Gnss_Satellite::reset() { - PRN = 0; system = std::string(""); block = std::string(""); + PRN = 0; rf_link = 0; } @@ -43,11 +43,11 @@ std::ostream& operator<<(std::ostream& out, const Gnss_Satellite& sat) // outpu std::string tag2; if (sat.get_system() == "Galileo") { - tag = "E"; + tag = std::string("E"); } if (sat.get_PRN() < 10) { - tag2 = "0"; + tag2 = std::string("0"); } out << sat.get_system() << " PRN " << tag << tag2 << sat.get_PRN() << " (Block " << sat.get_block() << ")"; return out; @@ -85,8 +85,8 @@ Gnss_Satellite& Gnss_Satellite::operator=(const Gnss_Satellite& rhs) if (this != &rhs) { this->system = rhs.system; - this->PRN = rhs.PRN; this->block = rhs.block; + this->PRN = rhs.PRN; this->rf_link = rhs.rf_link; } return *this; @@ -106,8 +106,8 @@ Gnss_Satellite& Gnss_Satellite::operator=(Gnss_Satellite&& other) noexcept if (this != &other) { this->system = other.get_system(); - this->PRN = other.get_PRN(); this->block = other.get_block(); + this->PRN = other.get_PRN(); this->rf_link = other.get_rf_link(); } return *this;