1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-12-23 01:55:48 -05:00

Aaronia RTSA: Fixed API device settings PUT and PATCH

This commit is contained in:
f4exb 2023-05-23 13:52:06 +02:00
parent 2b6f033b89
commit 1934867ccd
2 changed files with 15 additions and 1 deletions

View File

@ -4830,7 +4830,17 @@ bool WebAPIRequestMapper::getDeviceSettings(
extractKeys(settingsJsonObject, deviceSettingsKeys);
qDebug() << "WebAPIRequestMapper::getDeviceSettings: deviceSettingsKeys: " << deviceSettingsKeys;
if (deviceSettingsKey == "airspySettings")
if (deviceSettingsKey == "aaroniaRTSASettings")
{
deviceSettings->setAaroniaRtsaSettings(new SWGSDRangel::SWGAaroniaRTSASettings());
deviceSettings->getAaroniaRtsaSettings()->fromJsonObject(settingsJsonObject);
}
else if (deviceSettingsKey == "aaroniaRTSAOutputSettings")
{
deviceSettings->setAaroniaRtsaOutputSettings(new SWGSDRangel::SWGAaroniaRTSAOutputSettings());
deviceSettings->getAaroniaRtsaOutputSettings()->fromJsonObject(settingsJsonObject);
}
else if (deviceSettingsKey == "airspySettings")
{
deviceSettings->setAirspySettings(new SWGSDRangel::SWGAirspySettings());
deviceSettings->getAirspySettings()->fromJsonObject(settingsJsonObject);

View File

@ -90,6 +90,8 @@ const QMap<QString, QString> WebAPIUtils::m_channelURIToSettingsKey = {
};
const QMap<QString, QString> WebAPIUtils::m_deviceIdToSettingsKey = {
{"sdrangel.samplesource.aaroniartsasource", "aaroniaRTSASettings"},
{"sdrangel.samplesink.aaroniartsaoutput", "aaroniaRTSAOutputSettings"},
{"sdrangel.samplesource.airspy", "airspySettings"},
{"sdrangel.samplesource.airspyhf", "airspyHFSettings"},
{"sdrangel.samplesource.audioinput", "audioInputSettings"},
@ -209,6 +211,7 @@ const QMap<QString, QString> WebAPIUtils::m_channelTypeToActionsKey = {
};
const QMap<QString, QString> WebAPIUtils::m_sourceDeviceHwIdToSettingsKey = {
{"AaroniaRTSA", "aaroniaRTSASettings"},
{"Airspy", "airspySettings"},
{"AirspyHF", "airspyHFSettings"},
{"AudioInput", "audioInputSettings"},
@ -260,6 +263,7 @@ const QMap<QString, QString> WebAPIUtils::m_sourceDeviceHwIdToActionsKey = {
};
const QMap<QString, QString> WebAPIUtils::m_sinkDeviceHwIdToSettingsKey = {
{"AaroniaRTSAOutput", "aaroniaRTSAOutputSettings"},
{"AudioOutput", "audioOutputSettings"},
{"BladeRF1", "bladeRF1OutputSettings"},
{"BladeRF2", "bladeRF2OutputSettings"},