mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2024-12-15 04:30:33 +00:00
Merge branch 'next' of https://github.com/gnss-sdr/gnss-sdr into acq_performance
This commit is contained in:
commit
3f0880cf8e
@ -82,7 +82,31 @@ bool acquisition_dump_reader::read_binary_acq()
|
||||
Mat_VarFree(var2_);
|
||||
|
||||
var2_ = Mat_VarRead(matfile, "input_power");
|
||||
float normalization_factor = *static_cast<float*>(var2_->data);
|
||||
input_power = *static_cast<float*>(var2_->data);
|
||||
Mat_VarFree(var2_);
|
||||
|
||||
var2_ = Mat_VarRead(matfile, "acq_doppler_hz");
|
||||
acq_doppler_hz = *static_cast<float*>(var2_->data);
|
||||
Mat_VarFree(var2_);
|
||||
|
||||
var2_ = Mat_VarRead(matfile, "acq_delay_samples");
|
||||
acq_delay_samples = *static_cast<float*>(var2_->data);
|
||||
Mat_VarFree(var2_);
|
||||
|
||||
var2_ = Mat_VarRead(matfile, "test_statistic");
|
||||
test_statistic = *static_cast<float*>(var2_->data);
|
||||
Mat_VarFree(var2_);
|
||||
|
||||
var2_ = Mat_VarRead(matfile, "threshold");
|
||||
threshold = *static_cast<float*>(var2_->data);
|
||||
Mat_VarFree(var2_);
|
||||
|
||||
var2_ = Mat_VarRead(matfile, "sample_counter");
|
||||
sample_counter = *static_cast<long unsigned int*>(var2_->data);
|
||||
Mat_VarFree(var2_);
|
||||
|
||||
var2_ = Mat_VarRead(matfile, "d_positive_acq");
|
||||
positive_acq = *static_cast<int*>(var2_->data);
|
||||
Mat_VarFree(var2_);
|
||||
|
||||
std::vector<std::vector<float> >::iterator it1;
|
||||
@ -93,7 +117,7 @@ bool acquisition_dump_reader::read_binary_acq()
|
||||
{
|
||||
for (it2 = it1->begin(); it2 != it1->end(); it2++)
|
||||
{
|
||||
*it2 = static_cast<float>(aux[k]) / normalization_factor;
|
||||
*it2 = static_cast<float>(aux[k]) / input_power;
|
||||
k++;
|
||||
}
|
||||
}
|
||||
@ -117,6 +141,13 @@ acquisition_dump_reader::acquisition_dump_reader(const std::string& basename,
|
||||
d_doppler_max = doppler_max;
|
||||
d_doppler_step = doppler_step;
|
||||
d_samples_per_code = samples_per_code;
|
||||
acq_doppler_hz = 0.0;
|
||||
acq_delay_samples = 0.0;
|
||||
test_statistic = 0.0;
|
||||
input_power = 0.0;
|
||||
threshold = 0.0;
|
||||
positive_acq = 0;
|
||||
sample_counter = 0;
|
||||
d_num_doppler_bins = static_cast<unsigned int>(ceil(static_cast<double>(static_cast<int>(d_doppler_max) - static_cast<int>(-d_doppler_max)) / static_cast<double>(d_doppler_step)));
|
||||
std::vector<std::vector<float> > mag_aux(d_num_doppler_bins, std::vector<float>(d_samples_per_code));
|
||||
mag = mag_aux;
|
||||
|
@ -51,6 +51,13 @@ public:
|
||||
std::vector<int> doppler;
|
||||
std::vector<unsigned int> samples;
|
||||
std::vector<std::vector<float> > mag;
|
||||
float acq_doppler_hz;
|
||||
float acq_delay_samples;
|
||||
float test_statistic;
|
||||
float input_power;
|
||||
float threshold;
|
||||
int positive_acq;
|
||||
long unsigned int sample_counter;
|
||||
|
||||
private:
|
||||
std::string d_basename;
|
||||
|
Loading…
Reference in New Issue
Block a user