Add warning if sample rate is < 48kHz.

pull/1883/head
srcejon 2023-11-09 21:42:33 +00:00
rodzic 27f35feee8
commit d6f5c81856
1 zmienionych plików z 5 dodań i 0 usunięć

Wyświetl plik

@ -101,6 +101,11 @@ bool DSDDemodGUI::handleMessage(const Message& message)
DSPSignalNotification& notif = (DSPSignalNotification&) message;
m_deviceCenterFrequency = notif.getCenterFrequency();
m_basebandSampleRate = notif.getSampleRate();
if (m_basebandSampleRate < 48000) {
setStatusText(QString("Sample rate must be >= 48000 Hz (Currently %1 Hz)").arg(m_basebandSampleRate));
} else {
setStatusText("");
}
ui->deltaFrequency->setValueRange(false, 7, -m_basebandSampleRate/2, m_basebandSampleRate/2);
ui->deltaFrequencyLabel->setToolTip(tr("Range %1 %L2 Hz").arg(QChar(0xB1)).arg(m_basebandSampleRate/2));
updateAbsoluteCenterFrequency();