1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-25 01:18:38 -05:00

RTL-SDR: fixed gain setting sequence (issue #321)

This commit is contained in:
f4exb 2019-04-03 23:01:29 +02:00
parent 0e1b5cbb4a
commit f4d0066edf
6 changed files with 23 additions and 18 deletions

View File

@ -35,7 +35,7 @@ static int runQtApplication(int argc, char* argv[], qtwebapp::LoggerWithFile *lo
*/
QCoreApplication::setOrganizationName("f4exb");
QCoreApplication::setApplicationName("SDRangel");
QCoreApplication::setApplicationVersion("4.5.3");
QCoreApplication::setApplicationVersion("4.5.4");
#if QT_VERSION >= 0x050600
QApplication::setAttribute(Qt::AA_EnableHighDpiScaling); // DPI support
QCoreApplication::setAttribute(Qt::AA_UseHighDpiPixmaps); //HiDPI pixmaps

View File

@ -57,7 +57,7 @@ static int runQtApplication(int argc, char* argv[], qtwebapp::LoggerWithFile *lo
QCoreApplication::setOrganizationName("f4exb");
QCoreApplication::setApplicationName("SDRangelBench");
QCoreApplication::setApplicationVersion("4.5.3");
QCoreApplication::setApplicationVersion("4.5.4");
int catchSignals[] = {SIGQUIT, SIGINT, SIGTERM, SIGHUP};
std::vector<int> vsig(catchSignals, catchSignals + sizeof(catchSignals) / sizeof(int));

View File

@ -56,7 +56,7 @@ static int runQtApplication(int argc, char* argv[], qtwebapp::LoggerWithFile *lo
QCoreApplication::setOrganizationName("f4exb");
QCoreApplication::setApplicationName("SDRangelSrv");
QCoreApplication::setApplicationVersion("4.5.3");
QCoreApplication::setApplicationVersion("4.5.4");
int catchSignals[] = {SIGQUIT, SIGINT, SIGTERM, SIGHUP};
std::vector<int> vsig(catchSignals, catchSignals + sizeof(catchSignals) / sizeof(int));

6
debian/changelog vendored
View File

@ -1,3 +1,9 @@
sdrangel (4.5.4-1) unstable; urgency=medium
* Fixed RTL-SDR gain setting sequence. Fixes issue #321.
-- Edouard Griffiths, F4EXB <f4exb06@gmail.com> Fri, 05 Apr 2019 20:14:18 +0100
sdrangel (4.5.3-1) unstable; urgency=medium
* Fixed HackRF Rx/Tx frequency setting. Fixes issue #318.

View File

@ -380,20 +380,6 @@ bool RTLSDRInput::applySettings(const RTLSDRSettings& settings, bool force)
}
}
if ((m_settings.m_gain != settings.m_gain) || force)
{
reverseAPIKeys.append("gain");
if(m_dev != 0)
{
if (rtlsdr_set_tuner_gain(m_dev, settings.m_gain) != 0) {
qCritical("RTLSDRInput::applySettings: rtlsdr_set_tuner_gain() failed");
} else {
qDebug("RTLSDRInput::applySettings: rtlsdr_set_tuner_gain() to %d", settings.m_gain);
}
}
}
if ((m_settings.m_dcBlock != settings.m_dcBlock) || (m_settings.m_iqImbalance != settings.m_iqImbalance) || force)
{
reverseAPIKeys.append("dcBlock");
@ -550,6 +536,19 @@ bool RTLSDRInput::applySettings(const RTLSDRSettings& settings, bool force)
}
}
if ((m_settings.m_gain != settings.m_gain) || force)
{
reverseAPIKeys.append("gain");
if(m_dev != 0)
{
if (rtlsdr_set_tuner_gain(m_dev, settings.m_gain) != 0) {
qCritical("RTLSDRInput::applySettings: rtlsdr_set_tuner_gain() failed");
} else {
qDebug("RTLSDRInput::applySettings: rtlsdr_set_tuner_gain() to %d", settings.m_gain);
}
}
}
if (settings.m_useReverseAPI)
{

View File

@ -14,7 +14,7 @@
const PluginDescriptor RTLSDRPlugin::m_pluginDescriptor = {
QString("RTL-SDR Input"),
QString("4.5.2"),
QString("4.5.4"),
QString("(c) Edouard Griffiths, F4EXB"),
QString("https://github.com/f4exb/sdrangel"),
true,