mirror of
https://github.com/cjcliffe/CubicSDR.git
synced 2024-11-21 19:31:54 -05:00
Temporary patch for bladerf until bandwidth option is available
This commit is contained in:
parent
95fd357c72
commit
096a1aa5fd
@ -89,6 +89,12 @@ void SDRThread::init() {
|
||||
|
||||
wxGetApp().sdrEnumThreadNotify(SDREnumerator::SDR_ENUM_MESSAGE, std::string("Activating stream."));
|
||||
device->setSampleRate(SOAPY_SDR_RX,0,sampleRate.load());
|
||||
|
||||
// TODO: explore bandwidth setting option to see if this is necessary for others
|
||||
if (device->getDriverKey() == "bladerf") {
|
||||
device->setBandwidth(SOAPY_SDR_RX, 0, sampleRate.load());
|
||||
}
|
||||
|
||||
device->setFrequency(SOAPY_SDR_RX,0,"RF",frequency - offset.load());
|
||||
device->activateStream(stream);
|
||||
if (devInfo->hasCORR(SOAPY_SDR_RX, 0)) {
|
||||
@ -280,6 +286,10 @@ void SDRThread::updateSettings() {
|
||||
|
||||
if (rate_changed.load()) {
|
||||
device->setSampleRate(SOAPY_SDR_RX,0,sampleRate.load());
|
||||
// TODO: explore bandwidth setting option to see if this is necessary for others
|
||||
if (device->getDriverKey() == "bladerf") {
|
||||
device->setBandwidth(SOAPY_SDR_RX, 0, sampleRate.load());
|
||||
}
|
||||
sampleRate.store(device->getSampleRate(SOAPY_SDR_RX,0));
|
||||
numChannels.store(getOptimalChannelCount(sampleRate.load()));
|
||||
numElems.store(getOptimalElementCount(sampleRate.load(), 60));
|
||||
|
Loading…
Reference in New Issue
Block a user