From 013e51294863b526511797e12426f50b31e08721 Mon Sep 17 00:00:00 2001 From: f4exb Date: Mon, 14 Jan 2019 02:36:33 +0100 Subject: [PATCH] AirspyHF: new settings --- plugins/samplesource/airspyhf/airspyhfgui.cpp | 62 ++++++++ plugins/samplesource/airspyhf/airspyhfgui.h | 5 + plugins/samplesource/airspyhf/airspyhfgui.ui | 136 +++++++++++++++++- .../samplesource/airspyhf/airspyhfinput.cpp | 133 ++++++++++++++++- .../airspyhf/airspyhfsettings.cpp | 16 +++ .../samplesource/airspyhf/airspyhfsettings.h | 5 + sdrbase/resources/webapi/doc/html2/index.html | 22 ++- .../webapi/doc/swagger/include/AirspyHF.yaml | 15 ++ .../api/swagger/include/AirspyHF.yaml | 15 ++ swagger/sdrangel/code/html2/index.html | 22 ++- .../code/qt5/client/SWGAirspyHFSettings.cpp | 105 ++++++++++++++ .../code/qt5/client/SWGAirspyHFSettings.h | 30 ++++ 12 files changed, 561 insertions(+), 5 deletions(-) diff --git a/plugins/samplesource/airspyhf/airspyhfgui.cpp b/plugins/samplesource/airspyhf/airspyhfgui.cpp index aef2be568..a86fcba50 100644 --- a/plugins/samplesource/airspyhf/airspyhfgui.cpp +++ b/plugins/samplesource/airspyhf/airspyhfgui.cpp @@ -227,6 +227,10 @@ void AirspyHFGui::displaySettings() ui->sampleRate->setCurrentIndex(m_settings.m_devSampleRateIndex); ui->decim->setCurrentIndex(m_settings.m_log2Decim); ui->band->blockSignals(false); + ui->dsp->setChecked(m_settings.m_useDSP); + ui->lna->setChecked(m_settings.m_useLNA); + ui->att->setCurrentIndex(m_settings.m_attenuatorSteps); + displayAGC(); blockApplySettings(false); } @@ -258,6 +262,22 @@ void AirspyHFGui::displaySampleRates() } } +void AirspyHFGui::displayAGC() +{ + if (m_settings.m_useAGC) + { + if (m_settings.m_agcHigh) { + ui->agc->setCurrentIndex(2); + } else { + ui->agc->setCurrentIndex(1); + } + } + else + { + ui->agc->setCurrentIndex(0); + } +} + void AirspyHFGui::sendSettings() { if(!m_updateTimer.isActive()) @@ -340,6 +360,48 @@ void AirspyHFGui::on_band_currentIndexChanged(int index) sendSettings(); } +void AirspyHFGui::on_dsp_toggled(bool checked) +{ + m_settings.m_useDSP = checked; + sendSettings(); +} + +void AirspyHFGui::on_lna_toggled(bool checked) +{ + m_settings.m_useLNA = checked; + sendSettings(); +} + +void AirspyHFGui::on_agc_currentIndexChanged(int index) +{ + if (index == 0) + { + m_settings.m_useAGC = false; + sendSettings(); + } + else if (index <= 2) + { + m_settings.m_useAGC = true; + + if (index == 1) { + m_settings.m_agcHigh = false; + } else { + m_settings.m_agcHigh = true; + } + + sendSettings(); + } +} + +void AirspyHFGui::on_att_currentIndexChanged(int index) +{ + if ((index >= 0) && (index <= 8)) + { + m_settings.m_attenuatorSteps = index; + sendSettings(); + } +} + void AirspyHFGui::updateHardware() { qDebug() << "AirspyHFGui::updateHardware"; diff --git a/plugins/samplesource/airspyhf/airspyhfgui.h b/plugins/samplesource/airspyhf/airspyhfgui.h index 6dea4bc27..ef30271f1 100644 --- a/plugins/samplesource/airspyhf/airspyhfgui.h +++ b/plugins/samplesource/airspyhf/airspyhfgui.h @@ -72,6 +72,7 @@ private: void blockApplySettings(bool block) { m_doApplySettings = !block; } void displaySettings(); void displaySampleRates(); + void displayAGC(); void sendSettings(); void updateSampleRateAndFrequency(); void updateFrequencyLimits(); @@ -86,6 +87,10 @@ private slots: void on_record_toggled(bool checked); void on_transverter_clicked(); void on_band_currentIndexChanged(int index); + void on_dsp_toggled(bool checked); + void on_lna_toggled(bool checked); + void on_agc_currentIndexChanged(int index); + void on_att_currentIndexChanged(int index); void updateHardware(); void updateStatus(); void handleInputMessages(); diff --git a/plugins/samplesource/airspyhf/airspyhfgui.ui b/plugins/samplesource/airspyhf/airspyhfgui.ui index 73334a081..1cd52497a 100644 --- a/plugins/samplesource/airspyhf/airspyhfgui.ui +++ b/plugins/samplesource/airspyhf/airspyhfgui.ui @@ -7,7 +7,7 @@ 0 0 324 - 132 + 160 @@ -19,7 +19,7 @@ 320 - 132 + 160 @@ -409,6 +409,138 @@ + + + + + + AGC + + + + + + + + 55 + 16777215 + + + + + Off + + + + + Low + + + + + High + + + + + + + + LNA + + + + + + + Att + + + + + + + + 40 + 16777215 + + + + + 0 + + + + + 6 + + + + + 12 + + + + + 18 + + + + + 24 + + + + + 30 + + + + + 36 + + + + + 42 + + + + + 48 + + + + + + + + dB + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + DSP + + + + + diff --git a/plugins/samplesource/airspyhf/airspyhfinput.cpp b/plugins/samplesource/airspyhf/airspyhfinput.cpp index c3ab0f2de..061815cf3 100644 --- a/plugins/samplesource/airspyhf/airspyhfinput.cpp +++ b/plugins/samplesource/airspyhf/airspyhfinput.cpp @@ -378,7 +378,23 @@ void AirspyHFInput::setDeviceCenterFrequency(quint64 freq_hz, const AirspyHFSett bool AirspyHFInput::applySettings(const AirspyHFSettings& settings, bool force) { - qDebug() << "AirspyHFInput::applySettings"; + qDebug() << "AirspyHFInput::applySettings: " + << " m_centerFrequency: " << settings.m_centerFrequency + << " m_devSampleRateIndex: " << settings.m_devSampleRateIndex + << " m_log2Decim: " << settings.m_log2Decim + << " m_LOppmTenths: " << settings.m_LOppmTenths + << " m_bandIndex: " << settings.m_bandIndex + << " m_transverterDeltaFrequency: " << settings.m_transverterDeltaFrequency + << " m_transverterMode: " << settings.m_transverterMode + << " m_fileRecordName: " << settings.m_fileRecordName + << " m_useDSP: " << settings.m_useDSP + << " m_useAGC: " << settings.m_useAGC + << " m_useLNA: " << settings.m_useLNA + << " m_attenuatorSteps: " << settings.m_attenuatorSteps + << " m_useReverseAPI: " << settings.m_useReverseAPI + << " m_reverseAPIAddress: " << settings.m_reverseAPIAddress + << " m_reverseAPIPort: " << settings.m_reverseAPIPort + << " m_reverseAPIDeviceIndex: " << settings.m_reverseAPIDeviceIndex; QMutexLocker mutexLocker(&m_mutex); @@ -482,6 +498,86 @@ bool AirspyHFInput::applySettings(const AirspyHFSettings& settings, bool force) forwardChange = true; } + if ((m_settings.m_useAGC != settings.m_useAGC) || force) + { + reverseAPIKeys.append("useAGC"); + + if (m_dev != 0) + { + rc = (airspyhf_error) airspyhf_set_hf_agc(m_dev, settings.m_useAGC ? 1 : 0); + + if (rc != AIRSPYHF_SUCCESS) { + qCritical("AirspyHFInput::applySettings: could not set AGC to %d", settings.m_useAGC ? 1 : 0); + } else { + qDebug("AirspyHFInput::applySettings: set AGC to %d", settings.m_useAGC ? 1 : 0); + } + } + } + + if ((m_settings.m_agcHigh != settings.m_agcHigh) || force) + { + reverseAPIKeys.append("agcHigh"); + + if (m_dev != 0) + { + rc = (airspyhf_error) airspyhf_set_hf_agc_threshold(m_dev, settings.m_agcHigh ? 1 : 0); + + if (rc != AIRSPYHF_SUCCESS) { + qCritical("AirspyHFInput::applySettings: could not set AGC to %s", settings.m_agcHigh ? "high" : "low"); + } else { + qDebug("AirspyHFInput::applySettings: set AGC to %s", settings.m_agcHigh ? "high" : "low"); + } + } + } + + if ((m_settings.m_useDSP != settings.m_useDSP) || force) + { + reverseAPIKeys.append("useDSP"); + + if (m_dev != 0) + { + rc = (airspyhf_error) airspyhf_set_lib_dsp(m_dev, settings.m_useDSP ? 1 : 0); + + if (rc != AIRSPYHF_SUCCESS) { + qCritical("AirspyHFInput::applySettings: could not set DSP to %d", settings.m_useDSP ? 1 : 0); + } else { + qDebug("AirspyHFInput::applySettings: set DSP to %d", settings.m_useDSP ? 1 : 0); + } + } + } + + if ((m_settings.m_useLNA != settings.m_useLNA) || force) + { + reverseAPIKeys.append("useLNA"); + + if (m_dev != 0) + { + rc = (airspyhf_error) airspyhf_set_hf_lna(m_dev, settings.m_useLNA ? 1 : 0); + + if (rc != AIRSPYHF_SUCCESS) { + qCritical("AirspyHFInput::applySettings: could not set LNA to %d", settings.m_useLNA ? 1 : 0); + } else { + qDebug("AirspyHFInput::applySettings: set LNA to %d", settings.m_useLNA ? 1 : 0); + } + } + } + + if ((m_settings.m_attenuatorSteps != settings.m_attenuatorSteps) || force) + { + reverseAPIKeys.append("attenuatorSteps"); + + if (m_dev != 0) + { + rc = (airspyhf_error) airspyhf_set_hf_att(m_dev, settings.m_attenuatorSteps); + + if (rc != AIRSPYHF_SUCCESS) { + qCritical("AirspyHFInput::applySettings: could not set attenuator to %d dB", settings.m_attenuatorSteps * 6); + } else { + qDebug("AirspyHFInput::applySettings: set attenuator to %d dB", settings.m_attenuatorSteps * 6); + } + } + } + if (forwardChange && (sampleRateIndex >= 0)) { int sampleRate = m_sampleRates[sampleRateIndex]/(1<getReverseApiDeviceIndex(); } + if (deviceSettingsKeys.contains("useAGC")) { + settings.m_useAGC = response.getAirspyHfSettings()->getUseAgc(); + } + if (deviceSettingsKeys.contains("agcHigh")) { + settings.m_agcHigh = response.getAirspyHfSettings()->getAgcHigh(); + } + if (deviceSettingsKeys.contains("useDSP")) { + settings.m_useDSP = response.getAirspyHfSettings()->getUseDsp(); + } + if (deviceSettingsKeys.contains("useLNA")) { + settings.m_useLNA = response.getAirspyHfSettings()->getUseLna(); + } + if (deviceSettingsKeys.contains("attenuatorSteps")) { + settings.m_attenuatorSteps = response.getAirspyHfSettings()->getAttenuatorSteps(); + } MsgConfigureAirspyHF *msg = MsgConfigureAirspyHF::create(settings, force); m_inputMessageQueue.push(msg); @@ -624,6 +735,11 @@ void AirspyHFInput::webapiFormatDeviceSettings(SWGSDRangel::SWGDeviceSettings& r response.getAirspyHfSettings()->setReverseApiPort(settings.m_reverseAPIPort); response.getAirspyHfSettings()->setReverseApiDeviceIndex(settings.m_reverseAPIDeviceIndex); + response.getAirspyHfSettings()->setUseAgc(settings.m_useAGC ? 1 : 0); + response.getAirspyHfSettings()->setUseDsp(settings.m_useDSP ? 1 : 0); + response.getAirspyHfSettings()->setUseLna(settings.m_useLNA ? 1 : 0); + response.getAirspyHfSettings()->setAgcHigh(settings.m_agcHigh ? 1 : 0); + response.getAirspyHfSettings()->setAttenuatorSteps(settings.m_attenuatorSteps); } void AirspyHFInput::webapiFormatDeviceReport(SWGSDRangel::SWGDeviceReport& response) @@ -710,6 +826,21 @@ void AirspyHFInput::webapiReverseSendSettings(QList& deviceSettingsKeys if (deviceSettingsKeys.contains("fileRecordName") || force) { swgAirspyHFSettings->setFileRecordName(new QString(settings.m_fileRecordName)); } + if (deviceSettingsKeys.contains("useAGC")) { + swgAirspyHFSettings->setUseAgc(settings.m_useAGC ? 1 : 0); + } + if (deviceSettingsKeys.contains("agcHigh")) { + swgAirspyHFSettings->setAgcHigh(settings.m_agcHigh ? 1 : 0); + } + if (deviceSettingsKeys.contains("useDSP")) { + swgAirspyHFSettings->setUseDsp(settings.m_useDSP ? 1 : 0); + } + if (deviceSettingsKeys.contains("useLNA")) { + swgAirspyHFSettings->setUseLna(settings.m_useLNA ? 1 : 0); + } + if (deviceSettingsKeys.contains("attenuatorSteps")) { + swgAirspyHFSettings->setAttenuatorSteps(settings.m_attenuatorSteps); + } QString deviceSettingsURL = QString("http://%1:%2/sdrangel/deviceset/%3/device/settings") .arg(settings.m_reverseAPIAddress) diff --git a/plugins/samplesource/airspyhf/airspyhfsettings.cpp b/plugins/samplesource/airspyhf/airspyhfsettings.cpp index 77f96f383..4839db191 100644 --- a/plugins/samplesource/airspyhf/airspyhfsettings.cpp +++ b/plugins/samplesource/airspyhf/airspyhfsettings.cpp @@ -38,6 +38,11 @@ void AirspyHFSettings::resetToDefaults() m_reverseAPIAddress = "127.0.0.1"; m_reverseAPIPort = 8888; m_reverseAPIDeviceIndex = 0; + m_useDSP = true; + m_useAGC = false; + m_agcHigh = false; + m_useLNA = false; + m_attenuatorSteps = 0; } QByteArray AirspyHFSettings::serialize() const @@ -54,6 +59,11 @@ QByteArray AirspyHFSettings::serialize() const s.writeString(11, m_reverseAPIAddress); s.writeU32(12, m_reverseAPIPort); s.writeU32(13, m_reverseAPIDeviceIndex); + s.writeBool(14, m_useDSP); + s.writeBool(15, m_useAGC); + s.writeBool(16, m_agcHigh); + s.writeBool(17, m_useLNA); + s.writeU32(18, m_attenuatorSteps); return s.final(); } @@ -93,6 +103,12 @@ bool AirspyHFSettings::deserialize(const QByteArray& data) d.readU32(13, &uintval, 0); m_reverseAPIDeviceIndex = uintval > 99 ? 99 : uintval; + d.readBool(14, &m_useDSP, true); + d.readBool(15, &m_useAGC, false); + d.readBool(16, &m_agcHigh, false); + d.readBool(17, &m_useLNA, false); + d.readU32(18, &m_attenuatorSteps, 0); + return true; } else diff --git a/plugins/samplesource/airspyhf/airspyhfsettings.h b/plugins/samplesource/airspyhf/airspyhfsettings.h index a29e083af..bf4582e7e 100644 --- a/plugins/samplesource/airspyhf/airspyhfsettings.h +++ b/plugins/samplesource/airspyhf/airspyhfsettings.h @@ -33,6 +33,11 @@ struct AirspyHFSettings QString m_reverseAPIAddress; uint16_t m_reverseAPIPort; uint16_t m_reverseAPIDeviceIndex; + bool m_useDSP; + bool m_useAGC; + bool m_agcHigh; + bool m_useLNA; + quint32 m_attenuatorSteps; AirspyHFSettings(); void resetToDefaults(); diff --git a/sdrbase/resources/webapi/doc/html2/index.html b/sdrbase/resources/webapi/doc/html2/index.html index a41a9a47c..29a5573c4 100644 --- a/sdrbase/resources/webapi/doc/html2/index.html +++ b/sdrbase/resources/webapi/doc/html2/index.html @@ -1019,6 +1019,26 @@ margin-bottom: 20px; }, "reverseAPIDeviceIndex" : { "type" : "integer" + }, + "useAGC" : { + "type" : "integer", + "description" : "AGC (1 for on, 0 for off)" + }, + "agcHigh" : { + "type" : "integer", + "description" : "AGC threshold (1 for high, 0 for low)" + }, + "useDSP" : { + "type" : "integer", + "description" : "LibairspyHF DSP (1 for on, 0 for off)" + }, + "useLNA" : { + "type" : "integer", + "description" : "LNA (1 for on, 0 for off)" + }, + "attenuatorSteps" : { + "type" : "integer", + "description" : "Attenuator in number of 6 dB steps" } }, "description" : "AirspyHF" @@ -24347,7 +24367,7 @@ except ApiException as e:
- Generated 2019-01-11T14:37:54.502+01:00 + Generated 2019-01-14T01:23:06.065+01:00
diff --git a/sdrbase/resources/webapi/doc/swagger/include/AirspyHF.yaml b/sdrbase/resources/webapi/doc/swagger/include/AirspyHF.yaml index 61c383030..9c452224c 100644 --- a/sdrbase/resources/webapi/doc/swagger/include/AirspyHF.yaml +++ b/sdrbase/resources/webapi/doc/swagger/include/AirspyHF.yaml @@ -28,6 +28,21 @@ AirspyHFSettings: type: integer reverseAPIDeviceIndex: type: integer + useAGC: + description: AGC (1 for on, 0 for off) + type: integer + agcHigh: + description: AGC threshold (1 for high, 0 for low) + type: integer + useDSP: + description: LibairspyHF DSP (1 for on, 0 for off) + type: integer + useLNA: + description: LNA (1 for on, 0 for off) + type: integer + attenuatorSteps: + description: Attenuator in number of 6 dB steps + type: integer AirspyHFReport: description: AirspyHF diff --git a/swagger/sdrangel/api/swagger/include/AirspyHF.yaml b/swagger/sdrangel/api/swagger/include/AirspyHF.yaml index a6b4f28eb..6eaf34bdb 100644 --- a/swagger/sdrangel/api/swagger/include/AirspyHF.yaml +++ b/swagger/sdrangel/api/swagger/include/AirspyHF.yaml @@ -28,6 +28,21 @@ AirspyHFSettings: type: integer reverseAPIDeviceIndex: type: integer + useAGC: + description: AGC (1 for on, 0 for off) + type: integer + agcHigh: + description: AGC threshold (1 for high, 0 for low) + type: integer + useDSP: + description: LibairspyHF DSP (1 for on, 0 for off) + type: integer + useLNA: + description: LNA (1 for on, 0 for off) + type: integer + attenuatorSteps: + description: Attenuator in number of 6 dB steps + type: integer AirspyHFReport: description: AirspyHF diff --git a/swagger/sdrangel/code/html2/index.html b/swagger/sdrangel/code/html2/index.html index a41a9a47c..29a5573c4 100644 --- a/swagger/sdrangel/code/html2/index.html +++ b/swagger/sdrangel/code/html2/index.html @@ -1019,6 +1019,26 @@ margin-bottom: 20px; }, "reverseAPIDeviceIndex" : { "type" : "integer" + }, + "useAGC" : { + "type" : "integer", + "description" : "AGC (1 for on, 0 for off)" + }, + "agcHigh" : { + "type" : "integer", + "description" : "AGC threshold (1 for high, 0 for low)" + }, + "useDSP" : { + "type" : "integer", + "description" : "LibairspyHF DSP (1 for on, 0 for off)" + }, + "useLNA" : { + "type" : "integer", + "description" : "LNA (1 for on, 0 for off)" + }, + "attenuatorSteps" : { + "type" : "integer", + "description" : "Attenuator in number of 6 dB steps" } }, "description" : "AirspyHF" @@ -24347,7 +24367,7 @@ except ApiException as e:
- Generated 2019-01-11T14:37:54.502+01:00 + Generated 2019-01-14T01:23:06.065+01:00
diff --git a/swagger/sdrangel/code/qt5/client/SWGAirspyHFSettings.cpp b/swagger/sdrangel/code/qt5/client/SWGAirspyHFSettings.cpp index 0b016cb2d..39f600f02 100644 --- a/swagger/sdrangel/code/qt5/client/SWGAirspyHFSettings.cpp +++ b/swagger/sdrangel/code/qt5/client/SWGAirspyHFSettings.cpp @@ -52,6 +52,16 @@ SWGAirspyHFSettings::SWGAirspyHFSettings() { m_reverse_api_port_isSet = false; reverse_api_device_index = 0; m_reverse_api_device_index_isSet = false; + use_agc = 0; + m_use_agc_isSet = false; + agc_high = 0; + m_agc_high_isSet = false; + use_dsp = 0; + m_use_dsp_isSet = false; + use_lna = 0; + m_use_lna_isSet = false; + attenuator_steps = 0; + m_attenuator_steps_isSet = false; } SWGAirspyHFSettings::~SWGAirspyHFSettings() { @@ -84,6 +94,16 @@ SWGAirspyHFSettings::init() { m_reverse_api_port_isSet = false; reverse_api_device_index = 0; m_reverse_api_device_index_isSet = false; + use_agc = 0; + m_use_agc_isSet = false; + agc_high = 0; + m_agc_high_isSet = false; + use_dsp = 0; + m_use_dsp_isSet = false; + use_lna = 0; + m_use_lna_isSet = false; + attenuator_steps = 0; + m_attenuator_steps_isSet = false; } void @@ -104,6 +124,11 @@ SWGAirspyHFSettings::cleanup() { } + + + + + } SWGAirspyHFSettings* @@ -141,6 +166,16 @@ SWGAirspyHFSettings::fromJsonObject(QJsonObject &pJson) { ::SWGSDRangel::setValue(&reverse_api_device_index, pJson["reverseAPIDeviceIndex"], "qint32", ""); + ::SWGSDRangel::setValue(&use_agc, pJson["useAGC"], "qint32", ""); + + ::SWGSDRangel::setValue(&agc_high, pJson["agcHigh"], "qint32", ""); + + ::SWGSDRangel::setValue(&use_dsp, pJson["useDSP"], "qint32", ""); + + ::SWGSDRangel::setValue(&use_lna, pJson["useLNA"], "qint32", ""); + + ::SWGSDRangel::setValue(&attenuator_steps, pJson["attenuatorSteps"], "qint32", ""); + } QString @@ -193,6 +228,21 @@ SWGAirspyHFSettings::asJsonObject() { if(m_reverse_api_device_index_isSet){ obj->insert("reverseAPIDeviceIndex", QJsonValue(reverse_api_device_index)); } + if(m_use_agc_isSet){ + obj->insert("useAGC", QJsonValue(use_agc)); + } + if(m_agc_high_isSet){ + obj->insert("agcHigh", QJsonValue(agc_high)); + } + if(m_use_dsp_isSet){ + obj->insert("useDSP", QJsonValue(use_dsp)); + } + if(m_use_lna_isSet){ + obj->insert("useLNA", QJsonValue(use_lna)); + } + if(m_attenuator_steps_isSet){ + obj->insert("attenuatorSteps", QJsonValue(attenuator_steps)); + } return obj; } @@ -317,6 +367,56 @@ SWGAirspyHFSettings::setReverseApiDeviceIndex(qint32 reverse_api_device_index) { this->m_reverse_api_device_index_isSet = true; } +qint32 +SWGAirspyHFSettings::getUseAgc() { + return use_agc; +} +void +SWGAirspyHFSettings::setUseAgc(qint32 use_agc) { + this->use_agc = use_agc; + this->m_use_agc_isSet = true; +} + +qint32 +SWGAirspyHFSettings::getAgcHigh() { + return agc_high; +} +void +SWGAirspyHFSettings::setAgcHigh(qint32 agc_high) { + this->agc_high = agc_high; + this->m_agc_high_isSet = true; +} + +qint32 +SWGAirspyHFSettings::getUseDsp() { + return use_dsp; +} +void +SWGAirspyHFSettings::setUseDsp(qint32 use_dsp) { + this->use_dsp = use_dsp; + this->m_use_dsp_isSet = true; +} + +qint32 +SWGAirspyHFSettings::getUseLna() { + return use_lna; +} +void +SWGAirspyHFSettings::setUseLna(qint32 use_lna) { + this->use_lna = use_lna; + this->m_use_lna_isSet = true; +} + +qint32 +SWGAirspyHFSettings::getAttenuatorSteps() { + return attenuator_steps; +} +void +SWGAirspyHFSettings::setAttenuatorSteps(qint32 attenuator_steps) { + this->attenuator_steps = attenuator_steps; + this->m_attenuator_steps_isSet = true; +} + bool SWGAirspyHFSettings::isSet(){ @@ -334,6 +434,11 @@ SWGAirspyHFSettings::isSet(){ if(reverse_api_address != nullptr && *reverse_api_address != QString("")){ isObjectUpdated = true; break;} if(m_reverse_api_port_isSet){ isObjectUpdated = true; break;} if(m_reverse_api_device_index_isSet){ isObjectUpdated = true; break;} + if(m_use_agc_isSet){ isObjectUpdated = true; break;} + if(m_agc_high_isSet){ isObjectUpdated = true; break;} + if(m_use_dsp_isSet){ isObjectUpdated = true; break;} + if(m_use_lna_isSet){ isObjectUpdated = true; break;} + if(m_attenuator_steps_isSet){ isObjectUpdated = true; break;} }while(false); return isObjectUpdated; } diff --git a/swagger/sdrangel/code/qt5/client/SWGAirspyHFSettings.h b/swagger/sdrangel/code/qt5/client/SWGAirspyHFSettings.h index 63e8b3ebc..c7e6466ff 100644 --- a/swagger/sdrangel/code/qt5/client/SWGAirspyHFSettings.h +++ b/swagger/sdrangel/code/qt5/client/SWGAirspyHFSettings.h @@ -78,6 +78,21 @@ public: qint32 getReverseApiDeviceIndex(); void setReverseApiDeviceIndex(qint32 reverse_api_device_index); + qint32 getUseAgc(); + void setUseAgc(qint32 use_agc); + + qint32 getAgcHigh(); + void setAgcHigh(qint32 agc_high); + + qint32 getUseDsp(); + void setUseDsp(qint32 use_dsp); + + qint32 getUseLna(); + void setUseLna(qint32 use_lna); + + qint32 getAttenuatorSteps(); + void setAttenuatorSteps(qint32 attenuator_steps); + virtual bool isSet() override; @@ -118,6 +133,21 @@ private: qint32 reverse_api_device_index; bool m_reverse_api_device_index_isSet; + qint32 use_agc; + bool m_use_agc_isSet; + + qint32 agc_high; + bool m_agc_high_isSet; + + qint32 use_dsp; + bool m_use_dsp_isSet; + + qint32 use_lna; + bool m_use_lna_isSet; + + qint32 attenuator_steps; + bool m_attenuator_steps_isSet; + }; }