From 870b9ca7481fc40255749194fe6215cbbc74df93 Mon Sep 17 00:00:00 2001 From: Mike Black W9MDB Date: Mon, 19 Apr 2021 09:51:58 -0500 Subject: [PATCH] In icom.c add check for current vfo to avoid vfo swapping https://github.com/Hamlib/Hamlib/issues/665 https://github.com/Hamlib/Hamlib/issues/654 --- rigs/icom/icom.c | 2 +- rigs/icom/icom.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 6185f53fb..75ed7e381 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2105,7 +2105,7 @@ int icom_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width) // reason is we can't get width without swapping vfos -- yuck!! if (width != NULL) { - if (vfo & (RIG_VFO_A | RIG_VFO_MAIN | RIG_VFO_SUB_A | RIG_VFO_MAIN_A)) + if (vfo & (RIG_VFO_A | RIG_VFO_MAIN | RIG_VFO_SUB_A | RIG_VFO_MAIN_A | RIG_VFO_CURR)) { // then we get our current vfo..i.e. VFOA if (rig->state.current_vfo != RIG_VFO_A) diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 15f07c8d7..0f62d0732 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include #endif -#define BACKEND_VER "20210418" +#define BACKEND_VER "20210419" /* * defines used by comp_cal_str in rig.c