From 9bedee11830938f37b63919e0cecb615bbfd62a1 Mon Sep 17 00:00:00 2001 From: Dan Smith Date: Thu, 29 Aug 2024 17:09:52 -0700 Subject: [PATCH] ft857: Fix incorrect DTCS handling This driver has been broken forever in how it handles DTCS tone mode. It was always using the rx_dtcs field, which should only be honored in a ->DTCS cross mode. The new GUI, being in hide-unused-fields mode always made this clear, as it appeared to be snapping back to 023 always when the user selected a different value. Note that the test is *also* broken, which I will fix at the end of this series. Related to #11506 --- chirp/drivers/ft857.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chirp/drivers/ft857.py b/chirp/drivers/ft857.py index 57acf9b11..13e13f0da 100644 --- a/chirp/drivers/ft857.py +++ b/chirp/drivers/ft857.py @@ -514,7 +514,7 @@ def _set_tmode(self, mem, _mem): # this code has already been tested _mem.dcs = _mem.rxdcs = chirp_common.DTCS_CODES.index(mem.dtcs) elif mem.tmode == "DTCS": - _mem.dcs = _mem.rxdcs = chirp_common.DTCS_CODES.index(mem.rx_dtcs) + _mem.dcs = _mem.rxdcs = chirp_common.DTCS_CODES.index(mem.dtcs) elif mem.tmode == "Cross": _mem.tone = chirp_common.TONES.index(mem.rtone) _mem.rxtone = chirp_common.TONES.index(mem.ctone)