mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-17 17:42:02 -05:00
Fix some logic errors in CAT serial port control line settings
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6588 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
parent
dae625e6ce
commit
d63230729b
@ -1457,14 +1457,21 @@ void Configuration::impl::set_rig_invariants ()
|
||||
ui_->PTT_port_combo_box->setEnabled (enable_ptt_port);
|
||||
ui_->PTT_port_label->setEnabled (enable_ptt_port);
|
||||
|
||||
if (CAT_indirect_serial_PTT)
|
||||
{
|
||||
ui_->PTT_port_combo_box->setItemData (ui_->PTT_port_combo_box->findText ("CAT")
|
||||
, CAT_indirect_serial_PTT ? combo_box_item_enabled : combo_box_item_disabled
|
||||
, Qt::UserRole - 1);
|
||||
|
||||
ui_->PTT_DTR_radio_button->setEnabled (!("CAT" == ptt_port && !CAT_indirect_serial_PTT));
|
||||
|
||||
ui_->PTT_RTS_radio_button->setEnabled (!((is_serial_CAT && ptt_port == cat_port && is_hw_handshake)
|
||||
|| ("CAT" == ptt_port && !CAT_indirect_serial_PTT)));
|
||||
, combo_box_item_enabled, Qt::UserRole - 1);
|
||||
}
|
||||
else
|
||||
{
|
||||
ui_->PTT_port_combo_box->setItemData (ui_->PTT_port_combo_box->findText ("CAT")
|
||||
, combo_box_item_disabled, Qt::UserRole - 1);
|
||||
if ("CAT" == ui_->PTT_port_combo_box->currentText () && ui_->PTT_port_combo_box->currentIndex () > 0)
|
||||
{
|
||||
ui_->PTT_port_combo_box->setCurrentIndex (ui_->PTT_port_combo_box->currentIndex () - 1);
|
||||
}
|
||||
}
|
||||
ui_->PTT_RTS_radio_button->setEnabled (!(is_serial_CAT && ptt_port == cat_port && is_hw_handshake));
|
||||
|
||||
if (TransceiverFactory::basic_transceiver_name_ == rig)
|
||||
{
|
||||
@ -1631,9 +1638,9 @@ TransceiverFactory::ParameterPack Configuration::impl::gather_rig_data ()
|
||||
result.stop_bits = static_cast<TransceiverFactory::StopBits> (ui_->CAT_stop_bits_button_group->checkedId ());
|
||||
result.handshake = static_cast<TransceiverFactory::Handshake> (ui_->CAT_handshake_button_group->checkedId ());
|
||||
result.force_dtr = ui_->force_DTR_combo_box->isEnabled () && ui_->force_DTR_combo_box->currentIndex () > 0;
|
||||
result.dtr_high = 1 == ui_->force_DTR_combo_box->currentIndex ();
|
||||
result.dtr_high = ui_->force_DTR_combo_box->isEnabled () && 1 == ui_->force_DTR_combo_box->currentIndex ();
|
||||
result.force_rts = ui_->force_RTS_combo_box->isEnabled () && ui_->force_RTS_combo_box->currentIndex () > 0;
|
||||
result.rts_high = 1 == ui_->force_RTS_combo_box->currentIndex ();
|
||||
result.rts_high = ui_->force_RTS_combo_box->isEnabled () && 1 == ui_->force_RTS_combo_box->currentIndex ();
|
||||
result.poll_interval = ui_->CAT_poll_interval_spin_box->value ();
|
||||
result.ptt_type = static_cast<TransceiverFactory::PTTMethod> (ui_->PTT_method_button_group->checkedId ());
|
||||
result.ptt_port = ui_->PTT_port_combo_box->currentText ();
|
||||
|
@ -2,14 +2,6 @@
|
||||
<ui version="4.0">
|
||||
<class>configuration_dialog</class>
|
||||
<widget class="QDialog" name="configuration_dialog">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>545</width>
|
||||
<height>614</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Settings</string>
|
||||
</property>
|
||||
@ -807,7 +799,7 @@ a few, particularly some Kenwood rigs, require it).</string>
|
||||
<item row="0" column="1">
|
||||
<widget class="QRadioButton" name="PTT_DTR_radio_button">
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>Use the RS-232 DTR control line to toggle your radio's PTT,</p><p>requires hardware to inteface the line.</p><p>Some commercial interface units also use this method.</p><p>The DTR control line of the CAT serial port may be used for this or</p><p>a DTR control line on a different serial port may be used.</p></body></html></string>
|
||||
<string><html><head/><body><p>Use the RS-232 DTR control line to toggle your radio's PTT, requires hardware to inteface the line.</p><p>Some commercial interface units also use this method.</p><p>The DTR control line of the CAT serial port may be used for this or a DTR control line on a different serial port may be used.</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&DTR</string>
|
||||
@ -838,7 +830,7 @@ other hardware interface for PTT.</string>
|
||||
<item row="1" column="1">
|
||||
<widget class="QRadioButton" name="PTT_RTS_radio_button">
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>Use the RS-232 RTS control line to toggle your radio's PTT,</p><p>requires hardware to inteface the line.</p><p>Some commercial interface units also use this method.</p><p>The RTS control line of the CAT serial port may be used for this or</p><p>a RTS control line on a different serial port may be used.</p><p>Note that this options is not available on the CAT serial port</p><p>when hardware flow control is used.</p></body></html></string>
|
||||
<string><html><head/><body><p>Use the RS-232 RTS control line to toggle your radio's PTT, requires hardware to inteface the line.</p><p>Some commercial interface units also use this method.</p><p>The RTS control line of the CAT serial port may be used for this or a RTS control line on a different serial port may be used. Note that this option is not available on the CAT serial port when hardware flow control is used.</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>R&TS</string>
|
||||
@ -872,7 +864,7 @@ other hardware interface for PTT.</string>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>Select the RS-232 serial port utilised for PTT control,</p><p>this option is available when DTR or RTS is selected above</p><p>as a transmit method.</p><p>This port can be the same one as the one used for CAT control.</p><p>For some interface types the special value CAT may be chosen,</p><p>this is used for non-serial CAT interfaces that can control</p><p>serial port control lines remotely (OmniRig for example).</p></body></html></string>
|
||||
<string><html><head/><body><p>Select the RS-232 serial port utilised for PTT control, this option is available when DTR or RTS is selected above as a transmit method.</p><p>This port can be the same one as the one used for CAT control.</p><p>For some interface types the special value CAT may be chosen, this is used for non-serial CAT interfaces that can control serial port control lines remotely (OmniRig for example).</p></body></html></string>
|
||||
</property>
|
||||
<property name="editable">
|
||||
<bool>true</bool>
|
||||
@ -2403,6 +2395,7 @@ soundcard changes</string>
|
||||
<tabstop>disable_TX_on_73_check_box</tabstop>
|
||||
<tabstop>watchdog_check_box</tabstop>
|
||||
<tabstop>decode_at_52s_check_box</tabstop>
|
||||
<tabstop>offset_Rx_freq_check_box</tabstop>
|
||||
<tabstop>CW_id_after_73_check_box</tabstop>
|
||||
<tabstop>CW_id_interval_spin_box</tabstop>
|
||||
<tabstop>rig_combo_box</tabstop>
|
||||
@ -2419,8 +2412,8 @@ soundcard changes</string>
|
||||
<tabstop>force_DTR_combo_box</tabstop>
|
||||
<tabstop>force_RTS_combo_box</tabstop>
|
||||
<tabstop>PTT_VOX_radio_button</tabstop>
|
||||
<tabstop>PTT_DTR_radio_button</tabstop>
|
||||
<tabstop>PTT_CAT_radio_button</tabstop>
|
||||
<tabstop>PTT_DTR_radio_button</tabstop>
|
||||
<tabstop>PTT_RTS_radio_button</tabstop>
|
||||
<tabstop>PTT_port_combo_box</tabstop>
|
||||
<tabstop>TX_source_data_radio_button</tabstop>
|
||||
@ -2463,6 +2456,16 @@ soundcard changes</string>
|
||||
<tabstop>pbTxMsg</tabstop>
|
||||
<tabstop>pbNewDXCC</tabstop>
|
||||
<tabstop>pbNewCall</tabstop>
|
||||
<tabstop>sbNtrials</tabstop>
|
||||
<tabstop>cbSync1Bit</tabstop>
|
||||
<tabstop>cbTwoPass</tabstop>
|
||||
<tabstop>cbMyDx</tabstop>
|
||||
<tabstop>cbCQMyN</tabstop>
|
||||
<tabstop>cbNDxG</tabstop>
|
||||
<tabstop>cbNN</tabstop>
|
||||
<tabstop>cbEMEonly</tabstop>
|
||||
<tabstop>sbAggressive</tabstop>
|
||||
<tabstop>sbDegrade</tabstop>
|
||||
</tabstops>
|
||||
<resources/>
|
||||
<connections>
|
||||
@ -2525,19 +2528,19 @@ soundcard changes</string>
|
||||
<y>60</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>566</x>
|
||||
<x>404</x>
|
||||
<y>62</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<buttongroups>
|
||||
<buttongroup name="CAT_stop_bits_button_group"/>
|
||||
<buttongroup name="split_mode_button_group"/>
|
||||
<buttongroup name="CAT_data_bits_button_group"/>
|
||||
<buttongroup name="TX_audio_source_button_group"/>
|
||||
<buttongroup name="CAT_handshake_button_group"/>
|
||||
<buttongroup name="PTT_method_button_group"/>
|
||||
<buttongroup name="CAT_stop_bits_button_group"/>
|
||||
<buttongroup name="CAT_data_bits_button_group"/>
|
||||
<buttongroup name="TX_mode_button_group"/>
|
||||
<buttongroup name="TX_audio_source_button_group"/>
|
||||
</buttongroups>
|
||||
</ui>
|
||||
|
Loading…
Reference in New Issue
Block a user