mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-09-28 07:46:37 -04:00
SoapySDR support: fixed update settings processing in GUIs
This commit is contained in:
parent
2bc59154bf
commit
45a569655a
@ -583,12 +583,13 @@ bool SoapySDROutput::handleMessage(const Message& message)
|
||||
SoapySDROutputSettings settings = m_settings;
|
||||
//bool fromRxBuddy = report.getRxElseTx();
|
||||
|
||||
settings.m_centerFrequency = m_deviceShared.m_device->getFrequency(
|
||||
double centerFrequency = m_deviceShared.m_device->getFrequency(
|
||||
SOAPY_SDR_TX,
|
||||
requestedChannel,
|
||||
m_deviceShared.m_deviceParams->getTxChannelMainTunableElementName(requestedChannel));
|
||||
|
||||
settings.m_devSampleRate = m_deviceShared.m_device->getSampleRate(SOAPY_SDR_TX, requestedChannel);
|
||||
settings.m_centerFrequency = round(centerFrequency/1000.0) * 1000;
|
||||
settings.m_devSampleRate = round(m_deviceShared.m_device->getSampleRate(SOAPY_SDR_TX, requestedChannel));
|
||||
|
||||
//SoapySDROutputThread *outputThread = findThread();
|
||||
|
||||
|
@ -168,7 +168,17 @@ bool SoapySDROutputGui::deserialize(const QByteArray& data)
|
||||
|
||||
bool SoapySDROutputGui::handleMessage(const Message& message)
|
||||
{
|
||||
if (SoapySDROutput::MsgStartStop::match(message))
|
||||
if (SoapySDROutput::MsgConfigureSoapySDROutput::match(message))
|
||||
{
|
||||
const SoapySDROutput::MsgConfigureSoapySDROutput& cfg = (SoapySDROutput::MsgConfigureSoapySDROutput&) message;
|
||||
m_settings = cfg.getSettings();
|
||||
blockApplySettings(true);
|
||||
displaySettings();
|
||||
blockApplySettings(false);
|
||||
|
||||
return true;
|
||||
}
|
||||
else if (SoapySDROutput::MsgStartStop::match(message))
|
||||
{
|
||||
SoapySDROutput::MsgStartStop& notif = (SoapySDROutput::MsgStartStop&) message;
|
||||
blockApplySettings(true);
|
||||
|
@ -620,12 +620,13 @@ bool SoapySDRInput::handleMessage(const Message& message __attribute__((unused))
|
||||
settings.m_fcPos = (SoapySDRInputSettings::fcPos_t) report.getFcPos();
|
||||
//bool fromRxBuddy = report.getRxElseTx();
|
||||
|
||||
settings.m_centerFrequency = m_deviceShared.m_device->getFrequency(
|
||||
double centerFrequency = m_deviceShared.m_device->getFrequency(
|
||||
SOAPY_SDR_RX,
|
||||
requestedChannel,
|
||||
m_deviceShared.m_deviceParams->getRxChannelMainTunableElementName(requestedChannel));
|
||||
|
||||
settings.m_devSampleRate = m_deviceShared.m_device->getSampleRate(SOAPY_SDR_RX, requestedChannel);
|
||||
settings.m_centerFrequency = round(centerFrequency/1000.0) * 1000;
|
||||
settings.m_devSampleRate = round(m_deviceShared.m_device->getSampleRate(SOAPY_SDR_RX, requestedChannel));
|
||||
|
||||
SoapySDRInputThread *inputThread = findThread();
|
||||
|
||||
|
@ -191,10 +191,19 @@ bool SoapySDRInputGui::deserialize(const QByteArray& data)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
bool SoapySDRInputGui::handleMessage(const Message& message)
|
||||
{
|
||||
if (SoapySDRInput::MsgStartStop::match(message))
|
||||
if (SoapySDRInput::MsgConfigureSoapySDRInput::match(message))
|
||||
{
|
||||
const SoapySDRInput::MsgConfigureSoapySDRInput& cfg = (SoapySDRInput::MsgConfigureSoapySDRInput&) message;
|
||||
m_settings = cfg.getSettings();
|
||||
blockApplySettings(true);
|
||||
displaySettings();
|
||||
blockApplySettings(false);
|
||||
|
||||
return true;
|
||||
}
|
||||
else if (SoapySDRInput::MsgStartStop::match(message))
|
||||
{
|
||||
SoapySDRInput::MsgStartStop& notif = (SoapySDRInput::MsgStartStop&) message;
|
||||
blockApplySettings(true);
|
||||
|
Loading…
Reference in New Issue
Block a user