Fix for mode selection

translations
Phil Taylor 2024-01-28 09:42:50 +00:00
rodzic b3eb151104
commit 03b4059f76
9 zmienionych plików z 41 dodań i 26 usunięć

Wyświetl plik

@ -1342,7 +1342,7 @@ void rigCommander::determineRigCaps()
{
settings->setArrayIndex(c);
rigCaps.modes.push_back(modeInfo(rigMode_t(settings->value("Num", 0).toUInt()),
settings->value("Reg", 0).toString().toUInt(nullptr,16), settings->value("Name", "").toString(), settings->value("Min", 0).toInt(), settings->value("Max", 0).toInt()));
settings->value("Reg", 0).toString().toUInt(), settings->value("Name", "").toString(), settings->value("Min", 0).toInt(), settings->value("Max", 0).toInt()));
}
settings->endArray();
}
@ -2741,11 +2741,11 @@ void rigCommander::receiveCommand(funcs func, QVariant value, uchar vfo)
{
if (func == funcDataModeWithFilter)
{
payload.append(value.value<modeInfo>().data);
payload.append(bcdEncodeChar(value.value<modeInfo>().data));
if (value.value<modeInfo>().data != 0)
payload.append(value.value<modeInfo>().filter);
} else {
payload.append(value.value<modeInfo>().reg);
payload.append(bcdEncodeChar(value.value<modeInfo>().reg));
if (func == funcSelectedMode || func == funcUnselectedMode)
payload.append(value.value<modeInfo>().data);
payload.append(value.value<modeInfo>().filter);

Wyświetl plik

@ -399,8 +399,8 @@ Commands\75\Max=0
Commands\75\Command29=false
Commands\76\Type=Filter Width
Commands\76\String=\\x1a\\x03
Commands\76\Min=0
Commands\76\Max=3600
Commands\76\Min=50
Commands\76\Max=10000
Commands\76\Command29=false
Commands\77\Type=Quick Split
Commands\77\String=\\x1a\\x05\\x00\\x45

Wyświetl plik

@ -304,8 +304,8 @@ Commands\56\Max=0
Commands\56\Command29=false
Commands\57\Type=Filter Width
Commands\57\String=\\x1a\\x03
Commands\57\Min=0
Commands\57\Max=3600
Commands\57\Min=50
Commands\57\Max=10000
Commands\57\Command29=false
Commands\58\Type=Quick Split
Commands\58\String=\\x1a\\x05\\x00\\x30

Wyświetl plik

@ -6,6 +6,7 @@ Manufacturer=Icom
Model=IC-7610
CIVAddress=152
RigCtlDModel=3078
NumberOfVFOs=2
SpectrumSeqMax=15
SpectrumAmpMax=200
SpectrumLenMax=689
@ -424,8 +425,8 @@ Commands\80\Max=0
Commands\80\Command29=false
Commands\81\Type=Filter Width
Commands\81\String=\\x1a\\x03
Commands\81\Min=0
Commands\81\Max=3600
Commands\81\Min=50
Commands\81\Max=10000
Commands\81\Command29=true
Commands\82\Type=Quick Dual Watch
Commands\82\String=\\x1a\\x05\\x00\\x32
@ -897,12 +898,12 @@ Modes\8\Min=50
Modes\8\Max=2700
Modes\8\Name=RTTY-R
Modes\9\Num=8
Modes\9\Reg=0
Modes\9\Reg=12
Modes\9\Min=50
Modes\9\Max=3600
Modes\9\Name=PSK
Modes\10\Num=9
Modes\10\Reg=0
Modes\10\Reg=13
Modes\10\Min=50
Modes\10\Max=3600
Modes\10\Name=PSK-R

Wyświetl plik

@ -424,8 +424,8 @@ Commands\80\Max=0
Commands\80\Command29=false
Commands\81\Type=Filter Width
Commands\81\String=\\x1a\\x03
Commands\81\Min=0
Commands\81\Max=3600
Commands\81\Min=50
Commands\81\Max=10000
Commands\81\Command29=true
Commands\82\Type=Quick Split
Commands\82\String=\\x1a\\x05\\x00\\x33

Wyświetl plik

@ -379,8 +379,8 @@ Commands\71\Max=0
Commands\71\Command29=false
Commands\72\Type=Filter Width
Commands\72\String=\\x1a\\x03
Commands\72\Min=0
Commands\72\Max=3600
Commands\72\Min=50
Commands\72\Max=10000
Commands\72\Command29=false
Commands\73\Type=Quick Split
Commands\73\String=\\x1a\\x05\\x00\\x46

Wyświetl plik

@ -89,8 +89,8 @@ Commands\13\Max=1
Commands\13\Command29=false
Commands\14\Type=Memory Mode
Commands\14\String=\\x08
Commands\14\Min=0
Commands\14\Max=0
Commands\14\Min=1
Commands\14\Max=107
Commands\14\Command29=false
Commands\15\Type=Scanning
Commands\15\String=\\x0e
@ -105,7 +105,7 @@ Commands\16\Command29=false
Commands\17\Type=Tuning Step
Commands\17\String=\\x10
Commands\17\Min=0
Commands\17\Max=0
Commands\17\Max=11
Commands\17\Command29=false
Commands\18\Type=Attenuator Status
Commands\18\String=\\x11
@ -399,8 +399,8 @@ Commands\75\Max=0
Commands\75\Command29=false
Commands\76\Type=Filter Width
Commands\76\String=\\x1a\\x03
Commands\76\Min=0
Commands\76\Max=3600
Commands\76\Min=50
Commands\76\Max=10000
Commands\76\Command29=false
Commands\77\Type=Quick Split
Commands\77\String=\\x1a\\x05\\x00\\x43
@ -570,7 +570,7 @@ Commands\109\Command29=false
Commands\110\Type=Scope Main Mode
Commands\110\String=\\x27\\x14\\x00
Commands\110\Min=0
Commands\110\Max=0
Commands\110\Max=3
Commands\110\Command29=false
Commands\111\Type=Scope Main Span
Commands\111\String=\\x27\\x15\\x00
@ -612,7 +612,7 @@ Commands\118\String=\\x27\\x1d\\x00
Commands\118\Min=0
Commands\118\Max=1
Commands\118\Command29=false
Commands\119\Type=Scope Fixed Freq
Commands\119\Type=Scope Fixed Edge Freq
Commands\119\String=\\x27\\x1e
Commands\119\Min=1
Commands\119\Max=0
@ -740,12 +740,12 @@ Modes\8\Min=50
Modes\8\Max=2700
Modes\8\Name=RTTY-R
Modes\9\Num=12
Modes\9\Reg=0
Modes\9\Reg=17
Modes\9\Min=0
Modes\9\Max=0
Modes\9\Name=DV
Modes\10\Num=14
Modes\10\Reg=0
Modes\10\Reg=22
Modes\10\Min=0
Modes\10\Max=0
Modes\10\Name=DD

Wyświetl plik

@ -916,7 +916,14 @@ void spectrumScope::updatedMode(int index)
Q_UNUSED(index) // We don't know where it came from!
modeInfo mi = modeCombo->currentData().value<modeInfo>();
mi.filter = filterCombo->currentData().toInt();
mi.data = dataCombo->currentIndex();
if (mi.mk == modeCW || mi.mk == modeCW_R || mi.mk == modeRTTY || mi.mk == modeRTTY_R || mi.mk == modePSK || mi.mk == modePSK_R)
{
mi.data = 0;
dataCombo->setEnabled(false);
} else {
mi.data = dataCombo->currentIndex();
dataCombo->setEnabled(true);
}
queue->add(priorityImmediate,queueItem((vfo?funcUnselectedMode:funcSelectedMode),QVariant::fromValue(mi),false,vfo));
}
@ -1381,6 +1388,13 @@ void spectrumScope::receiveMode(modeInfo m)
dataCombo->blockSignals(false);
}
if (m.mk == modeCW || m.mk == modeCW_R || m.mk == modeRTTY || m.mk == modeRTTY_R || m.mk == modePSK || m.mk == modePSK_R)
{
dataCombo->setEnabled(false);
} else {
dataCombo->setEnabled(true);
}
if (m.mk != mode.mk) {
// We have changed mode so "may" need to change regular commands

Wyświetl plik

@ -15,7 +15,7 @@ DEFINES += USB_CONTROLLER
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets printsupport websockets
contains(DEFINES,USB_CONTROLLER){
lessThan(QT_MAJOR_VERSION, 6): QT += gamepad
lessThan(QT_MAJOR_VERSION, 6): QT += gamepad
}
TARGET = wfview