Added configuration option for sending SNR in HB ACKs instead of disabling completely
This commit is contained in:
parent
57890e55c1
commit
dd3efd15a1
@ -645,6 +645,7 @@ private:
|
|||||||
bool autoreply_confirmation_;
|
bool autoreply_confirmation_;
|
||||||
bool heartbeat_anywhere_;
|
bool heartbeat_anywhere_;
|
||||||
bool heartbeat_qso_pause_;
|
bool heartbeat_qso_pause_;
|
||||||
|
bool heartbeat_ack_snr_;
|
||||||
bool relay_disabled_;
|
bool relay_disabled_;
|
||||||
bool monitor_off_at_startup_;
|
bool monitor_off_at_startup_;
|
||||||
bool monitor_last_used_;
|
bool monitor_last_used_;
|
||||||
@ -812,6 +813,7 @@ bool Configuration::autoreply_on_at_startup () const {
|
|||||||
bool Configuration::autoreply_confirmation() const { return m_->autoreply_confirmation_; }
|
bool Configuration::autoreply_confirmation() const { return m_->autoreply_confirmation_; }
|
||||||
bool Configuration::heartbeat_anywhere() const { return m_->heartbeat_anywhere_;}
|
bool Configuration::heartbeat_anywhere() const { return m_->heartbeat_anywhere_;}
|
||||||
bool Configuration::heartbeat_qso_pause() const { return m_->heartbeat_qso_pause_;}
|
bool Configuration::heartbeat_qso_pause() const { return m_->heartbeat_qso_pause_;}
|
||||||
|
bool Configuration::heartbeat_ack_snr() const { return m_->heartbeat_ack_snr_;}
|
||||||
bool Configuration::relay_off() const { return m_->relay_disabled_; }
|
bool Configuration::relay_off() const { return m_->relay_disabled_; }
|
||||||
bool Configuration::monitor_off_at_startup () const {return m_->monitor_off_at_startup_;}
|
bool Configuration::monitor_off_at_startup () const {return m_->monitor_off_at_startup_;}
|
||||||
bool Configuration::monitor_last_used () const {return m_->rig_is_dummy_ || m_->monitor_last_used_;}
|
bool Configuration::monitor_last_used () const {return m_->rig_is_dummy_ || m_->monitor_last_used_;}
|
||||||
@ -1543,6 +1545,7 @@ void Configuration::impl::initialize_models ()
|
|||||||
ui_->autoreply_confirmation_check_box->setChecked (autoreply_confirmation_);
|
ui_->autoreply_confirmation_check_box->setChecked (autoreply_confirmation_);
|
||||||
ui_->heartbeat_anywhere_check_box->setChecked(heartbeat_anywhere_);
|
ui_->heartbeat_anywhere_check_box->setChecked(heartbeat_anywhere_);
|
||||||
ui_->heartbeat_qso_pause_check_box->setChecked(heartbeat_qso_pause_);
|
ui_->heartbeat_qso_pause_check_box->setChecked(heartbeat_qso_pause_);
|
||||||
|
ui_->heartbeat_ack_snr_check_box->setChecked(heartbeat_ack_snr_);
|
||||||
ui_->relay_disabled_check_box->setChecked(relay_disabled_);
|
ui_->relay_disabled_check_box->setChecked(relay_disabled_);
|
||||||
ui_->monitor_off_check_box->setChecked (monitor_off_at_startup_);
|
ui_->monitor_off_check_box->setChecked (monitor_off_at_startup_);
|
||||||
ui_->monitor_last_used_check_box->setChecked (monitor_last_used_);
|
ui_->monitor_last_used_check_box->setChecked (monitor_last_used_);
|
||||||
@ -1963,6 +1966,7 @@ void Configuration::impl::read_settings ()
|
|||||||
autoreply_confirmation_ = settings_->value ("AutoreplyConfirmation", false).toBool ();
|
autoreply_confirmation_ = settings_->value ("AutoreplyConfirmation", false).toBool ();
|
||||||
heartbeat_anywhere_ = settings_->value("BeaconAnywhere", false).toBool();
|
heartbeat_anywhere_ = settings_->value("BeaconAnywhere", false).toBool();
|
||||||
heartbeat_qso_pause_ = settings_->value("HeartbeatQSOPause", true).toBool();
|
heartbeat_qso_pause_ = settings_->value("HeartbeatQSOPause", true).toBool();
|
||||||
|
heartbeat_ack_snr_ = settings_->value("HeartbeatAckSNR", false).toBool();
|
||||||
relay_disabled_ = settings_->value ("RelayOFF", false).toBool ();
|
relay_disabled_ = settings_->value ("RelayOFF", false).toBool ();
|
||||||
monitor_off_at_startup_ = settings_->value ("MonitorOFF", false).toBool ();
|
monitor_off_at_startup_ = settings_->value ("MonitorOFF", false).toBool ();
|
||||||
monitor_last_used_ = settings_->value ("MonitorLastUsed", false).toBool ();
|
monitor_last_used_ = settings_->value ("MonitorLastUsed", false).toBool ();
|
||||||
@ -2178,6 +2182,7 @@ void Configuration::impl::write_settings ()
|
|||||||
settings_->setValue ("AutoreplyConfirmation", autoreply_confirmation_);
|
settings_->setValue ("AutoreplyConfirmation", autoreply_confirmation_);
|
||||||
settings_->setValue ("BeaconAnywhere", heartbeat_anywhere_);
|
settings_->setValue ("BeaconAnywhere", heartbeat_anywhere_);
|
||||||
settings_->setValue ("HeartbeatQSOPause", heartbeat_qso_pause_);
|
settings_->setValue ("HeartbeatQSOPause", heartbeat_qso_pause_);
|
||||||
|
settings_->setValue ("HeartbeatAckSNR", heartbeat_ack_snr_);
|
||||||
settings_->setValue ("RelayOFF", relay_disabled_);
|
settings_->setValue ("RelayOFF", relay_disabled_);
|
||||||
settings_->setValue ("MonitorOFF", monitor_off_at_startup_);
|
settings_->setValue ("MonitorOFF", monitor_off_at_startup_);
|
||||||
settings_->setValue ("MonitorLastUsed", monitor_last_used_);
|
settings_->setValue ("MonitorLastUsed", monitor_last_used_);
|
||||||
@ -2813,6 +2818,7 @@ void Configuration::impl::accept ()
|
|||||||
autoreply_confirmation_ = ui_->autoreply_confirmation_check_box->isChecked ();
|
autoreply_confirmation_ = ui_->autoreply_confirmation_check_box->isChecked ();
|
||||||
heartbeat_anywhere_ = ui_->heartbeat_anywhere_check_box->isChecked();
|
heartbeat_anywhere_ = ui_->heartbeat_anywhere_check_box->isChecked();
|
||||||
heartbeat_qso_pause_ = ui_->heartbeat_qso_pause_check_box->isChecked();
|
heartbeat_qso_pause_ = ui_->heartbeat_qso_pause_check_box->isChecked();
|
||||||
|
heartbeat_ack_snr_ = ui_->heartbeat_ack_snr_check_box->isChecked();
|
||||||
relay_disabled_ = ui_->relay_disabled_check_box->isChecked();
|
relay_disabled_ = ui_->relay_disabled_check_box->isChecked();
|
||||||
monitor_off_at_startup_ = ui_->monitor_off_check_box->isChecked ();
|
monitor_off_at_startup_ = ui_->monitor_off_check_box->isChecked ();
|
||||||
monitor_last_used_ = ui_->monitor_last_used_check_box->isChecked ();
|
monitor_last_used_ = ui_->monitor_last_used_check_box->isChecked ();
|
||||||
|
@ -143,6 +143,7 @@ public:
|
|||||||
bool autoreply_confirmation () const;
|
bool autoreply_confirmation () const;
|
||||||
bool heartbeat_anywhere() const;
|
bool heartbeat_anywhere() const;
|
||||||
bool heartbeat_qso_pause() const;
|
bool heartbeat_qso_pause() const;
|
||||||
|
bool heartbeat_ack_snr() const;
|
||||||
bool relay_off() const;
|
bool relay_off() const;
|
||||||
bool monitor_off_at_startup () const;
|
bool monitor_off_at_startup () const;
|
||||||
bool monitor_last_used () const;
|
bool monitor_last_used () const;
|
||||||
|
@ -206,7 +206,9 @@
|
|||||||
</item>
|
</item>
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
<widget class="QLabel" name="label_28">
|
<widget class="QLabel" name="label_28">
|
||||||
<property name="visible"><bool>false</bool></property>
|
<property name="visible">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>HB Message:</string>
|
<string>HB Message:</string>
|
||||||
</property>
|
</property>
|
||||||
@ -221,7 +223,9 @@
|
|||||||
</item>
|
</item>
|
||||||
<item row="0" column="1">
|
<item row="0" column="1">
|
||||||
<widget class="QLineEdit" name="hb_message_line_edit">
|
<widget class="QLineEdit" name="hb_message_line_edit">
|
||||||
<property name="visible"><bool>false</bool></property>
|
<property name="visible">
|
||||||
|
<bool>false</bool>
|
||||||
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>HB <MYGRID4></string>
|
<string>HB <MYGRID4></string>
|
||||||
</property>
|
</property>
|
||||||
@ -870,6 +874,13 @@ text message.</string>
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QCheckBox" name="heartbeat_ack_snr_check_box">
|
||||||
|
<property name="text">
|
||||||
|
<string>Send SNR report when acknowledging heartbeats</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<layout class="QFormLayout" name="formLayout_16">
|
<layout class="QFormLayout" name="formLayout_16">
|
||||||
<property name="bottomMargin">
|
<property name="bottomMargin">
|
||||||
@ -878,7 +889,7 @@ text message.</string>
|
|||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
<widget class="QLabel" name="label_26">
|
<widget class="QLabel" name="label_26">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Never ACK heartbeats from these callsigns (comma separated):</string>
|
<string>Never acknowledge heartbeats from these callsigns (comma separated):</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
@ -8166,13 +8166,10 @@ void MainWindow::sendHeartbeat(){
|
|||||||
processTxQueue();
|
processTxQueue();
|
||||||
}
|
}
|
||||||
|
|
||||||
#define SEND_SNR_IN_ACK 0
|
|
||||||
void MainWindow::sendHeartbeatAck(QString to, int snr, QString extra){
|
void MainWindow::sendHeartbeatAck(QString to, int snr, QString extra){
|
||||||
#if SEND_SNR_IN_ACK
|
auto message = m_config.heartbeat_ack_snr() ?
|
||||||
auto message = QString("%1 ACK %2 %3").arg(to).arg(Varicode::formatSNR(snr)).arg(extra).trimmed();
|
QString("%1 SNR %2 %3").arg(to).arg(Varicode::formatSNR(snr)).arg(extra).trimmed() :
|
||||||
#else
|
QString("%1 ACK %2").arg(to).arg(extra).trimmed();
|
||||||
auto message = QString("%1 ACK %2").arg(to).arg(extra).trimmed();
|
|
||||||
#endif
|
|
||||||
|
|
||||||
auto f = m_config.heartbeat_anywhere() ? -1 : findFreeFreqOffset(500, 1000, 50);
|
auto f = m_config.heartbeat_anywhere() ? -1 : findFreeFreqOffset(500, 1000, 50);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user