mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2024-12-14 20:20:35 +00:00
add XTRX gain setting and reading (osmocom source)
This commit is contained in:
parent
8f2f0781a1
commit
c7f3994683
@ -101,8 +101,20 @@ OsmosdrSignalSource::OsmosdrSignalSource(const ConfigurationInterface* configura
|
||||
}
|
||||
else
|
||||
{
|
||||
std::cout << "Actual RX Gain: " << osmosdr_source_->get_gain() << " dB...\n";
|
||||
LOG(INFO) << "Actual RX Gain: " << osmosdr_source_->get_gain() << " dB...";
|
||||
if (!osmosdr_args_.empty() && (osmosdr_args_.find("xtrx") != std::string::npos))
|
||||
{
|
||||
osmosdr_source_->set_gain(gain_, "LNA", 0);
|
||||
osmosdr_source_->set_gain(rf_gain_, "TIA", 0);
|
||||
osmosdr_source_->set_gain(if_gain_, "PGA", 0);
|
||||
std::cout << "Actual XTRX LNA Gain: " << osmosdr_source_->get_gain("LNA", 0) << " dB...\n";
|
||||
std::cout << "Actual XTRX TIA Gain: " << osmosdr_source_->get_gain("TIA", 0) << " dB...\n";
|
||||
std::cout << "Actual XTRX PGA Gain: " << osmosdr_source_->get_gain("PGA", 0) << " dB...\n";
|
||||
}
|
||||
else
|
||||
{
|
||||
std::cout << "Actual RX Gain: " << osmosdr_source_->get_gain() << " dB...\n";
|
||||
LOG(INFO) << "Actual RX Gain: " << osmosdr_source_->get_gain() << " dB...";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user