1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-12-15 12:40:35 +00:00

Remove debug lines

This commit is contained in:
Antonio Ramos 2018-01-22 12:21:28 +01:00
parent 7a2a02252a
commit dd77cd10df
4 changed files with 0 additions and 35 deletions

View File

@ -54,7 +54,6 @@ SpirGSS6450FileSignalSource::SpirGSS6450FileSignalSource(ConfigurationInterface*
filename_ = configuration->property(role + ".filename", default_filename); filename_ = configuration->property(role + ".filename", default_filename);
repeat_ = configuration->property(role + ".repeat", false); repeat_ = configuration->property(role + ".repeat", false);
dump_ = configuration->property(role + ".dump", false); dump_ = configuration->property(role + ".dump", false);
dump_test_ = configuration->property(role + ".dump_test", false);
endian_swap_ = configuration->property(role + ".endian", false); endian_swap_ = configuration->property(role + ".endian", false);
dump_filename_ = configuration->property(role + ".dump_filename", default_dump_filename); dump_filename_ = configuration->property(role + ".dump_filename", default_dump_filename);
enable_throttle_control_ = configuration->property(role + ".enable_throttle_control", false); enable_throttle_control_ = configuration->property(role + ".enable_throttle_control", false);
@ -150,10 +149,6 @@ SpirGSS6450FileSignalSource::SpirGSS6450FileSignalSource(ConfigurationInterface*
sink_ = gr::blocks::file_sink::make(sizeof(gr_complex), dump_filename_.c_str()); sink_ = gr::blocks::file_sink::make(sizeof(gr_complex), dump_filename_.c_str());
DLOG(INFO) << "file_sink(" << sink_->unique_id() << ")"; DLOG(INFO) << "file_sink(" << sink_->unique_id() << ")";
} }
if (dump_test_)
{
sink_test = gr::blocks::file_sink::make(sizeof(int), (dump_filename_ + "int").c_str());
}
if (enable_throttle_control_) if (enable_throttle_control_)
{ {
throttle_ = gr::blocks::throttle::make(sizeof(gr_complex), sampling_frequency_); throttle_ = gr::blocks::throttle::make(sizeof(gr_complex), sampling_frequency_);
@ -216,11 +211,6 @@ void SpirGSS6450FileSignalSource::connect(gr::top_block_sptr top_block)
{ {
top_block->connect(valve_, 0, sink_, 0); top_block->connect(valve_, 0, sink_, 0);
} }
if(dump_test_)
{
if(endian_swap_) top_block->connect(endian_, 0, sink_test, 0);
else top_block->connect(deint_, sel_ch_ - 1, sink_test, 0);
}
} }
else else
{ {
@ -268,11 +258,6 @@ void SpirGSS6450FileSignalSource::disconnect(gr::top_block_sptr top_block)
{ {
top_block->disconnect(valve_, 0, sink_, 0); top_block->disconnect(valve_, 0, sink_, 0);
} }
if(dump_test_)
{
if(endian_swap_) top_block->disconnect(endian_, 0, sink_test, 0);
else top_block->disconnect(deint_, sel_ch_ - 1, sink_test, 0);
}
} }
else else
{ {

View File

@ -112,7 +112,6 @@ private:
std::string filename_; std::string filename_;
bool repeat_; bool repeat_;
bool dump_; //Enables dumping the gr_complex sample output bool dump_; //Enables dumping the gr_complex sample output
bool dump_test_; //Enables dumping the raw 32-bits deinterleaved (and endian swapped if enabled) words
bool enable_throttle_control_; bool enable_throttle_control_;
bool endian_swap_; bool endian_swap_;
std::string dump_filename_; std::string dump_filename_;
@ -130,7 +129,6 @@ private:
unpack_spir_gss6450_samples_sptr unpack_spir_; unpack_spir_gss6450_samples_sptr unpack_spir_;
boost::shared_ptr<gr::block> valve_; boost::shared_ptr<gr::block> valve_;
gr::blocks::file_sink::sptr sink_; gr::blocks::file_sink::sptr sink_;
gr::blocks::file_sink::sptr sink_test;
gr::blocks::throttle::sptr throttle_; gr::blocks::throttle::sptr throttle_;
gr::msg_queue::sptr queue_; gr::msg_queue::sptr queue_;
size_t item_size_; size_t item_size_;

View File

@ -83,7 +83,6 @@ int unpack_spir_gss6450_samples::work(int noutput_items,
for(int i = 0; i < noutput_items; i++) for(int i = 0; i < noutput_items; i++)
{ {
int sample_aux = in[in_counter]; int sample_aux = in[in_counter];
//reverse_bits(sample_aux);
int aux_i = sample_aux; int aux_i = sample_aux;
int aux_q = sample_aux; int aux_q = sample_aux;
int i_shift = adc_bits * 2 * (samples_per_int - n_sample - 1) + adc_bits; int i_shift = adc_bits * 2 * (samples_per_int - n_sample - 1) + adc_bits;
@ -101,22 +100,6 @@ int unpack_spir_gss6450_samples::work(int noutput_items,
return noutput_items; return noutput_items;
} }
void unpack_spir_gss6450_samples::reverse_bits(int& data)
{
unsigned int v = data; // input bits to be reversed
unsigned int r = v; // r will be reversed bits of v; first get LSB of v
int s = sizeof(v) * CHAR_BIT - 1; // extra shift needed at end
for (v >>= 1; v; v >>= 1)
{
r <<= 1;
r |= v & 1;
s--;
}
r <<= s; // shift when v's highest bits are zero
data = r;
}
void unpack_spir_gss6450_samples::compute_two_complement(int& data) void unpack_spir_gss6450_samples::compute_two_complement(int& data)
{ {
data = map_[data]; data = map_[data];

View File

@ -55,7 +55,6 @@ private:
unsigned int samples_per_int; unsigned int samples_per_int;
void process_sample(gr_complex& out); void process_sample(gr_complex& out);
void compute_two_complement(int& data); void compute_two_complement(int& data);
void reverse_bits(int& data);
int i_data; int i_data;
int q_data; int q_data;
int mask_data; int mask_data;