mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2024-12-14 04:00:34 +00:00
Use const container calls when result is immediately converted to a const iterator
This commit is contained in:
parent
87baa04ef9
commit
e2f02a50f0
@ -1526,8 +1526,8 @@ void Rinex_Printer::log_rinex_nav(std::fstream& out, const std::map<int,Gps_Ephe
|
|||||||
std::string line;
|
std::string line;
|
||||||
std::map<int,Gps_Ephemeris>::const_iterator gps_ephemeris_iter;
|
std::map<int,Gps_Ephemeris>::const_iterator gps_ephemeris_iter;
|
||||||
|
|
||||||
for(gps_ephemeris_iter = eph_map.begin();
|
for(gps_ephemeris_iter = eph_map.cbegin();
|
||||||
gps_ephemeris_iter != eph_map.end();
|
gps_ephemeris_iter != eph_map.cend();
|
||||||
gps_ephemeris_iter++)
|
gps_ephemeris_iter++)
|
||||||
{
|
{
|
||||||
// -------- SV / EPOCH / SV CLK
|
// -------- SV / EPOCH / SV CLK
|
||||||
@ -1857,8 +1857,8 @@ void Rinex_Printer::log_rinex_nav(std::fstream& out, const std::map<int,Gps_CNAV
|
|||||||
std::string line;
|
std::string line;
|
||||||
std::map<int,Gps_CNAV_Ephemeris>::const_iterator gps_ephemeris_iter;
|
std::map<int,Gps_CNAV_Ephemeris>::const_iterator gps_ephemeris_iter;
|
||||||
|
|
||||||
for(gps_ephemeris_iter = eph_map.begin();
|
for(gps_ephemeris_iter = eph_map.cbegin();
|
||||||
gps_ephemeris_iter != eph_map.end();
|
gps_ephemeris_iter != eph_map.cend();
|
||||||
gps_ephemeris_iter++)
|
gps_ephemeris_iter++)
|
||||||
{
|
{
|
||||||
// -------- SV / EPOCH / SV CLK
|
// -------- SV / EPOCH / SV CLK
|
||||||
@ -2020,8 +2020,8 @@ void Rinex_Printer::log_rinex_nav(std::fstream& out, const std::map<int, Galileo
|
|||||||
std::string line;
|
std::string line;
|
||||||
std::map<int,Galileo_Ephemeris>::const_iterator galileo_ephemeris_iter;
|
std::map<int,Galileo_Ephemeris>::const_iterator galileo_ephemeris_iter;
|
||||||
line.clear();
|
line.clear();
|
||||||
for(galileo_ephemeris_iter = eph_map.begin();
|
for(galileo_ephemeris_iter = eph_map.cbegin();
|
||||||
galileo_ephemeris_iter != eph_map.end();
|
galileo_ephemeris_iter != eph_map.cend();
|
||||||
galileo_ephemeris_iter++)
|
galileo_ephemeris_iter++)
|
||||||
{
|
{
|
||||||
// -------- SV / EPOCH / SV CLK
|
// -------- SV / EPOCH / SV CLK
|
||||||
|
@ -136,8 +136,8 @@ int sbas_l1_telemetry_decoder_cc::general_work (int noutput_items __attribute__(
|
|||||||
// compute message sample stamp
|
// compute message sample stamp
|
||||||
// and fill messages in SBAS raw message objects
|
// and fill messages in SBAS raw message objects
|
||||||
//std::vector<Sbas_Raw_Msg> sbas_raw_msgs;
|
//std::vector<Sbas_Raw_Msg> sbas_raw_msgs;
|
||||||
for(std::vector<msg_candiate_char_t>::const_iterator it = valid_msgs.begin();
|
for(std::vector<msg_candiate_char_t>::const_iterator it = valid_msgs.cbegin();
|
||||||
it != valid_msgs.end(); ++it)
|
it != valid_msgs.cend(); ++it)
|
||||||
{
|
{
|
||||||
int message_sample_offset =
|
int message_sample_offset =
|
||||||
(sample_alignment ? 0 : -1)
|
(sample_alignment ? 0 : -1)
|
||||||
@ -314,7 +314,7 @@ bool sbas_l1_telemetry_decoder_cc::symbol_aligner_and_decoder::get_bits(const st
|
|||||||
std::vector<double> symbols_vd1(symbols); // aligned symbol vector -> copy input symbol vector
|
std::vector<double> symbols_vd1(symbols); // aligned symbol vector -> copy input symbol vector
|
||||||
std::vector<double> symbols_vd2; // shifted symbol vector -> add past sample in front of input vector
|
std::vector<double> symbols_vd2; // shifted symbol vector -> add past sample in front of input vector
|
||||||
symbols_vd2.push_back(d_past_symbol);
|
symbols_vd2.push_back(d_past_symbol);
|
||||||
for (std::vector<double>::const_iterator symbol_it = symbols.begin(); symbol_it != symbols.end() - 1; ++symbol_it)
|
for (std::vector<double>::const_iterator symbol_it = symbols.cbegin(); symbol_it != symbols.cend() - 1; ++symbol_it)
|
||||||
{
|
{
|
||||||
symbols_vd2.push_back(*symbol_it);
|
symbols_vd2.push_back(*symbol_it);
|
||||||
}
|
}
|
||||||
@ -361,7 +361,7 @@ void sbas_l1_telemetry_decoder_cc::frame_detector::get_frame_candidates(const st
|
|||||||
ss << "copy bits ";
|
ss << "copy bits ";
|
||||||
int count = 0;
|
int count = 0;
|
||||||
// copy new bits into the working buffer
|
// copy new bits into the working buffer
|
||||||
for (std::vector<int>::const_iterator bit_it = bits.begin(); bit_it < bits.end(); ++bit_it)
|
for (std::vector<int>::const_iterator bit_it = bits.cbegin(); bit_it < bits.cend(); ++bit_it)
|
||||||
{
|
{
|
||||||
d_buffer.push_back(*bit_it);
|
d_buffer.push_back(*bit_it);
|
||||||
ss << *bit_it;
|
ss << *bit_it;
|
||||||
@ -421,7 +421,7 @@ void sbas_l1_telemetry_decoder_cc::crc_verifier::get_valid_frames(const std::vec
|
|||||||
std::stringstream ss;
|
std::stringstream ss;
|
||||||
VLOG(FLOW) << "get_valid_frames(): " << "msg_candidates.size()=" << msg_candidates.size();
|
VLOG(FLOW) << "get_valid_frames(): " << "msg_candidates.size()=" << msg_candidates.size();
|
||||||
// for each candidate
|
// for each candidate
|
||||||
for (std::vector<msg_candiate_int_t>::const_iterator candidate_it = msg_candidates.begin(); candidate_it < msg_candidates.end(); ++candidate_it)
|
for (std::vector<msg_candiate_int_t>::const_iterator candidate_it = msg_candidates.cbegin(); candidate_it < msg_candidates.cend(); ++candidate_it)
|
||||||
{
|
{
|
||||||
// convert to bytes
|
// convert to bytes
|
||||||
std::vector<unsigned char> candidate_bytes;
|
std::vector<unsigned char> candidate_bytes;
|
||||||
@ -462,7 +462,7 @@ void sbas_l1_telemetry_decoder_cc::crc_verifier::zerropad_back_and_convert_to_by
|
|||||||
const size_t bits_per_byte = 8;
|
const size_t bits_per_byte = 8;
|
||||||
unsigned char byte = 0;
|
unsigned char byte = 0;
|
||||||
VLOG(LMORE) << "zerropad_back_and_convert_to_bytes():" << byte;
|
VLOG(LMORE) << "zerropad_back_and_convert_to_bytes():" << byte;
|
||||||
for (std::vector<int>::const_iterator candidate_bit_it = msg_candidate.begin(); candidate_bit_it < msg_candidate.end(); ++candidate_bit_it)
|
for (std::vector<int>::const_iterator candidate_bit_it = msg_candidate.cbegin(); candidate_bit_it < msg_candidate.cend(); ++candidate_bit_it)
|
||||||
{
|
{
|
||||||
int idx_bit = candidate_bit_it - msg_candidate.begin();
|
int idx_bit = candidate_bit_it - msg_candidate.begin();
|
||||||
int bit_pos_in_current_byte = (bits_per_byte - 1) - (idx_bit % bits_per_byte);
|
int bit_pos_in_current_byte = (bits_per_byte - 1) - (idx_bit % bits_per_byte);
|
||||||
@ -490,7 +490,7 @@ void sbas_l1_telemetry_decoder_cc::crc_verifier::zerropad_front_and_convert_to_b
|
|||||||
unsigned char byte = 0;
|
unsigned char byte = 0;
|
||||||
int idx_bit = 6; // insert 6 zeros at the front to fit the 250bits into a multiple of bytes
|
int idx_bit = 6; // insert 6 zeros at the front to fit the 250bits into a multiple of bytes
|
||||||
VLOG(LMORE) << "zerropad_front_and_convert_to_bytes():" << byte;
|
VLOG(LMORE) << "zerropad_front_and_convert_to_bytes():" << byte;
|
||||||
for (std::vector<int>::const_iterator candidate_bit_it = msg_candidate.begin(); candidate_bit_it < msg_candidate.end(); ++candidate_bit_it)
|
for (std::vector<int>::const_iterator candidate_bit_it = msg_candidate.cbegin(); candidate_bit_it < msg_candidate.cend(); ++candidate_bit_it)
|
||||||
{
|
{
|
||||||
int bit_pos_in_current_byte = (bits_per_byte - 1) - (idx_bit % bits_per_byte);
|
int bit_pos_in_current_byte = (bits_per_byte - 1) - (idx_bit % bits_per_byte);
|
||||||
byte |= (unsigned char)(*candidate_bit_it) << bit_pos_in_current_byte;
|
byte |= (unsigned char)(*candidate_bit_it) << bit_pos_in_current_byte;
|
||||||
|
@ -462,8 +462,8 @@ std::string Rtcm::print_MT1001(const Gps_Ephemeris & gps_eph, double obs_time, c
|
|||||||
std::map<int, Gnss_Synchro> observablesL1;
|
std::map<int, Gnss_Synchro> observablesL1;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
||||||
|
|
||||||
for(observables_iter = observables.begin();
|
for(observables_iter = observables.cbegin();
|
||||||
observables_iter != observables.end();
|
observables_iter != observables.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
std::string system_(&observables_iter->second.System, 1);
|
std::string system_(&observables_iter->second.System, 1);
|
||||||
@ -477,8 +477,8 @@ std::string Rtcm::print_MT1001(const Gps_Ephemeris & gps_eph, double obs_time, c
|
|||||||
std::bitset<64> header = Rtcm::get_MT1001_4_header(1001, obs_time, observablesL1, ref_id, smooth_int, sync_flag, divergence_free);
|
std::bitset<64> header = Rtcm::get_MT1001_4_header(1001, obs_time, observablesL1, ref_id, smooth_int, sync_flag, divergence_free);
|
||||||
std::string data = header.to_string();
|
std::string data = header.to_string();
|
||||||
|
|
||||||
for(observables_iter = observablesL1.begin();
|
for(observables_iter = observablesL1.cbegin();
|
||||||
observables_iter != observablesL1.end();
|
observables_iter != observablesL1.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
std::bitset<58> content = Rtcm::get_MT1001_sat_content(gps_eph, obs_time, observables_iter->second);
|
std::bitset<58> content = Rtcm::get_MT1001_sat_content(gps_eph, obs_time, observables_iter->second);
|
||||||
@ -512,8 +512,8 @@ std::string Rtcm::print_MT1002(const Gps_Ephemeris & gps_eph, double obs_time, c
|
|||||||
std::map<int, Gnss_Synchro> observablesL1;
|
std::map<int, Gnss_Synchro> observablesL1;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
||||||
|
|
||||||
for(observables_iter = observables.begin();
|
for(observables_iter = observables.cbegin();
|
||||||
observables_iter != observables.end();
|
observables_iter != observables.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
std::string system_(&observables_iter->second.System, 1);
|
std::string system_(&observables_iter->second.System, 1);
|
||||||
@ -527,8 +527,8 @@ std::string Rtcm::print_MT1002(const Gps_Ephemeris & gps_eph, double obs_time, c
|
|||||||
std::bitset<64> header = Rtcm::get_MT1001_4_header(1002, obs_time, observablesL1, ref_id, smooth_int, sync_flag, divergence_free);
|
std::bitset<64> header = Rtcm::get_MT1001_4_header(1002, obs_time, observablesL1, ref_id, smooth_int, sync_flag, divergence_free);
|
||||||
std::string data = header.to_string();
|
std::string data = header.to_string();
|
||||||
|
|
||||||
for(observables_iter = observablesL1.begin();
|
for(observables_iter = observablesL1.cbegin();
|
||||||
observables_iter != observablesL1.end();
|
observables_iter != observablesL1.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
std::bitset<74> content = Rtcm::get_MT1002_sat_content(gps_eph, obs_time, observables_iter->second);
|
std::bitset<74> content = Rtcm::get_MT1002_sat_content(gps_eph, obs_time, observables_iter->second);
|
||||||
@ -586,8 +586,8 @@ std::string Rtcm::print_MT1003(const Gps_Ephemeris & ephL1, const Gps_CNAV_Ephem
|
|||||||
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator observables_iter2;
|
std::map<int, Gnss_Synchro>::const_iterator observables_iter2;
|
||||||
|
|
||||||
for(observables_iter = observables.begin();
|
for(observables_iter = observables.cbegin();
|
||||||
observables_iter != observables.end();
|
observables_iter != observables.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
std::string system_(&observables_iter->second.System, 1);
|
std::string system_(&observables_iter->second.System, 1);
|
||||||
@ -607,13 +607,13 @@ std::string Rtcm::print_MT1003(const Gps_Ephemeris & ephL1, const Gps_CNAV_Ephem
|
|||||||
std::vector< std::pair< Gnss_Synchro, Gnss_Synchro > >::const_iterator common_observables_iter;
|
std::vector< std::pair< Gnss_Synchro, Gnss_Synchro > >::const_iterator common_observables_iter;
|
||||||
std::map<int, Gnss_Synchro> observablesL1_with_L2;
|
std::map<int, Gnss_Synchro> observablesL1_with_L2;
|
||||||
|
|
||||||
for(observables_iter = observablesL1.begin();
|
for(observables_iter = observablesL1.cbegin();
|
||||||
observables_iter != observablesL1.end();
|
observables_iter != observablesL1.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
unsigned int prn_ = observables_iter->second.PRN;
|
unsigned int prn_ = observables_iter->second.PRN;
|
||||||
for(observables_iter2 = observablesL2.begin();
|
for(observables_iter2 = observablesL2.cbegin();
|
||||||
observables_iter2 != observablesL2.end();
|
observables_iter2 != observablesL2.cend();
|
||||||
observables_iter2++)
|
observables_iter2++)
|
||||||
{
|
{
|
||||||
if(observables_iter2->second.PRN == prn_)
|
if(observables_iter2->second.PRN == prn_)
|
||||||
@ -631,8 +631,8 @@ std::string Rtcm::print_MT1003(const Gps_Ephemeris & ephL1, const Gps_CNAV_Ephem
|
|||||||
std::bitset<64> header = Rtcm::get_MT1001_4_header(1003, obs_time, observablesL1_with_L2, ref_id, smooth_int, sync_flag, divergence_free);
|
std::bitset<64> header = Rtcm::get_MT1001_4_header(1003, obs_time, observablesL1_with_L2, ref_id, smooth_int, sync_flag, divergence_free);
|
||||||
std::string data = header.to_string();
|
std::string data = header.to_string();
|
||||||
|
|
||||||
for(common_observables_iter = common_observables.begin();
|
for(common_observables_iter = common_observables.cbegin();
|
||||||
common_observables_iter != common_observables.end();
|
common_observables_iter != common_observables.cend();
|
||||||
common_observables_iter++)
|
common_observables_iter++)
|
||||||
{
|
{
|
||||||
std::bitset<101> content = Rtcm::get_MT1003_sat_content(ephL1, ephL2, obs_time, common_observables_iter->first, common_observables_iter->second);
|
std::bitset<101> content = Rtcm::get_MT1003_sat_content(ephL1, ephL2, obs_time, common_observables_iter->first, common_observables_iter->second);
|
||||||
@ -696,8 +696,8 @@ std::string Rtcm::print_MT1004(const Gps_Ephemeris & ephL1, const Gps_CNAV_Ephem
|
|||||||
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator observables_iter2;
|
std::map<int, Gnss_Synchro>::const_iterator observables_iter2;
|
||||||
|
|
||||||
for(observables_iter = observables.begin();
|
for(observables_iter = observables.cbegin();
|
||||||
observables_iter != observables.end();
|
observables_iter != observables.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
std::string system_(&observables_iter->second.System, 1);
|
std::string system_(&observables_iter->second.System, 1);
|
||||||
@ -717,13 +717,13 @@ std::string Rtcm::print_MT1004(const Gps_Ephemeris & ephL1, const Gps_CNAV_Ephem
|
|||||||
std::vector< std::pair< Gnss_Synchro, Gnss_Synchro > >::const_iterator common_observables_iter;
|
std::vector< std::pair< Gnss_Synchro, Gnss_Synchro > >::const_iterator common_observables_iter;
|
||||||
std::map<int, Gnss_Synchro> observablesL1_with_L2;
|
std::map<int, Gnss_Synchro> observablesL1_with_L2;
|
||||||
|
|
||||||
for(observables_iter = observablesL1.begin();
|
for(observables_iter = observablesL1.cbegin();
|
||||||
observables_iter != observablesL1.end();
|
observables_iter != observablesL1.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
unsigned int prn_ = observables_iter->second.PRN;
|
unsigned int prn_ = observables_iter->second.PRN;
|
||||||
for(observables_iter2 = observablesL2.begin();
|
for(observables_iter2 = observablesL2.cbegin();
|
||||||
observables_iter2 != observablesL2.end();
|
observables_iter2 != observablesL2.cend();
|
||||||
observables_iter2++)
|
observables_iter2++)
|
||||||
{
|
{
|
||||||
if(observables_iter2->second.PRN == prn_)
|
if(observables_iter2->second.PRN == prn_)
|
||||||
@ -741,8 +741,8 @@ std::string Rtcm::print_MT1004(const Gps_Ephemeris & ephL1, const Gps_CNAV_Ephem
|
|||||||
std::bitset<64> header = Rtcm::get_MT1001_4_header(1004, obs_time, observablesL1_with_L2, ref_id, smooth_int, sync_flag, divergence_free);
|
std::bitset<64> header = Rtcm::get_MT1001_4_header(1004, obs_time, observablesL1_with_L2, ref_id, smooth_int, sync_flag, divergence_free);
|
||||||
std::string data = header.to_string();
|
std::string data = header.to_string();
|
||||||
|
|
||||||
for(common_observables_iter = common_observables.begin();
|
for(common_observables_iter = common_observables.cbegin();
|
||||||
common_observables_iter != common_observables.end();
|
common_observables_iter != common_observables.cend();
|
||||||
common_observables_iter++)
|
common_observables_iter++)
|
||||||
{
|
{
|
||||||
std::bitset<125> content = Rtcm::get_MT1004_sat_content(ephL1, ephL2, obs_time, common_observables_iter->first, common_observables_iter->second);
|
std::bitset<125> content = Rtcm::get_MT1004_sat_content(ephL1, ephL2, obs_time, common_observables_iter->first, common_observables_iter->second);
|
||||||
@ -1037,7 +1037,7 @@ std::string Rtcm::print_MT1008(unsigned int ref_id, const std::string & antenna_
|
|||||||
DF029 = std::bitset<8>(len);
|
DF029 = std::bitset<8>(len);
|
||||||
|
|
||||||
std::string DF030_str_;
|
std::string DF030_str_;
|
||||||
for(auto it = ant_descriptor.begin(); it != ant_descriptor.end(); it++)
|
for(auto it = ant_descriptor.cbegin(); it != ant_descriptor.cend(); it++)
|
||||||
{
|
{
|
||||||
char c = *it;
|
char c = *it;
|
||||||
std::bitset<8> character = std::bitset<8>(c);
|
std::bitset<8> character = std::bitset<8>(c);
|
||||||
@ -1056,7 +1056,7 @@ std::string Rtcm::print_MT1008(unsigned int ref_id, const std::string & antenna_
|
|||||||
DF032 = std::bitset<8>(len2);
|
DF032 = std::bitset<8>(len2);
|
||||||
|
|
||||||
std::string DF033_str_;
|
std::string DF033_str_;
|
||||||
for(auto it = ant_sn.begin(); it != ant_sn.end(); it++)
|
for(auto it = ant_sn.cbegin(); it != ant_sn.cend(); it++)
|
||||||
{
|
{
|
||||||
char c = *it;
|
char c = *it;
|
||||||
std::bitset<8> character = std::bitset<8>(c);
|
std::bitset<8> character = std::bitset<8>(c);
|
||||||
@ -1317,7 +1317,7 @@ std::string Rtcm::print_MT1029(unsigned int ref_id, const Gps_Ephemeris & gps_ep
|
|||||||
unsigned int i = 0;
|
unsigned int i = 0;
|
||||||
bool first = true;
|
bool first = true;
|
||||||
std::string text_binary;
|
std::string text_binary;
|
||||||
for(auto it = message.begin(); it != message.end(); it++)
|
for(auto it = message.cbegin(); it != message.cend(); it++)
|
||||||
{
|
{
|
||||||
char c = *it;
|
char c = *it;
|
||||||
if(isgraph(c))
|
if(isgraph(c))
|
||||||
@ -1684,8 +1684,8 @@ std::string Rtcm::get_MSM_1_content_sat_data(const std::map<int, Gnss_Synchro> &
|
|||||||
std::vector<unsigned int> pos;
|
std::vector<unsigned int> pos;
|
||||||
std::vector<unsigned int>::iterator it;
|
std::vector<unsigned int>::iterator it;
|
||||||
|
|
||||||
for(gnss_synchro_iter = observables.begin();
|
for(gnss_synchro_iter = observables.cbegin();
|
||||||
gnss_synchro_iter != observables.end();
|
gnss_synchro_iter != observables.cend();
|
||||||
gnss_synchro_iter++)
|
gnss_synchro_iter++)
|
||||||
{
|
{
|
||||||
it = std::find(pos.begin(), pos.end(), 65 - gnss_synchro_iter->second.PRN);
|
it = std::find(pos.begin(), pos.end(), 65 - gnss_synchro_iter->second.PRN);
|
||||||
@ -1717,8 +1717,8 @@ std::string Rtcm::get_MSM_1_content_signal_data(const std::map<int, Gnss_Synchro
|
|||||||
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
||||||
|
|
||||||
for(map_iter = observables.begin();
|
for(map_iter = observables.cbegin();
|
||||||
map_iter != observables.end();
|
map_iter != observables.cend();
|
||||||
map_iter++)
|
map_iter++)
|
||||||
{
|
{
|
||||||
observables_vector.push_back(*map_iter);
|
observables_vector.push_back(*map_iter);
|
||||||
@ -1806,8 +1806,8 @@ std::string Rtcm::get_MSM_2_content_signal_data(const Gps_Ephemeris & ephNAV, co
|
|||||||
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
||||||
|
|
||||||
for(map_iter = observables.begin();
|
for(map_iter = observables.cbegin();
|
||||||
map_iter != observables.end();
|
map_iter != observables.cend();
|
||||||
map_iter++)
|
map_iter++)
|
||||||
{
|
{
|
||||||
observables_vector.push_back(*map_iter);
|
observables_vector.push_back(*map_iter);
|
||||||
@ -1902,8 +1902,8 @@ std::string Rtcm::get_MSM_3_content_signal_data(const Gps_Ephemeris & ephNAV, co
|
|||||||
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
||||||
|
|
||||||
for(map_iter = observables.begin();
|
for(map_iter = observables.cbegin();
|
||||||
map_iter != observables.end();
|
map_iter != observables.cend();
|
||||||
map_iter++)
|
map_iter++)
|
||||||
{
|
{
|
||||||
observables_vector.push_back(*map_iter);
|
observables_vector.push_back(*map_iter);
|
||||||
@ -2000,8 +2000,8 @@ std::string Rtcm::get_MSM_4_content_sat_data(const std::map<int, Gnss_Synchro> &
|
|||||||
std::vector<unsigned int> pos;
|
std::vector<unsigned int> pos;
|
||||||
std::vector<unsigned int>::iterator it;
|
std::vector<unsigned int>::iterator it;
|
||||||
|
|
||||||
for(gnss_synchro_iter = observables.begin();
|
for(gnss_synchro_iter = observables.cbegin();
|
||||||
gnss_synchro_iter != observables.end();
|
gnss_synchro_iter != observables.cend();
|
||||||
gnss_synchro_iter++)
|
gnss_synchro_iter++)
|
||||||
{
|
{
|
||||||
it = std::find(pos.begin(), pos.end(), 65 - gnss_synchro_iter->second.PRN);
|
it = std::find(pos.begin(), pos.end(), 65 - gnss_synchro_iter->second.PRN);
|
||||||
@ -2040,8 +2040,8 @@ std::string Rtcm::get_MSM_4_content_signal_data(const Gps_Ephemeris & ephNAV, co
|
|||||||
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
||||||
|
|
||||||
for(map_iter = observables.begin();
|
for(map_iter = observables.cbegin();
|
||||||
map_iter != observables.end();
|
map_iter != observables.cend();
|
||||||
map_iter++)
|
map_iter++)
|
||||||
{
|
{
|
||||||
observables_vector.push_back(*map_iter);
|
observables_vector.push_back(*map_iter);
|
||||||
@ -2142,8 +2142,8 @@ std::string Rtcm::get_MSM_5_content_sat_data(const std::map<int, Gnss_Synchro> &
|
|||||||
std::vector<unsigned int> pos;
|
std::vector<unsigned int> pos;
|
||||||
std::vector<unsigned int>::iterator it;
|
std::vector<unsigned int>::iterator it;
|
||||||
|
|
||||||
for(gnss_synchro_iter = observables.begin();
|
for(gnss_synchro_iter = observables.cbegin();
|
||||||
gnss_synchro_iter != observables.end();
|
gnss_synchro_iter != observables.cend();
|
||||||
gnss_synchro_iter++)
|
gnss_synchro_iter++)
|
||||||
{
|
{
|
||||||
it = std::find(pos.begin(), pos.end(), 65 - gnss_synchro_iter->second.PRN);
|
it = std::find(pos.begin(), pos.end(), 65 - gnss_synchro_iter->second.PRN);
|
||||||
@ -2187,8 +2187,8 @@ std::string Rtcm::get_MSM_5_content_signal_data(const Gps_Ephemeris & ephNAV, co
|
|||||||
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
||||||
|
|
||||||
for(map_iter = observables.begin();
|
for(map_iter = observables.cbegin();
|
||||||
map_iter != observables.end();
|
map_iter != observables.cend();
|
||||||
map_iter++)
|
map_iter++)
|
||||||
{
|
{
|
||||||
observables_vector.push_back(*map_iter);
|
observables_vector.push_back(*map_iter);
|
||||||
@ -2290,8 +2290,8 @@ std::string Rtcm::get_MSM_6_content_signal_data(const Gps_Ephemeris & ephNAV, co
|
|||||||
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
||||||
|
|
||||||
for(map_iter = observables.begin();
|
for(map_iter = observables.cbegin();
|
||||||
map_iter != observables.end();
|
map_iter != observables.cend();
|
||||||
map_iter++)
|
map_iter++)
|
||||||
{
|
{
|
||||||
observables_vector.push_back(*map_iter);
|
observables_vector.push_back(*map_iter);
|
||||||
@ -2392,8 +2392,8 @@ std::string Rtcm::get_MSM_7_content_signal_data(const Gps_Ephemeris & ephNAV, co
|
|||||||
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
std::vector<std::pair<int, Gnss_Synchro> > observables_vector;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
std::map<int, Gnss_Synchro>::const_iterator map_iter;
|
||||||
|
|
||||||
for(map_iter = observables.begin();
|
for(map_iter = observables.cbegin();
|
||||||
map_iter != observables.end();
|
map_iter != observables.cend();
|
||||||
map_iter++)
|
map_iter++)
|
||||||
{
|
{
|
||||||
observables_vector.push_back(*map_iter);
|
observables_vector.push_back(*map_iter);
|
||||||
@ -2442,8 +2442,8 @@ std::vector<std::pair<int, Gnss_Synchro> > Rtcm::sort_by_PRN_mask(const std::vec
|
|||||||
}
|
}
|
||||||
} has_lower_pos;
|
} has_lower_pos;
|
||||||
|
|
||||||
for(synchro_map_iter = synchro_map.begin();
|
for(synchro_map_iter = synchro_map.cbegin();
|
||||||
synchro_map_iter != synchro_map.end();
|
synchro_map_iter != synchro_map.cend();
|
||||||
synchro_map_iter++)
|
synchro_map_iter++)
|
||||||
|
|
||||||
{
|
{
|
||||||
@ -2499,8 +2499,8 @@ std::vector<std::pair<int, Gnss_Synchro> > Rtcm::sort_by_signal(const std::vecto
|
|||||||
} has_lower_signalID;
|
} has_lower_signalID;
|
||||||
|
|
||||||
|
|
||||||
for(synchro_map_iter = synchro_map.begin();
|
for(synchro_map_iter = synchro_map.cbegin();
|
||||||
synchro_map_iter != synchro_map.end();
|
synchro_map_iter != synchro_map.cend();
|
||||||
synchro_map_iter++)
|
synchro_map_iter++)
|
||||||
|
|
||||||
{
|
{
|
||||||
@ -2785,8 +2785,8 @@ int Rtcm::set_DF006(const std::map<int, Gnss_Synchro> & observables)
|
|||||||
//Number of satellites observed in current epoch
|
//Number of satellites observed in current epoch
|
||||||
unsigned short int nsats = 0;
|
unsigned short int nsats = 0;
|
||||||
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
std::map<int, Gnss_Synchro>::const_iterator observables_iter;
|
||||||
for(observables_iter = observables.begin();
|
for(observables_iter = observables.cbegin();
|
||||||
observables_iter != observables.end();
|
observables_iter != observables.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
nsats++;
|
nsats++;
|
||||||
@ -3566,8 +3566,8 @@ int Rtcm::set_DF394(const std::map<int, Gnss_Synchro> & gnss_synchro)
|
|||||||
DF394.reset();
|
DF394.reset();
|
||||||
std::map<int, Gnss_Synchro>::const_iterator gnss_synchro_iter;
|
std::map<int, Gnss_Synchro>::const_iterator gnss_synchro_iter;
|
||||||
unsigned int mask_position;
|
unsigned int mask_position;
|
||||||
for(gnss_synchro_iter = gnss_synchro.begin();
|
for(gnss_synchro_iter = gnss_synchro.cbegin();
|
||||||
gnss_synchro_iter != gnss_synchro.end();
|
gnss_synchro_iter != gnss_synchro.cend();
|
||||||
gnss_synchro_iter++)
|
gnss_synchro_iter++)
|
||||||
{
|
{
|
||||||
mask_position = 64 - gnss_synchro_iter->second.PRN;
|
mask_position = 64 - gnss_synchro_iter->second.PRN;
|
||||||
@ -3587,8 +3587,8 @@ int Rtcm::set_DF395(const std::map<int, Gnss_Synchro> & gnss_synchro)
|
|||||||
std::map<int, Gnss_Synchro>::const_iterator gnss_synchro_iter;
|
std::map<int, Gnss_Synchro>::const_iterator gnss_synchro_iter;
|
||||||
std::string sig;
|
std::string sig;
|
||||||
unsigned int mask_position;
|
unsigned int mask_position;
|
||||||
for(gnss_synchro_iter = gnss_synchro.begin();
|
for(gnss_synchro_iter = gnss_synchro.cbegin();
|
||||||
gnss_synchro_iter != gnss_synchro.end();
|
gnss_synchro_iter != gnss_synchro.cend();
|
||||||
gnss_synchro_iter++)
|
gnss_synchro_iter++)
|
||||||
{
|
{
|
||||||
std::string sig_(gnss_synchro_iter->second.Signal);
|
std::string sig_(gnss_synchro_iter->second.Signal);
|
||||||
@ -3654,8 +3654,8 @@ std::string Rtcm::set_DF396(const std::map<int, Gnss_Synchro> & observables)
|
|||||||
std::vector<unsigned int> list_of_sats;
|
std::vector<unsigned int> list_of_sats;
|
||||||
std::vector<int> list_of_signals;
|
std::vector<int> list_of_signals;
|
||||||
|
|
||||||
for(observables_iter = observables.begin();
|
for(observables_iter = observables.cbegin();
|
||||||
observables_iter != observables.end();
|
observables_iter != observables.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
list_of_sats.push_back(observables_iter->second.PRN);
|
list_of_sats.push_back(observables_iter->second.PRN);
|
||||||
@ -3708,8 +3708,8 @@ std::string Rtcm::set_DF396(const std::map<int, Gnss_Synchro> & observables)
|
|||||||
for(unsigned int sat = 0; sat < num_satellites; sat++)
|
for(unsigned int sat = 0; sat < num_satellites; sat++)
|
||||||
{
|
{
|
||||||
value = false;
|
value = false;
|
||||||
for(observables_iter = observables.begin();
|
for(observables_iter = observables.cbegin();
|
||||||
observables_iter != observables.end();
|
observables_iter != observables.cend();
|
||||||
observables_iter++)
|
observables_iter++)
|
||||||
{
|
{
|
||||||
std::string sig_(observables_iter->second.Signal);
|
std::string sig_(observables_iter->second.Signal);
|
||||||
|
@ -93,7 +93,7 @@ int DataTypeAdapter::run_ishort_to_cshort_block()
|
|||||||
EXPECT_EQ(expected_implementation, ishort_to_cshort->implementation());
|
EXPECT_EQ(expected_implementation, ishort_to_cshort->implementation());
|
||||||
|
|
||||||
std::ofstream ofs(file_name_input.c_str(), std::ofstream::binary);
|
std::ofstream ofs(file_name_input.c_str(), std::ofstream::binary);
|
||||||
for(std::vector<short>::const_iterator i = input_data_shorts.begin(); i != input_data_shorts.end(); ++i)
|
for(std::vector<short>::const_iterator i = input_data_shorts.cbegin(); i != input_data_shorts.cend(); ++i)
|
||||||
{
|
{
|
||||||
short aux = *i;
|
short aux = *i;
|
||||||
ofs.write(reinterpret_cast<const char*>(&aux), sizeof(short));
|
ofs.write(reinterpret_cast<const char*>(&aux), sizeof(short));
|
||||||
@ -122,7 +122,7 @@ int DataTypeAdapter::run_ishort_to_complex_block()
|
|||||||
EXPECT_EQ(expected_implementation, ishort_to_complex->implementation());
|
EXPECT_EQ(expected_implementation, ishort_to_complex->implementation());
|
||||||
|
|
||||||
std::ofstream ofs(file_name_input.c_str(), std::ofstream::binary);
|
std::ofstream ofs(file_name_input.c_str(), std::ofstream::binary);
|
||||||
for(std::vector<short>::const_iterator i = input_data_shorts.begin(); i != input_data_shorts.end(); ++i)
|
for(std::vector<short>::const_iterator i = input_data_shorts.cbegin(); i != input_data_shorts.cend(); ++i)
|
||||||
{
|
{
|
||||||
short aux = *i;
|
short aux = *i;
|
||||||
ofs.write(reinterpret_cast<const char*>(&aux), sizeof(short));
|
ofs.write(reinterpret_cast<const char*>(&aux), sizeof(short));
|
||||||
@ -151,7 +151,7 @@ int DataTypeAdapter::run_ibyte_to_cshort_block()
|
|||||||
EXPECT_EQ(expected_implementation, ibyte_to_cshort->implementation());
|
EXPECT_EQ(expected_implementation, ibyte_to_cshort->implementation());
|
||||||
|
|
||||||
std::ofstream ofs(file_name_input.c_str());
|
std::ofstream ofs(file_name_input.c_str());
|
||||||
for(std::vector<int8_t>::const_iterator i = input_data_bytes.begin(); i != input_data_bytes.end(); ++i)
|
for(std::vector<int8_t>::const_iterator i = input_data_bytes.cbegin(); i != input_data_bytes.cend(); ++i)
|
||||||
{
|
{
|
||||||
ofs << *i;
|
ofs << *i;
|
||||||
}
|
}
|
||||||
@ -179,7 +179,7 @@ int DataTypeAdapter::run_ibyte_to_complex_block()
|
|||||||
EXPECT_EQ(expected_implementation, ibyte_to_complex->implementation());
|
EXPECT_EQ(expected_implementation, ibyte_to_complex->implementation());
|
||||||
|
|
||||||
std::ofstream ofs(file_name_input.c_str() );
|
std::ofstream ofs(file_name_input.c_str() );
|
||||||
for(std::vector<int8_t>::const_iterator i = input_data_bytes.begin(); i != input_data_bytes.end(); ++i)
|
for(std::vector<int8_t>::const_iterator i = input_data_bytes.cbegin(); i != input_data_bytes.cend(); ++i)
|
||||||
{
|
{
|
||||||
ofs << *i;
|
ofs << *i;
|
||||||
}
|
}
|
||||||
@ -207,7 +207,7 @@ int DataTypeAdapter::run_ibyte_to_cbyte_block()
|
|||||||
EXPECT_EQ(expected_implementation, ibyte_to_cbyte->implementation());
|
EXPECT_EQ(expected_implementation, ibyte_to_cbyte->implementation());
|
||||||
|
|
||||||
std::ofstream ofs(file_name_input.c_str());
|
std::ofstream ofs(file_name_input.c_str());
|
||||||
for(std::vector<int8_t>::const_iterator i = input_data_bytes.begin(); i != input_data_bytes.end(); ++i)
|
for(std::vector<int8_t>::const_iterator i = input_data_bytes.cbegin(); i != input_data_bytes.cend(); ++i)
|
||||||
{
|
{
|
||||||
ofs << *i;
|
ofs << *i;
|
||||||
}
|
}
|
||||||
@ -235,7 +235,7 @@ int DataTypeAdapter::run_byte_to_short_block()
|
|||||||
EXPECT_EQ(expected_implementation, byte_to_short->implementation());
|
EXPECT_EQ(expected_implementation, byte_to_short->implementation());
|
||||||
|
|
||||||
std::ofstream ofs(file_name_input.c_str());
|
std::ofstream ofs(file_name_input.c_str());
|
||||||
for(std::vector<int8_t>::const_iterator i = input_data_bytes.begin(); i != input_data_bytes.end(); ++i)
|
for(std::vector<int8_t>::const_iterator i = input_data_bytes.cbegin(); i != input_data_bytes.cend(); ++i)
|
||||||
{
|
{
|
||||||
ofs << *i;
|
ofs << *i;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user