mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2025-01-31 03:14:56 +00:00
Fix std::copy usage, replace more memcpy by std::copy
This commit is contained in:
parent
e8fb655fad
commit
cc50da1425
@ -55,7 +55,7 @@ GalileoE5aDllPllTrackingFpga::GalileoE5aDllPllTrackingFpga(
|
||||
}
|
||||
trk_params_fpga.system = 'E';
|
||||
const std::array<char, 3> sig_{'5', 'X', '\0'};
|
||||
std::copy_n(sig_.data(), 3, trk_params.signal);
|
||||
std::copy_n(sig_.data(), 3, trk_params_fpga.signal);
|
||||
|
||||
d_data_codes = nullptr;
|
||||
|
||||
|
@ -65,7 +65,7 @@ GpsL1CaDllPllTrackingFpga::GpsL1CaDllPllTrackingFpga(
|
||||
}
|
||||
trk_params_fpga.system = 'G';
|
||||
const std::array<char, 3> sig_{'1', 'C', '\0'};
|
||||
std::copy_n(sig_.data(), 3, trk_params.signal);
|
||||
std::copy_n(sig_.data(), 3, trk_params_fpga.signal);
|
||||
|
||||
// UIO device file
|
||||
device_name = configuration->property(role + ".devicename", default_device_name_GPS_L1);
|
||||
|
@ -62,7 +62,7 @@ GpsL2MDllPllTrackingFpga::GpsL2MDllPllTrackingFpga(
|
||||
}
|
||||
trk_params_fpga.system = 'G';
|
||||
const std::array<char, 3> sig_{'2', 'S', '\0'};
|
||||
std::copy_n(sig_.data(), 3, trk_params.signal);
|
||||
std::copy_n(sig_.data(), 3, trk_params_fpga.signal);
|
||||
|
||||
// UIO device file
|
||||
device_name = configuration->property(role + ".devicename", default_device_name_GPS_L2);
|
||||
|
@ -62,7 +62,7 @@ GpsL5DllPllTrackingFpga::GpsL5DllPllTrackingFpga(
|
||||
d_track_pilot = trk_params_fpga.track_pilot;
|
||||
trk_params_fpga.system = 'G';
|
||||
const std::array<char, 3> sig_{'L', '5', '\0'};
|
||||
std::copy_n(sig_.data(), 3, trk_params.signal);
|
||||
std::copy_n(sig_.data(), 3, trk_params_fpga.signal);
|
||||
|
||||
// UIO device file
|
||||
device_name = configuration->property(role + ".devicename", default_device_name_GPS_L5);
|
||||
|
@ -156,7 +156,7 @@ void Galileo_E1_Tcp_Connector_Tracking_cc::start_tracking()
|
||||
d_acq_carrier_doppler_hz = static_cast<float>(d_acquisition_gnss_synchro->Acq_doppler_hz);
|
||||
d_acq_sample_stamp = d_acquisition_gnss_synchro->Acq_samplestamp_samples;
|
||||
std::array<char, 3> Signal_{};
|
||||
std::memcpy(Signal_.data(), d_acquisition_gnss_synchro->Signal, 3);
|
||||
std::copy_n(d_acquisition_gnss_synchro->Signal, 3, Signal_.data());
|
||||
|
||||
// generate local reference ALWAYS starting at chip 1 (2 samples per chip)
|
||||
galileo_e1_code_gen_complex_sampled(d_ca_code,
|
||||
|
@ -24,6 +24,7 @@
|
||||
#include <boost/lexical_cast.hpp>
|
||||
#include <glog/logging.h>
|
||||
#include <gnuradio/io_signature.h>
|
||||
#include <algorithm>
|
||||
#include <cmath>
|
||||
#include <cuda_profiler_api.h>
|
||||
#include <iostream>
|
||||
@ -349,7 +350,7 @@ int Gps_L1_Ca_Dll_Pll_Tracking_GPU_cc::general_work(int noutput_items __attribut
|
||||
// ################# CARRIER WIPEOFF AND CORRELATORS ##############################
|
||||
// perform carrier wipe-off and compute Early, Prompt and Late correlation
|
||||
|
||||
memcpy(in_gpu, in, sizeof(gr_complex) * d_correlation_length_samples);
|
||||
std::copy(in, in + d_correlation_length_samples, in_gpu);
|
||||
cudaProfilerStart();
|
||||
multicorrelator_gpu->Carrier_wipeoff_multicorrelator_resampler_cuda(static_cast<float>(d_rem_carrier_phase_rad),
|
||||
static_cast<float>(d_carrier_phase_step_rad),
|
||||
|
Loading…
Reference in New Issue
Block a user