mirror of
https://github.com/f4exb/sdrangel.git
synced 2025-05-29 13:32:26 -04:00
ChirpChat demod: API changes and fixes
This commit is contained in:
parent
dea312898d
commit
2299c09f36
@ -667,6 +667,7 @@ void ChirpChatDemod::webapiFormatChannelReport(SWGSDRangel::SWGChannelReport& re
|
|||||||
response.getChirpChatDemodReport()->setPayloadCrcStatus(m_lastMsgPayloadCRC);
|
response.getChirpChatDemodReport()->setPayloadCrcStatus(m_lastMsgPayloadCRC);
|
||||||
response.getChirpChatDemodReport()->setMessageTimestamp(new QString(m_lastMsgTimestamp));
|
response.getChirpChatDemodReport()->setMessageTimestamp(new QString(m_lastMsgTimestamp));
|
||||||
response.getChirpChatDemodReport()->setMessageString(new QString(m_lastMsgString));
|
response.getChirpChatDemodReport()->setMessageString(new QString(m_lastMsgString));
|
||||||
|
response.getChirpChatDemodReport()->setDecoding(getDemodActive() ? 1 : 0);
|
||||||
|
|
||||||
response.getChirpChatDemodReport()->setMessageBytes(new QList<QString *>);
|
response.getChirpChatDemodReport()->setMessageBytes(new QList<QString *>);
|
||||||
QList<QString *> *bytesStr = response.getChirpChatDemodReport()->getMessageBytes();
|
QList<QString *> *bytesStr = response.getChirpChatDemodReport()->getMessageBytes();
|
||||||
|
@ -3426,6 +3426,10 @@ margin-bottom: 20px;
|
|||||||
"items" : {
|
"items" : {
|
||||||
"type" : "string"
|
"type" : "string"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"decoding" : {
|
||||||
|
"type" : "integer",
|
||||||
|
"description" : "Boolean - decoding status\n * 0 - no deconding\n * 1 - decoding\n"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"description" : "ChirpChatDemod"
|
"description" : "ChirpChatDemod"
|
||||||
@ -3495,6 +3499,10 @@ margin-bottom: 20px;
|
|||||||
"type" : "integer",
|
"type" : "integer",
|
||||||
"description" : "boolean 1 to send decoded message via UDP else 0"
|
"description" : "boolean 1 to send decoded message via UDP else 0"
|
||||||
},
|
},
|
||||||
|
"udoEnabled" : {
|
||||||
|
"type" : "integer",
|
||||||
|
"description" : "Boolean - Send via UDP\n * 0 - Do not send decoded messages via UDP\n * 1 - Send decoded messages via UDP\n"
|
||||||
|
},
|
||||||
"udpAddress" : {
|
"udpAddress" : {
|
||||||
"type" : "string",
|
"type" : "string",
|
||||||
"description" : "UDP destination udpAddress"
|
"description" : "UDP destination udpAddress"
|
||||||
@ -51371,7 +51379,7 @@ except ApiException as e:
|
|||||||
</div>
|
</div>
|
||||||
<div id="generator">
|
<div id="generator">
|
||||||
<div class="content">
|
<div class="content">
|
||||||
Generated 2021-11-21T11:04:18.372+01:00
|
Generated 2021-11-22T22:28:50.413+01:00
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -88,6 +88,12 @@ ChirpChatDemodSettings:
|
|||||||
sendViaUDP:
|
sendViaUDP:
|
||||||
description: boolean 1 to send decoded message via UDP else 0
|
description: boolean 1 to send decoded message via UDP else 0
|
||||||
type: integer
|
type: integer
|
||||||
|
udoEnabled:
|
||||||
|
type: integer
|
||||||
|
description: >
|
||||||
|
Boolean - Send via UDP
|
||||||
|
* 0 - Do not send decoded messages via UDP
|
||||||
|
* 1 - Send decoded messages via UDP
|
||||||
udpAddress:
|
udpAddress:
|
||||||
description: UDP destination udpAddress
|
description: UDP destination udpAddress
|
||||||
type: string
|
type: string
|
||||||
@ -185,3 +191,9 @@ ChirpChatDemodReport:
|
|||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
type: string
|
type: string
|
||||||
|
decoding:
|
||||||
|
type: integer
|
||||||
|
description: >
|
||||||
|
Boolean - decoding status
|
||||||
|
* 0 - no deconding
|
||||||
|
* 1 - decoding
|
||||||
|
@ -88,6 +88,12 @@ ChirpChatDemodSettings:
|
|||||||
sendViaUDP:
|
sendViaUDP:
|
||||||
description: boolean 1 to send decoded message via UDP else 0
|
description: boolean 1 to send decoded message via UDP else 0
|
||||||
type: integer
|
type: integer
|
||||||
|
udoEnabled:
|
||||||
|
type: integer
|
||||||
|
description: >
|
||||||
|
Boolean - Send via UDP
|
||||||
|
* 0 - Do not send decoded messages via UDP
|
||||||
|
* 1 - Send decoded messages via UDP
|
||||||
udpAddress:
|
udpAddress:
|
||||||
description: UDP destination udpAddress
|
description: UDP destination udpAddress
|
||||||
type: string
|
type: string
|
||||||
@ -185,3 +191,9 @@ ChirpChatDemodReport:
|
|||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
type: string
|
type: string
|
||||||
|
decoding:
|
||||||
|
type: integer
|
||||||
|
description: >
|
||||||
|
Boolean - decoding status
|
||||||
|
* 0 - no deconding
|
||||||
|
* 1 - decoding
|
||||||
|
@ -64,6 +64,8 @@ SWGChirpChatDemodReport::SWGChirpChatDemodReport() {
|
|||||||
m_message_string_isSet = false;
|
m_message_string_isSet = false;
|
||||||
message_bytes = nullptr;
|
message_bytes = nullptr;
|
||||||
m_message_bytes_isSet = false;
|
m_message_bytes_isSet = false;
|
||||||
|
decoding = 0;
|
||||||
|
m_decoding_isSet = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
SWGChirpChatDemodReport::~SWGChirpChatDemodReport() {
|
SWGChirpChatDemodReport::~SWGChirpChatDemodReport() {
|
||||||
@ -108,6 +110,8 @@ SWGChirpChatDemodReport::init() {
|
|||||||
m_message_string_isSet = false;
|
m_message_string_isSet = false;
|
||||||
message_bytes = new QList<QString*>();
|
message_bytes = new QList<QString*>();
|
||||||
m_message_bytes_isSet = false;
|
m_message_bytes_isSet = false;
|
||||||
|
decoding = 0;
|
||||||
|
m_decoding_isSet = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -140,6 +144,7 @@ SWGChirpChatDemodReport::cleanup() {
|
|||||||
}
|
}
|
||||||
delete message_bytes;
|
delete message_bytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
SWGChirpChatDemodReport*
|
SWGChirpChatDemodReport*
|
||||||
@ -189,6 +194,8 @@ SWGChirpChatDemodReport::fromJsonObject(QJsonObject &pJson) {
|
|||||||
|
|
||||||
|
|
||||||
::SWGSDRangel::setValue(&message_bytes, pJson["messageBytes"], "QList", "QString");
|
::SWGSDRangel::setValue(&message_bytes, pJson["messageBytes"], "QList", "QString");
|
||||||
|
::SWGSDRangel::setValue(&decoding, pJson["decoding"], "qint32", "");
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QString
|
QString
|
||||||
@ -259,6 +266,9 @@ SWGChirpChatDemodReport::asJsonObject() {
|
|||||||
if(message_bytes && message_bytes->size() > 0){
|
if(message_bytes && message_bytes->size() > 0){
|
||||||
toJsonArray((QList<void*>*)message_bytes, obj, "messageBytes", "QString");
|
toJsonArray((QList<void*>*)message_bytes, obj, "messageBytes", "QString");
|
||||||
}
|
}
|
||||||
|
if(m_decoding_isSet){
|
||||||
|
obj->insert("decoding", QJsonValue(decoding));
|
||||||
|
}
|
||||||
|
|
||||||
return obj;
|
return obj;
|
||||||
}
|
}
|
||||||
@ -443,6 +453,16 @@ SWGChirpChatDemodReport::setMessageBytes(QList<QString*>* message_bytes) {
|
|||||||
this->m_message_bytes_isSet = true;
|
this->m_message_bytes_isSet = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
qint32
|
||||||
|
SWGChirpChatDemodReport::getDecoding() {
|
||||||
|
return decoding;
|
||||||
|
}
|
||||||
|
void
|
||||||
|
SWGChirpChatDemodReport::setDecoding(qint32 decoding) {
|
||||||
|
this->decoding = decoding;
|
||||||
|
this->m_decoding_isSet = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
bool
|
bool
|
||||||
SWGChirpChatDemodReport::isSet(){
|
SWGChirpChatDemodReport::isSet(){
|
||||||
@ -502,6 +522,9 @@ SWGChirpChatDemodReport::isSet(){
|
|||||||
if(message_bytes && (message_bytes->size() > 0)){
|
if(message_bytes && (message_bytes->size() > 0)){
|
||||||
isObjectUpdated = true; break;
|
isObjectUpdated = true; break;
|
||||||
}
|
}
|
||||||
|
if(m_decoding_isSet){
|
||||||
|
isObjectUpdated = true; break;
|
||||||
|
}
|
||||||
}while(false);
|
}while(false);
|
||||||
return isObjectUpdated;
|
return isObjectUpdated;
|
||||||
}
|
}
|
||||||
|
@ -97,6 +97,9 @@ public:
|
|||||||
QList<QString*>* getMessageBytes();
|
QList<QString*>* getMessageBytes();
|
||||||
void setMessageBytes(QList<QString*>* message_bytes);
|
void setMessageBytes(QList<QString*>* message_bytes);
|
||||||
|
|
||||||
|
qint32 getDecoding();
|
||||||
|
void setDecoding(qint32 decoding);
|
||||||
|
|
||||||
|
|
||||||
virtual bool isSet() override;
|
virtual bool isSet() override;
|
||||||
|
|
||||||
@ -155,6 +158,9 @@ private:
|
|||||||
QList<QString*>* message_bytes;
|
QList<QString*>* message_bytes;
|
||||||
bool m_message_bytes_isSet;
|
bool m_message_bytes_isSet;
|
||||||
|
|
||||||
|
qint32 decoding;
|
||||||
|
bool m_decoding_isSet;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -60,6 +60,8 @@ SWGChirpChatDemodSettings::SWGChirpChatDemodSettings() {
|
|||||||
m_has_header_isSet = false;
|
m_has_header_isSet = false;
|
||||||
send_via_udp = 0;
|
send_via_udp = 0;
|
||||||
m_send_via_udp_isSet = false;
|
m_send_via_udp_isSet = false;
|
||||||
|
udo_enabled = 0;
|
||||||
|
m_udo_enabled_isSet = false;
|
||||||
udp_address = nullptr;
|
udp_address = nullptr;
|
||||||
m_udp_address_isSet = false;
|
m_udp_address_isSet = false;
|
||||||
udp_port = 0;
|
udp_port = 0;
|
||||||
@ -120,6 +122,8 @@ SWGChirpChatDemodSettings::init() {
|
|||||||
m_has_header_isSet = false;
|
m_has_header_isSet = false;
|
||||||
send_via_udp = 0;
|
send_via_udp = 0;
|
||||||
m_send_via_udp_isSet = false;
|
m_send_via_udp_isSet = false;
|
||||||
|
udo_enabled = 0;
|
||||||
|
m_udo_enabled_isSet = false;
|
||||||
udp_address = new QString("");
|
udp_address = new QString("");
|
||||||
m_udp_address_isSet = false;
|
m_udp_address_isSet = false;
|
||||||
udp_port = 0;
|
udp_port = 0;
|
||||||
@ -160,6 +164,7 @@ SWGChirpChatDemodSettings::cleanup() {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if(udp_address != nullptr) {
|
if(udp_address != nullptr) {
|
||||||
delete udp_address;
|
delete udp_address;
|
||||||
}
|
}
|
||||||
@ -221,6 +226,8 @@ SWGChirpChatDemodSettings::fromJsonObject(QJsonObject &pJson) {
|
|||||||
|
|
||||||
::SWGSDRangel::setValue(&send_via_udp, pJson["sendViaUDP"], "qint32", "");
|
::SWGSDRangel::setValue(&send_via_udp, pJson["sendViaUDP"], "qint32", "");
|
||||||
|
|
||||||
|
::SWGSDRangel::setValue(&udo_enabled, pJson["udoEnabled"], "qint32", "");
|
||||||
|
|
||||||
::SWGSDRangel::setValue(&udp_address, pJson["udpAddress"], "QString", "QString");
|
::SWGSDRangel::setValue(&udp_address, pJson["udpAddress"], "QString", "QString");
|
||||||
|
|
||||||
::SWGSDRangel::setValue(&udp_port, pJson["udpPort"], "qint32", "");
|
::SWGSDRangel::setValue(&udp_port, pJson["udpPort"], "qint32", "");
|
||||||
@ -305,6 +312,9 @@ SWGChirpChatDemodSettings::asJsonObject() {
|
|||||||
if(m_send_via_udp_isSet){
|
if(m_send_via_udp_isSet){
|
||||||
obj->insert("sendViaUDP", QJsonValue(send_via_udp));
|
obj->insert("sendViaUDP", QJsonValue(send_via_udp));
|
||||||
}
|
}
|
||||||
|
if(m_udo_enabled_isSet){
|
||||||
|
obj->insert("udoEnabled", QJsonValue(udo_enabled));
|
||||||
|
}
|
||||||
if(udp_address != nullptr && *udp_address != QString("")){
|
if(udp_address != nullptr && *udp_address != QString("")){
|
||||||
toJsonValue(QString("udpAddress"), udp_address, obj, QString("QString"));
|
toJsonValue(QString("udpAddress"), udp_address, obj, QString("QString"));
|
||||||
}
|
}
|
||||||
@ -499,6 +509,16 @@ SWGChirpChatDemodSettings::setSendViaUdp(qint32 send_via_udp) {
|
|||||||
this->m_send_via_udp_isSet = true;
|
this->m_send_via_udp_isSet = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
qint32
|
||||||
|
SWGChirpChatDemodSettings::getUdoEnabled() {
|
||||||
|
return udo_enabled;
|
||||||
|
}
|
||||||
|
void
|
||||||
|
SWGChirpChatDemodSettings::setUdoEnabled(qint32 udo_enabled) {
|
||||||
|
this->udo_enabled = udo_enabled;
|
||||||
|
this->m_udo_enabled_isSet = true;
|
||||||
|
}
|
||||||
|
|
||||||
QString*
|
QString*
|
||||||
SWGChirpChatDemodSettings::getUdpAddress() {
|
SWGChirpChatDemodSettings::getUdpAddress() {
|
||||||
return udp_address;
|
return udp_address;
|
||||||
@ -652,6 +672,9 @@ SWGChirpChatDemodSettings::isSet(){
|
|||||||
if(m_send_via_udp_isSet){
|
if(m_send_via_udp_isSet){
|
||||||
isObjectUpdated = true; break;
|
isObjectUpdated = true; break;
|
||||||
}
|
}
|
||||||
|
if(m_udo_enabled_isSet){
|
||||||
|
isObjectUpdated = true; break;
|
||||||
|
}
|
||||||
if(udp_address && *udp_address != QString("")){
|
if(udp_address && *udp_address != QString("")){
|
||||||
isObjectUpdated = true; break;
|
isObjectUpdated = true; break;
|
||||||
}
|
}
|
||||||
|
@ -90,6 +90,9 @@ public:
|
|||||||
qint32 getSendViaUdp();
|
qint32 getSendViaUdp();
|
||||||
void setSendViaUdp(qint32 send_via_udp);
|
void setSendViaUdp(qint32 send_via_udp);
|
||||||
|
|
||||||
|
qint32 getUdoEnabled();
|
||||||
|
void setUdoEnabled(qint32 udo_enabled);
|
||||||
|
|
||||||
QString* getUdpAddress();
|
QString* getUdpAddress();
|
||||||
void setUdpAddress(QString* udp_address);
|
void setUdpAddress(QString* udp_address);
|
||||||
|
|
||||||
@ -172,6 +175,9 @@ private:
|
|||||||
qint32 send_via_udp;
|
qint32 send_via_udp;
|
||||||
bool m_send_via_udp_isSet;
|
bool m_send_via_udp_isSet;
|
||||||
|
|
||||||
|
qint32 udo_enabled;
|
||||||
|
bool m_udo_enabled_isSet;
|
||||||
|
|
||||||
QString* udp_address;
|
QString* udp_address;
|
||||||
bool m_udp_address_isSet;
|
bool m_udp_address_isSet;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user