[chirp_devel] [PATCH] [uv5r] Add Cross Mode of "DTCS->DTCS"
Jim Unroe
Wed Jan 9 17:50:48 PST 2013
# HG changeset patch
# User Jim Unroe <rock.unroe at gmail.com>
# Date 1357780979 18000
# Node ID c61dc1d88339278288c2f0e1a898b0d0cd3c9c62
# Parent 9b8dc6fdf745485d3bb15fc46a7512f6a8f6634d
[uv5r] Add Cross Mode of "DTCS->DTCS"
A cross mode of "DTCS->DTCS" will allow the UV-5R to use a different
DCS code for transmit and receive
#413
diff -r 9b8dc6fdf745 -r c61dc1d88339 chirp/uv5r.py
--- a/chirp/uv5r.py Tue Jan 08 13:27:24 2013 -0800
+++ b/chirp/uv5r.py Wed Jan 09 20:22:59 2013 -0500
@@ -362,6 +362,7 @@
rf.has_settings = True
rf.has_bank = False
rf.has_cross = True
+ rf.has_rx_dtcs = True
rf.has_tuning_step = False
rf.can_odd_split = True
rf.valid_name_length = 7
@@ -369,7 +370,7 @@
rf.valid_skips = ["", "S"]
rf.valid_tmodes = ["", "Tone", "TSQL", "DTCS", "Cross"]
rf.valid_cross_modes = ["Tone->Tone", "Tone->DTCS", "DTCS->Tone",
- "->Tone", "->DTCS", "DTCS->"]
+ "->Tone", "->DTCS", "DTCS->", "DTCS->DTCS"]
rf.valid_power_levels = UV5R_POWER_LEVELS
rf.valid_duplexes = ["", "-", "+", "split", "off"]
rf.valid_modes = ["FM", "NFM"]
@@ -473,7 +474,7 @@
dtcs_pol[1] = "R"
else:
index = _mem.rxtone - 1
- mem.dtcs = UV5R_DTCS[index]
+ mem.rx_dtcs = UV5R_DTCS[index]
else:
print "Bug: rxtone is %04x" % _mem.rxtone
@@ -481,7 +482,7 @@
mem.tmode = "Tone"
elif txmode == rxmode and txmode == "Tone" and mem.rtone == mem.ctone:
mem.tmode = "TSQL"
- elif txmode == rxmode and txmode == "DTCS":
+ elif txmode == rxmode and txmode == "DTCS" and mem.dtcs == mem.rx_dtcs:
mem.tmode = "DTCS"
elif rxmode or txmode:
mem.tmode = "Cross"
@@ -549,7 +550,7 @@
if rxmode == "Tone":
_mem.rxtone = int(mem.ctone * 10)
elif rxmode == "DTCS":
- _mem.rxtone = UV5R_DTCS.index(mem.dtcs) + 1
+ _mem.rxtone = UV5R_DTCS.index(mem.rx_dtcs) + 1
else:
_mem.rxtone = 0
else:
More information about the chirp_devel
mailing list