kopia lustrzana https://gitlab.com/eliggett/wfview
rodzic
d742c7564a
commit
a231cb086f
|
@ -217,20 +217,6 @@ void rigCommander::receiveBaudRate(quint32 baudrate) {
|
|||
emit haveBaudRate(baudrate);
|
||||
}
|
||||
|
||||
void rigCommander::setRTSforPTT(bool enabled)
|
||||
{
|
||||
if(!usingNativeLAN)
|
||||
{
|
||||
useRTSforPTT_isSet = true;
|
||||
useRTSforPTT_manual = enabled;
|
||||
if(comm != NULL)
|
||||
{
|
||||
rigCaps.useRTSforPTT=enabled;
|
||||
comm->setUseRTSforPTT(enabled);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void rigCommander::findRigs()
|
||||
{
|
||||
// This function sends data to 0x00 ("broadcast") to look for any connected rig.
|
||||
|
@ -3610,13 +3596,8 @@ void rigCommander::determineRigCaps()
|
|||
haveRigCaps = true;
|
||||
|
||||
if(!usingNativeLAN)
|
||||
{
|
||||
if(useRTSforPTT_isSet)
|
||||
{
|
||||
rigCaps.useRTSforPTT = useRTSforPTT_manual;
|
||||
}
|
||||
comm->setUseRTSforPTT(rigCaps.useRTSforPTT);
|
||||
}
|
||||
|
||||
|
||||
if(lookingForRig)
|
||||
{
|
||||
|
|
|
@ -79,7 +79,6 @@ public slots:
|
|||
void commSetup(unsigned char rigCivAddr, udpPreferences prefs, audioSetup rxSetup, audioSetup txSetup, QString vsp);
|
||||
void closeComm();
|
||||
void stateUpdated();
|
||||
void setRTSforPTT(bool enabled);
|
||||
|
||||
// Power:
|
||||
void powerOn();
|
||||
|
@ -453,9 +452,6 @@ private:
|
|||
unsigned char civAddr;
|
||||
unsigned char incomingCIVAddr; // place to store the incoming CIV.
|
||||
bool pttAllowed;
|
||||
bool useRTSforPTT_isSet = false;
|
||||
bool useRTSforPTT_manual = false;
|
||||
|
||||
|
||||
QString rigSerialPort;
|
||||
quint32 rigBaudRate;
|
||||
|
|
17
wfmain.cpp
17
wfmain.cpp
|
@ -423,7 +423,7 @@ void wfmain::makeRig()
|
|||
// Rig comm setup:
|
||||
connect(this, SIGNAL(sendCommSetup(unsigned char, udpPreferences, audioSetup, audioSetup, QString)), rig, SLOT(commSetup(unsigned char, udpPreferences, audioSetup, audioSetup, QString)));
|
||||
connect(this, SIGNAL(sendCommSetup(unsigned char, QString, quint32,QString)), rig, SLOT(commSetup(unsigned char, QString, quint32,QString)));
|
||||
connect(this, SIGNAL(setRTSforPTT(bool)), rig, SLOT(setRTSforPTT(bool)));
|
||||
|
||||
|
||||
connect(rig, SIGNAL(haveBaudRate(quint32)), this, SLOT(receiveBaudRate(quint32)));
|
||||
|
||||
|
@ -1312,7 +1312,6 @@ void wfmain::setDefPrefs()
|
|||
defPrefs.stylesheetPath = QString("qdarkstyle/style.qss");
|
||||
defPrefs.radioCIVAddr = 0x00; // previously was 0x94 for 7300.
|
||||
defPrefs.CIVisRadioModel = false;
|
||||
defPrefs.forceRTSasPTT = false;
|
||||
defPrefs.serialPortRadio = QString("auto");
|
||||
defPrefs.serialPortBaud = 115200;
|
||||
defPrefs.enablePTT = false;
|
||||
|
@ -1412,9 +1411,7 @@ void wfmain::loadSettings()
|
|||
ui->rigCIVaddrHexLine->setEnabled(false);
|
||||
}
|
||||
prefs.CIVisRadioModel = (bool)settings->value("CIVisRadioModel", defPrefs.CIVisRadioModel).toBool();
|
||||
prefs.forceRTSasPTT = (bool)settings->value("ForceRTSasPTT", defPrefs.forceRTSasPTT).toBool();
|
||||
|
||||
ui->useRTSforPTTchk->setChecked(prefs.forceRTSasPTT);
|
||||
|
||||
prefs.serialPortRadio = settings->value("SerialPortRadio", defPrefs.serialPortRadio).toString();
|
||||
int serialIndex = ui->serialDeviceListCombo->findText(prefs.serialPortRadio);
|
||||
|
@ -1775,7 +1772,6 @@ void wfmain::saveSettings()
|
|||
settings->beginGroup("Radio");
|
||||
settings->setValue("RigCIVuInt", prefs.radioCIVAddr);
|
||||
settings->setValue("CIVisRadioModel", prefs.CIVisRadioModel);
|
||||
settings->setValue("ForceRTSasPTT", prefs.forceRTSasPTT);
|
||||
settings->setValue("SerialPortRadio", prefs.serialPortRadio);
|
||||
settings->setValue("SerialPortBaud", prefs.serialPortBaud);
|
||||
settings->setValue("VirtualSerialPort", prefs.virtualSerialPort);
|
||||
|
@ -3266,10 +3262,6 @@ void wfmain::receiveRigID(rigCapabilities rigCaps)
|
|||
ui->tuneEnableChk->setEnabled(rigCaps.hasATU);
|
||||
ui->tuneNowBtn->setEnabled(rigCaps.hasATU);
|
||||
|
||||
ui->useRTSforPTTchk->blockSignals(true);
|
||||
ui->useRTSforPTTchk->setChecked(rigCaps.useRTSforPTT);
|
||||
ui->useRTSforPTTchk->blockSignals(false);
|
||||
|
||||
ui->connectBtn->setText("Disconnect"); // We must be connected now.
|
||||
prepareWf(ui->wfLengthSlider->value());
|
||||
if(usingLAN)
|
||||
|
@ -5505,7 +5497,6 @@ void wfmain::on_rigCIVaddrHexLine_editingFinished()
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
void wfmain::on_baudRateCombo_activated(int index)
|
||||
{
|
||||
bool ok = false;
|
||||
|
@ -5519,12 +5510,6 @@ void wfmain::on_baudRateCombo_activated(int index)
|
|||
(void)index;
|
||||
}
|
||||
|
||||
void wfmain::on_useRTSforPTTchk_clicked(bool checked)
|
||||
{
|
||||
emit setRTSforPTT(checked);
|
||||
prefs.forceRTSasPTT = checked;
|
||||
}
|
||||
|
||||
void wfmain::on_wfLengthSlider_valueChanged(int value)
|
||||
{
|
||||
prefs.wflength = (unsigned int)(value);
|
||||
|
|
4
wfmain.h
4
wfmain.h
|
@ -52,7 +52,6 @@ signals:
|
|||
// Basic to rig:
|
||||
void setCIVAddr(unsigned char newRigCIVAddr);
|
||||
void setRigID(unsigned char rigID);
|
||||
void setRTSforPTT(bool enabled);
|
||||
|
||||
// Power
|
||||
void sendPowerOn();
|
||||
|
@ -515,8 +514,6 @@ private slots:
|
|||
|
||||
void onServerPasswordChanged();
|
||||
|
||||
void on_useRTSforPTTchk_clicked(bool checked);
|
||||
|
||||
private:
|
||||
Ui::wfmain *ui;
|
||||
void closeEvent(QCloseEvent *event);
|
||||
|
@ -739,7 +736,6 @@ private:
|
|||
QString stylesheetPath;
|
||||
unsigned char radioCIVAddr;
|
||||
bool CIVisRadioModel;
|
||||
bool forceRTSasPTT;
|
||||
QString serialPortRadio;
|
||||
quint32 serialPortBaud;
|
||||
bool enablePTT;
|
||||
|
|
12
wfmain.ui
12
wfmain.ui
|
@ -2066,7 +2066,7 @@
|
|||
<item>
|
||||
<widget class="QStackedWidget" name="settingsStack">
|
||||
<property name="currentIndex">
|
||||
<number>0</number>
|
||||
<number>3</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="radioAccess">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_21">
|
||||
|
@ -2250,16 +2250,6 @@
|
|||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="useRTSforPTTchk">
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>This feature is for older radios that respond best to an RTS serial port signal than a PTT command.</p><p><br/>For radios lacking PTT commands, this is automatic and transparent, but for radios which have a PTT command, you can check this box to override and force the PTT to be done using RTS. Do not check this box unless you really need this and have an appropriate adapter with RTS connected to the PTT line of the transceiver. </p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Send RTS for PTT</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_4">
|
||||
<property name="orientation">
|
||||
|
|
Ładowanie…
Reference in New Issue