diff --git a/sdrbase/resources/webapi/doc/swagger/include/LocalSink.yaml b/sdrbase/resources/webapi/doc/swagger/include/LocalSink.yaml index a5c857493..63896856a 100644 --- a/sdrbase/resources/webapi/doc/swagger/include/LocalSink.yaml +++ b/sdrbase/resources/webapi/doc/swagger/include/LocalSink.yaml @@ -12,6 +12,9 @@ LocalSinkSettings: type: integer filterChainHash: type: integer + play: + description: boolean (1 to play, 0 to stop) + type: integer streamIndex: description: MIMO channel. Not relevant when connected to SI (single Rx). type: integer diff --git a/sdrbase/resources/webapi/doc/swagger/include/LocalSource.yaml b/sdrbase/resources/webapi/doc/swagger/include/LocalSource.yaml index f62c9cf7e..2b2e462ed 100644 --- a/sdrbase/resources/webapi/doc/swagger/include/LocalSource.yaml +++ b/sdrbase/resources/webapi/doc/swagger/include/LocalSource.yaml @@ -12,6 +12,9 @@ LocalSourceSettings: type: integer filterChainHash: type: integer + play: + description: boolean (1 to play, 0 to stop) + type: integer streamIndex: description: MIMO channel. Not relevant when connected to SI (single Rx). type: integer diff --git a/swagger/sdrangel/api/swagger/include/LocalSink.yaml b/swagger/sdrangel/api/swagger/include/LocalSink.yaml index a5c857493..63896856a 100644 --- a/swagger/sdrangel/api/swagger/include/LocalSink.yaml +++ b/swagger/sdrangel/api/swagger/include/LocalSink.yaml @@ -12,6 +12,9 @@ LocalSinkSettings: type: integer filterChainHash: type: integer + play: + description: boolean (1 to play, 0 to stop) + type: integer streamIndex: description: MIMO channel. Not relevant when connected to SI (single Rx). type: integer diff --git a/swagger/sdrangel/api/swagger/include/LocalSource.yaml b/swagger/sdrangel/api/swagger/include/LocalSource.yaml index f62c9cf7e..2b2e462ed 100644 --- a/swagger/sdrangel/api/swagger/include/LocalSource.yaml +++ b/swagger/sdrangel/api/swagger/include/LocalSource.yaml @@ -12,6 +12,9 @@ LocalSourceSettings: type: integer filterChainHash: type: integer + play: + description: boolean (1 to play, 0 to stop) + type: integer streamIndex: description: MIMO channel. Not relevant when connected to SI (single Rx). type: integer diff --git a/swagger/sdrangel/code/qt5/client/SWGHttpRequest.cpp b/swagger/sdrangel/code/qt5/client/SWGHttpRequest.cpp index e89f0cae2..6f72adc6f 100644 --- a/swagger/sdrangel/code/qt5/client/SWGHttpRequest.cpp +++ b/swagger/sdrangel/code/qt5/client/SWGHttpRequest.cpp @@ -1,6 +1,6 @@ /** * SDRangel - * This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time --- + * This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time --- * * OpenAPI spec version: 4.11.6 * Contact: f4exb06@gmail.com diff --git a/swagger/sdrangel/code/qt5/client/SWGLocalSinkSettings.cpp b/swagger/sdrangel/code/qt5/client/SWGLocalSinkSettings.cpp index b43000dfd..1e0c8cb40 100644 --- a/swagger/sdrangel/code/qt5/client/SWGLocalSinkSettings.cpp +++ b/swagger/sdrangel/code/qt5/client/SWGLocalSinkSettings.cpp @@ -38,6 +38,8 @@ SWGLocalSinkSettings::SWGLocalSinkSettings() { m_log2_decim_isSet = false; filter_chain_hash = 0; m_filter_chain_hash_isSet = false; + play = 0; + m_play_isSet = false; stream_index = 0; m_stream_index_isSet = false; use_reverse_api = 0; @@ -68,6 +70,8 @@ SWGLocalSinkSettings::init() { m_log2_decim_isSet = false; filter_chain_hash = 0; m_filter_chain_hash_isSet = false; + play = 0; + m_play_isSet = false; stream_index = 0; m_stream_index_isSet = false; use_reverse_api = 0; @@ -93,6 +97,7 @@ SWGLocalSinkSettings::cleanup() { + if(reverse_api_address != nullptr) { delete reverse_api_address; } @@ -122,6 +127,8 @@ SWGLocalSinkSettings::fromJsonObject(QJsonObject &pJson) { ::SWGSDRangel::setValue(&filter_chain_hash, pJson["filterChainHash"], "qint32", ""); + ::SWGSDRangel::setValue(&play, pJson["play"], "qint32", ""); + ::SWGSDRangel::setValue(&stream_index, pJson["streamIndex"], "qint32", ""); ::SWGSDRangel::setValue(&use_reverse_api, pJson["useReverseAPI"], "qint32", ""); @@ -165,6 +172,9 @@ SWGLocalSinkSettings::asJsonObject() { if(m_filter_chain_hash_isSet){ obj->insert("filterChainHash", QJsonValue(filter_chain_hash)); } + if(m_play_isSet){ + obj->insert("play", QJsonValue(play)); + } if(m_stream_index_isSet){ obj->insert("streamIndex", QJsonValue(stream_index)); } @@ -237,6 +247,16 @@ SWGLocalSinkSettings::setFilterChainHash(qint32 filter_chain_hash) { this->m_filter_chain_hash_isSet = true; } +qint32 +SWGLocalSinkSettings::getPlay() { + return play; +} +void +SWGLocalSinkSettings::setPlay(qint32 play) { + this->play = play; + this->m_play_isSet = true; +} + qint32 SWGLocalSinkSettings::getStreamIndex() { return stream_index; @@ -317,6 +337,9 @@ SWGLocalSinkSettings::isSet(){ if(m_filter_chain_hash_isSet){ isObjectUpdated = true; break; } + if(m_play_isSet){ + isObjectUpdated = true; break; + } if(m_stream_index_isSet){ isObjectUpdated = true; break; } diff --git a/swagger/sdrangel/code/qt5/client/SWGLocalSinkSettings.h b/swagger/sdrangel/code/qt5/client/SWGLocalSinkSettings.h index de5181bed..88317d197 100644 --- a/swagger/sdrangel/code/qt5/client/SWGLocalSinkSettings.h +++ b/swagger/sdrangel/code/qt5/client/SWGLocalSinkSettings.h @@ -57,6 +57,9 @@ public: qint32 getFilterChainHash(); void setFilterChainHash(qint32 filter_chain_hash); + qint32 getPlay(); + void setPlay(qint32 play); + qint32 getStreamIndex(); void setStreamIndex(qint32 stream_index); @@ -94,6 +97,9 @@ private: qint32 filter_chain_hash; bool m_filter_chain_hash_isSet; + qint32 play; + bool m_play_isSet; + qint32 stream_index; bool m_stream_index_isSet; diff --git a/swagger/sdrangel/code/qt5/client/SWGLocalSourceSettings.cpp b/swagger/sdrangel/code/qt5/client/SWGLocalSourceSettings.cpp index d3e3a76de..2e5b6bf8a 100644 --- a/swagger/sdrangel/code/qt5/client/SWGLocalSourceSettings.cpp +++ b/swagger/sdrangel/code/qt5/client/SWGLocalSourceSettings.cpp @@ -38,6 +38,8 @@ SWGLocalSourceSettings::SWGLocalSourceSettings() { m_log2_interp_isSet = false; filter_chain_hash = 0; m_filter_chain_hash_isSet = false; + play = 0; + m_play_isSet = false; stream_index = 0; m_stream_index_isSet = false; use_reverse_api = 0; @@ -68,6 +70,8 @@ SWGLocalSourceSettings::init() { m_log2_interp_isSet = false; filter_chain_hash = 0; m_filter_chain_hash_isSet = false; + play = 0; + m_play_isSet = false; stream_index = 0; m_stream_index_isSet = false; use_reverse_api = 0; @@ -93,6 +97,7 @@ SWGLocalSourceSettings::cleanup() { + if(reverse_api_address != nullptr) { delete reverse_api_address; } @@ -122,6 +127,8 @@ SWGLocalSourceSettings::fromJsonObject(QJsonObject &pJson) { ::SWGSDRangel::setValue(&filter_chain_hash, pJson["filterChainHash"], "qint32", ""); + ::SWGSDRangel::setValue(&play, pJson["play"], "qint32", ""); + ::SWGSDRangel::setValue(&stream_index, pJson["streamIndex"], "qint32", ""); ::SWGSDRangel::setValue(&use_reverse_api, pJson["useReverseAPI"], "qint32", ""); @@ -165,6 +172,9 @@ SWGLocalSourceSettings::asJsonObject() { if(m_filter_chain_hash_isSet){ obj->insert("filterChainHash", QJsonValue(filter_chain_hash)); } + if(m_play_isSet){ + obj->insert("play", QJsonValue(play)); + } if(m_stream_index_isSet){ obj->insert("streamIndex", QJsonValue(stream_index)); } @@ -237,6 +247,16 @@ SWGLocalSourceSettings::setFilterChainHash(qint32 filter_chain_hash) { this->m_filter_chain_hash_isSet = true; } +qint32 +SWGLocalSourceSettings::getPlay() { + return play; +} +void +SWGLocalSourceSettings::setPlay(qint32 play) { + this->play = play; + this->m_play_isSet = true; +} + qint32 SWGLocalSourceSettings::getStreamIndex() { return stream_index; @@ -317,6 +337,9 @@ SWGLocalSourceSettings::isSet(){ if(m_filter_chain_hash_isSet){ isObjectUpdated = true; break; } + if(m_play_isSet){ + isObjectUpdated = true; break; + } if(m_stream_index_isSet){ isObjectUpdated = true; break; } diff --git a/swagger/sdrangel/code/qt5/client/SWGLocalSourceSettings.h b/swagger/sdrangel/code/qt5/client/SWGLocalSourceSettings.h index d40115bb4..694845eca 100644 --- a/swagger/sdrangel/code/qt5/client/SWGLocalSourceSettings.h +++ b/swagger/sdrangel/code/qt5/client/SWGLocalSourceSettings.h @@ -57,6 +57,9 @@ public: qint32 getFilterChainHash(); void setFilterChainHash(qint32 filter_chain_hash); + qint32 getPlay(); + void setPlay(qint32 play); + qint32 getStreamIndex(); void setStreamIndex(qint32 stream_index); @@ -94,6 +97,9 @@ private: qint32 filter_chain_hash; bool m_filter_chain_hash_isSet; + qint32 play; + bool m_play_isSet; + qint32 stream_index; bool m_stream_index_isSet;