mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-26 17:58:43 -05:00
LimeSDR: clamp NCO lower limit to 0
This commit is contained in:
parent
c29d9623f4
commit
50c39b90a1
@ -287,8 +287,9 @@ void LimeSDROutputGUI::displaySettings()
|
||||
void LimeSDROutputGUI::setNCODisplay()
|
||||
{
|
||||
int ncoHalfRange = (m_settings.m_devSampleRate * (1<<(m_settings.m_log2HardInterp)))/2;
|
||||
int lowBoundary = std::max(0, (int) m_settings.m_centerFrequency - ncoHalfRange);
|
||||
ui->ncoFrequency->setValueRange(7,
|
||||
(m_settings.m_centerFrequency - ncoHalfRange)/1000,
|
||||
lowBoundary/1000,
|
||||
(m_settings.m_centerFrequency + ncoHalfRange)/1000); // frequency dial is in kHz
|
||||
ui->ncoFrequency->setValue((m_settings.m_centerFrequency + m_settings.m_ncoFrequency)/1000);
|
||||
}
|
||||
|
@ -30,7 +30,7 @@
|
||||
|
||||
const PluginDescriptor LimeSDROutputPlugin::m_pluginDescriptor = {
|
||||
QString("LimeSDR Output"),
|
||||
QString("3.5.0"),
|
||||
QString("3.5.4"),
|
||||
QString("(c) Edouard Griffiths, F4EXB"),
|
||||
QString("https://github.com/f4exb/sdrangel"),
|
||||
true,
|
||||
|
@ -19,6 +19,8 @@
|
||||
#include <QDebug>
|
||||
#include <QMessageBox>
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
#include "ui_limesdrinputgui.h"
|
||||
#include "gui/colormapper.h"
|
||||
#include "gui/glspectrum.h"
|
||||
@ -313,8 +315,9 @@ void LimeSDRInputGUI::displaySettings()
|
||||
void LimeSDRInputGUI::setNCODisplay()
|
||||
{
|
||||
int ncoHalfRange = (m_settings.m_devSampleRate * (1<<(m_settings.m_log2HardDecim)))/2;
|
||||
int lowBoundary = std::max(0, (int) m_settings.m_centerFrequency - ncoHalfRange);
|
||||
ui->ncoFrequency->setValueRange(7,
|
||||
(m_settings.m_centerFrequency - ncoHalfRange)/1000,
|
||||
lowBoundary/1000,
|
||||
(m_settings.m_centerFrequency + ncoHalfRange)/1000); // frequency dial is in kHz
|
||||
ui->ncoFrequency->setValue((m_settings.m_centerFrequency + m_settings.m_ncoFrequency)/1000);
|
||||
}
|
||||
|
@ -31,7 +31,7 @@
|
||||
|
||||
const PluginDescriptor LimeSDRInputPlugin::m_pluginDescriptor = {
|
||||
QString("LimeSDR Input"),
|
||||
QString("3.5.0"),
|
||||
QString("3.5.4"),
|
||||
QString("(c) Edouard Griffiths, F4EXB"),
|
||||
QString("https://github.com/f4exb/sdrangel"),
|
||||
true,
|
||||
|
Loading…
Reference in New Issue
Block a user