[chirp_devel] Fwd: [PATCH] [BF-F8HP] Fix for out-of-range TXP values in VFOs
Jim Unroe
Wed Feb 24 14:29:42 PST 2021
---------- Forwarded message ---------
From: Jim Unroe <kc9hi at comcast.net>
Date: Wed, Feb 24, 2021 at 5:23 PM
Subject: [PATCH] [BF-F8HP] Fix for out-of-range TXP values in VFOs
To: <Rock.Unroe at gmail.com>
# HG changeset patch
# User Jim Unroe <rock.unroe at gmail.com>
# Date 1614205381 18000
# Wed Feb 24 17:23:01 2021 -0500
# Node ID 9e2559a3722e1bf4ce7eb9d24e93197a6e162084
# Parent 9302d496db2b2082e99fab333d3c943d948a954d
[BF-F8HP] Fix for out-of-range TXP values in VFOs
This patch forces out-of-range TXP values to a valid value.
Fixes #8539
diff -r 9302d496db2b -r 9e2559a3722e chirp/drivers/uv5r.py
--- a/chirp/drivers/uv5r.py Tue Feb 23 21:28:16 2021 -0500
+++ b/chirp/drivers/uv5r.py Wed Feb 24 17:23:01 2021 -0500
@@ -1488,16 +1488,24 @@
workmode.append(rs)
if self._tri_power:
+ if _vfoa.txpower3 > 0x02:
+ val = 0x00
+ else:
+ val = _vfoa.txpower3
rs = RadioSetting("vfoa.txpower3", "VFO A Power",
RadioSettingValueList(
TXPOWER3_LIST,
- TXPOWER3_LIST[_vfoa.txpower3]))
+ TXPOWER3_LIST[val]))
workmode.append(rs)
+ if _vfob.txpower3 > 0x02:
+ val = 0x00
+ else:
+ val = _vfob.txpower3
rs = RadioSetting("vfob.txpower3", "VFO B Power",
RadioSettingValueList(
TXPOWER3_LIST,
- TXPOWER3_LIST[_vfob.txpower3]))
+ TXPOWER3_LIST[val]))
workmode.append(rs)
else:
rs = RadioSetting("vfoa.txpower", "VFO A Power",
More information about the chirp_devel
mailing list