Fix TS450 and TS690 split check -- should be using IF status now

Should work with any rigs that don't have split status too in case there are any.
https://github.com/Hamlib/Hamlib/issues/826
pull/846/head
Mike Black W9MDB 2021-10-15 12:02:41 -05:00
rodzic 8a983cae80
commit 891ca6ed75
2 zmienionych plików z 8 dodań i 4 usunięć

Wyświetl plik

@ -1228,6 +1228,7 @@ int kenwood_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t txvfo)
char cmdbuf[12];
int retval;
unsigned char vfo_function;
split_t tsplit;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
@ -1324,10 +1325,13 @@ int kenwood_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t txvfo)
they impact output power when transmitting
and all other rigs don't need to set it if it's already set correctly
*/
if (RIG_OK == (retval = kenwood_safe_transaction(rig, "FT", cmdbuf,
sizeof(cmdbuf), 3)))
tsplit = RIG_SPLIT_OFF; // default in case rig does not set split status
retval = rig_get_split(rig, vfo, &tsplit);
// and it should be OK to do a SPLIT_OFF at any time so we won's skip that
if (retval == RIG_OK && split == RIG_SPLIT_ON && tsplit == RIG_SPLIT_ON)
{
if (cmdbuf[2] == vfo_function) { RETURNFUNC(RIG_OK); }
rig_debug(RIG_DEBUG_VERBOSE, "%s: already set split=%d\n", __func__, tsplit);
RETURNFUNC(RIG_OK);
}
/* set TX VFO */

Wyświetl plik

@ -28,7 +28,7 @@
#include "token.h"
#include "misc.h"
#define BACKEND_VER "20211008"
#define BACKEND_VER "20211015"
#define EOM_KEN ';'
#define EOM_TH '\r'