diff --git a/plugins/channeltx/modmeshtastic/meshtasticmod.cpp b/plugins/channeltx/modmeshtastic/meshtasticmod.cpp index d696da497..6e3f2e2c2 100644 --- a/plugins/channeltx/modmeshtastic/meshtasticmod.cpp +++ b/plugins/channeltx/modmeshtastic/meshtasticmod.cpp @@ -483,18 +483,6 @@ void MeshtasticMod::webapiUpdateChannelSettings( if (channelSettingsKeys.contains("nbParityBits")) { settings.m_nbParityBits = response.getChirpChatModSettings()->getNbParityBits(); } - if (channelSettingsKeys.contains("myCall")) { - settings.m_myCall = *response.getChirpChatModSettings()->getMyCall(); - } - if (channelSettingsKeys.contains("urCall")) { - settings.m_urCall = *response.getChirpChatModSettings()->getUrCall(); - } - if (channelSettingsKeys.contains("myLoc")) { - settings.m_myLoc = *response.getChirpChatModSettings()->getMyLoc(); - } - if (channelSettingsKeys.contains("myRpt")) { - settings.m_myRpt = *response.getChirpChatModSettings()->getMyRpt(); - } if (channelSettingsKeys.contains("textMessage")) { settings.m_textMessage = *response.getChirpChatModSettings()->getTextMessage(); } @@ -585,31 +573,6 @@ void MeshtasticMod::webapiFormatChannelSettings(SWGSDRangel::SWGChannelSettings& response.getChirpChatModSettings()->setNbParityBits(settings.m_nbParityBits); response.getChirpChatModSettings()->setHasCrc(settings.m_hasCRC ? 1 : 0); response.getChirpChatModSettings()->setHasHeader(settings.m_hasHeader ? 1 : 0); - - if (response.getChirpChatModSettings()->getMyCall()) { - *response.getChirpChatModSettings()->getMyCall() = settings.m_myCall; - } else { - response.getChirpChatModSettings()->setMyCall(new QString(settings.m_myCall)); - } - - if (response.getChirpChatModSettings()->getUrCall()) { - *response.getChirpChatModSettings()->getUrCall() = settings.m_urCall; - } else { - response.getChirpChatModSettings()->setUrCall(new QString(settings.m_urCall)); - } - - if (response.getChirpChatModSettings()->getMyLoc()) { - *response.getChirpChatModSettings()->getMyLoc() = settings.m_myLoc; - } else { - response.getChirpChatModSettings()->setMyLoc(new QString(settings.m_myLoc)); - } - - if (response.getChirpChatModSettings()->getMyRpt()) { - *response.getChirpChatModSettings()->getMyRpt() = settings.m_myRpt; - } else { - response.getChirpChatModSettings()->setMyRpt(new QString(settings.m_myRpt)); - } - response.getChirpChatModSettings()->setMessageType((int) settings.m_messageType); if (response.getChirpChatModSettings()->getTextMessage()) { @@ -796,18 +759,6 @@ void MeshtasticMod::webapiFormatChannelSettings( if (channelSettingsKeys.contains("hasHeader") || force) { swgMeshtasticModSettings->setHasHeader(settings.m_hasHeader ? 1 : 0); } - if (channelSettingsKeys.contains("myCall") || force) { - swgMeshtasticModSettings->setMyCall(new QString(settings.m_myCall)); - } - if (channelSettingsKeys.contains("urCall") || force) { - swgMeshtasticModSettings->setUrCall(new QString(settings.m_urCall)); - } - if (channelSettingsKeys.contains("myLoc") || force) { - swgMeshtasticModSettings->setMyLoc(new QString(settings.m_myLoc)); - } - if (channelSettingsKeys.contains("myRpt") || force) { - swgMeshtasticModSettings->setMyRpt(new QString(settings.m_myRpt)); - } if (channelSettingsKeys.contains("messageType") || force) { swgMeshtasticModSettings->setMessageType((int) settings.m_messageType); } diff --git a/plugins/channeltx/modmeshtastic/meshtasticmodgui.cpp b/plugins/channeltx/modmeshtastic/meshtasticmodgui.cpp index 534c8599f..80b9c1db4 100644 --- a/plugins/channeltx/modmeshtastic/meshtasticmodgui.cpp +++ b/plugins/channeltx/modmeshtastic/meshtasticmodgui.cpp @@ -348,30 +348,6 @@ void MeshtasticModGUI::on_fecParity_valueChanged(int value) applySettings(); } -void MeshtasticModGUI::on_myCall_editingFinished() -{ - m_settings.m_myCall = ui->myCall->text(); - applySettings(); -} - -void MeshtasticModGUI::on_urCall_editingFinished() -{ - m_settings.m_urCall = ui->urCall->text(); - applySettings(); -} - -void MeshtasticModGUI::on_myLocator_editingFinished() -{ - m_settings.m_myLoc = ui->myLocator->text(); - applySettings(); -} - -void MeshtasticModGUI::on_report_editingFinished() -{ - m_settings.m_myRpt = ui->report->text(); - applySettings(); -} - void MeshtasticModGUI::on_resetMessages_clicked(bool checked) { (void) checked; @@ -681,10 +657,6 @@ void MeshtasticModGUI::displaySettings() ui->fecParityText->setText(tr("%1").arg(m_settings.m_nbParityBits)); ui->crc->setChecked(m_settings.m_hasCRC); ui->header->setChecked(m_settings.m_hasHeader); - ui->myCall->setText(m_settings.m_myCall); - ui->urCall->setText(m_settings.m_urCall); - ui->myLocator->setText(m_settings.m_myLoc); - ui->report->setText(m_settings.m_myRpt); ui->repeatMessage->setValue(m_settings.m_messageRepeat); ui->repeatText->setText(tr("%1").arg(m_settings.m_messageRepeat)); ui->msgType->setCurrentIndex((int) m_settings.m_messageType); @@ -776,10 +748,6 @@ void MeshtasticModGUI::makeUIConnections() QObject::connect(ui->syncWord, &QLineEdit::editingFinished, this, &MeshtasticModGUI::on_syncWord_editingFinished); QObject::connect(ui->channelMute, &QToolButton::toggled, this, &MeshtasticModGUI::on_channelMute_toggled); QObject::connect(ui->fecParity, &QDial::valueChanged, this, &MeshtasticModGUI::on_fecParity_valueChanged); - QObject::connect(ui->myCall, &QLineEdit::editingFinished, this, &MeshtasticModGUI::on_myCall_editingFinished); - QObject::connect(ui->urCall, &QLineEdit::editingFinished, this, &MeshtasticModGUI::on_urCall_editingFinished); - QObject::connect(ui->myLocator, &QLineEdit::editingFinished, this, &MeshtasticModGUI::on_myLocator_editingFinished); - QObject::connect(ui->report, &QLineEdit::editingFinished, this, &MeshtasticModGUI::on_report_editingFinished); QObject::connect(ui->resetMessages, &QPushButton::clicked, this, &MeshtasticModGUI::on_resetMessages_clicked); QObject::connect(ui->playMessage, &QPushButton::clicked, this, &MeshtasticModGUI::on_playMessage_clicked); QObject::connect(ui->repeatMessage, &QDial::valueChanged, this, &MeshtasticModGUI::on_repeatMessage_valueChanged); diff --git a/plugins/channeltx/modmeshtastic/meshtasticmodgui.h b/plugins/channeltx/modmeshtastic/meshtasticmodgui.h index 101005134..af7260a68 100644 --- a/plugins/channeltx/modmeshtastic/meshtasticmodgui.h +++ b/plugins/channeltx/modmeshtastic/meshtasticmodgui.h @@ -110,10 +110,6 @@ private slots: void on_syncWord_editingFinished(); void on_channelMute_toggled(bool checked); void on_fecParity_valueChanged(int value); - void on_myCall_editingFinished(); - void on_urCall_editingFinished(); - void on_myLocator_editingFinished(); - void on_report_editingFinished(); void on_resetMessages_clicked(bool checked); void on_playMessage_clicked(bool checked); void on_repeatMessage_valueChanged(int value); diff --git a/plugins/channeltx/modmeshtastic/meshtasticmodsettings.cpp b/plugins/channeltx/modmeshtastic/meshtasticmodsettings.cpp index bd3aa4697..f9f38393d 100644 --- a/plugins/channeltx/modmeshtastic/meshtasticmodsettings.cpp +++ b/plugins/channeltx/modmeshtastic/meshtasticmodsettings.cpp @@ -80,10 +80,6 @@ void MeshtasticModSettings::resetToDefaults() m_quietMillis = 1000; m_nbParityBits = 1; m_textMessage = "Hello LoRa"; - m_myCall = "MYCALL"; - m_urCall = "URCALL"; - m_myLoc = "AA00AA"; - m_myRpt = "59"; m_syncWord = 0x34; m_channelMute = false; m_messageRepeat = 1; @@ -144,10 +140,6 @@ QByteArray MeshtasticModSettings::serialize() const s.writeS32(31, m_nbParityBits); s.writeBool(32, m_hasCRC); s.writeBool(33, m_hasHeader); - s.writeString(40, m_myCall); - s.writeString(41, m_urCall); - s.writeString(42, m_myLoc); - s.writeString(43, m_myRpt); s.writeS32(44, m_messageRepeat); s.writeBool(50, m_useReverseAPI); s.writeString(51, m_reverseAPIAddress); @@ -207,10 +199,6 @@ bool MeshtasticModSettings::deserialize(const QByteArray& data) d.readString(28, &m_textMessage, "Hello LoRa"); d.readBlob(29, &m_bytesMessage); d.readS32(31, &m_nbParityBits, 1); - d.readString(40, &m_myCall, "MYCALL"); - d.readString(41, &m_urCall, "URCALL"); - d.readString(42, &m_myLoc, "AA00AA"); - d.readString(43, &m_myRpt, "59"); d.readS32(44, &m_messageRepeat, 1); d.readBool(50, &m_useReverseAPI, false); d.readString(51, &m_reverseAPIAddress, "127.0.0.1"); @@ -313,14 +301,6 @@ void MeshtasticModSettings::applySettings(const QStringList& settingsKeys, const m_bytesMessage = settings.m_bytesMessage; if (settingsKeys.contains("nbParityBits")) m_nbParityBits = settings.m_nbParityBits; - if (settingsKeys.contains("myCall")) - m_myCall = settings.m_myCall; - if (settingsKeys.contains("urCall")) - m_urCall = settings.m_urCall; - if (settingsKeys.contains("myLoc")) - m_myLoc = settings.m_myLoc; - if (settingsKeys.contains("myRpt")) - m_myRpt = settings.m_myRpt; if (settingsKeys.contains("messageRepeat")) m_messageRepeat = settings.m_messageRepeat; } @@ -382,14 +362,6 @@ QString MeshtasticModSettings::getDebugString(const QStringList& settingsKeys, b debug += QString("Has CRC: %1\n").arg(m_hasCRC); if (settingsKeys.contains("hasHeader") || force) debug += QString("Has Header: %1\n").arg(m_hasHeader); - if (settingsKeys.contains("myCall") || force) - debug += QString("My Call: %1\n").arg(m_myCall); - if (settingsKeys.contains("urCall") || force) - debug += QString("UR Call: %1\n").arg(m_urCall); - if (settingsKeys.contains("myLoc") || force) - debug += QString("My Loc: %1\n").arg(m_myLoc); - if (settingsKeys.contains("myRpt") || force) - debug += QString("My Rpt: %1\n").arg(m_myRpt); if (settingsKeys.contains("messageRepeat") || force) debug += QString("Message Repeat: %1\n").arg(m_messageRepeat); return debug; diff --git a/plugins/channeltx/modmeshtastic/meshtasticmodsettings.h b/plugins/channeltx/modmeshtastic/meshtasticmodsettings.h index dd7a15f86..088d86658 100644 --- a/plugins/channeltx/modmeshtastic/meshtasticmodsettings.h +++ b/plugins/channeltx/modmeshtastic/meshtasticmodsettings.h @@ -65,10 +65,6 @@ struct MeshtasticModSettings unsigned char m_syncWord; bool m_channelMute; static const CodingScheme m_codingScheme; - QString m_myCall; //!< QSO mode: my callsign - QString m_urCall; //!< QSO mode: your callsign - QString m_myLoc; //!< QSO mode: my locator - QString m_myRpt; //!< QSO mode: my report static const MessageType m_messageType; QString m_textMessage; QByteArray m_bytesMessage;