[Hamlib-commits] Hamlib -- Ham radio control libraries branch master updated. 80e199b302af7d5354438
Library to control radio transceivers and receivers
Brought to you by:
n0nb
From: Michael B. <mdb...@us...> - 2021-03-20 13:08:20
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 80e199b302af7d5354438551a355e0fafee170bd (commit) via 950163f1a426d9942c1c15492b62833ff8e62555 (commit) from 1224e9f6ba7e2084a133f8a94f6013820045fbd7 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 80e199b302af7d5354438551a355e0fafee170bd Author: Michael Black W9MDB <mdb...@ya...> Date: Sat Mar 20 08:07:16 2021 -0500 Add satmode detection for Icom rigs like IC9700 In satmode VFOB/Sub now maps to SubA (2nd VFO) https://github.com/Hamlib/Hamlib/issues/621 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index b3c54002..f3686cbe 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2107,6 +2107,11 @@ int icom_set_vfo(RIG *rig, vfo_t vfo) { // If we're being asked for B/Sub but we are a MainA/MainB rig change it vfo = RIG_VFO_MAIN_B; + // If we're in satmode for rigs like IC9700 we want the 2nd VFO + if (rig->state.cache.satmode) + { + vfo = RIG_VFO_SUB_A; + } } else if ((vfo == RIG_VFO_A || vfo == RIG_VFO_B) && !VFO_HAS_A_B && VFO_HAS_MAIN_SUB) { diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 6be6e773..6a000848 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20210319" +#define BACKEND_VER "20210320" /* * defines used by comp_cal_str in rig.c commit 950163f1a426d9942c1c15492b62833ff8e62555 Author: Michael Black W9MDB <mdb...@ya...> Date: Fri Mar 19 23:36:33 2021 -0500 Rigs like IC9700 with MainA/B will have VFOA/Main mapped to MainA and VFOB/Sub mapped to MainB No known use for SubA/SubB yet https://github.com/Hamlib/Hamlib/issues/621 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index d12721e4..b3c54002 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2098,7 +2098,17 @@ int icom_set_vfo(RIG *rig, vfo_t vfo) else if (VFO_HAS_MAIN_SUB_A_B_ONLY && rig->state.cache.satmode) { vfo = RIG_VFO_SUB; } } - if ((vfo == RIG_VFO_A || vfo == RIG_VFO_B) && !VFO_HAS_A_B && VFO_HAS_MAIN_SUB) + else if ((vfo == RIG_VFO_A || vfo == RIG_VFO_MAIN) && VFO_HAS_MAIN_SUB_A_B_ONLY) + { + // If we're being asked for A/Main but we are a MainA/MainB rig change it + vfo = RIG_VFO_MAIN_A; + } + else if ((vfo == RIG_VFO_B || vfo == RIG_VFO_SUB) && VFO_HAS_MAIN_SUB_A_B_ONLY) + { + // If we're being asked for B/Sub but we are a MainA/MainB rig change it + vfo = RIG_VFO_MAIN_B; + } + else if ((vfo == RIG_VFO_A || vfo == RIG_VFO_B) && !VFO_HAS_A_B && VFO_HAS_MAIN_SUB) { // If we're being asked for A/B but we are a Main/Sub rig change it vfo_t vfo_old = vfo; @@ -2108,6 +2118,7 @@ int icom_set_vfo(RIG *rig, vfo_t vfo) rig_strvfo(vfo)); } + if ((vfo == RIG_VFO_MAIN || vfo == RIG_VFO_SUB) && !VFO_HAS_MAIN_SUB) { rig_debug(RIG_DEBUG_ERR, "%s: Rig does not have VFO Main/Sub?\n", diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 9127cc62..6be6e773 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20210318" +#define BACKEND_VER "20210319" /* * defines used by comp_cal_str in rig.c ----------------------------------------------------------------------- Summary of changes: rigs/icom/icom.c | 18 +++++++++++++++++- rigs/icom/icom.h | 2 +- 2 files changed, 18 insertions(+), 2 deletions(-) hooks/post-receive -- Hamlib -- Ham radio control libraries |