[chirp_devel] [PATCH] [KG-UVxD] Fix dtcs pol get for cross tone

Jim Unroe
Mon Mar 10 03:39:37 PDT 2014


Marco,
This still isn't accepted by the radio properly. See issue #1479 for
details. I have to head to work.
Jim


On Sun, Mar 9, 2014 at 12:32 PM, Marco Filippi IZ3GME <
iz3gme.marco at gmail.com> wrote:

> # HG changeset patch
> # User Marco Filippi <iz3gme.marco at gmail.com>
> # Date 1394382139 -3600
> #      Sun Mar 09 17:22:19 2014 +0100
> # Node ID d1081e1a2f00df31c29dc0278d3e64f1e5fe8e9a
> # Parent  b6ca836716a933248e18fedf10ed8c45f0187848
> [KG-UVxD] Fix dtcs pol get for cross tone
>
> Dtcs pol get was working only for "DTCS" tone mode, it has to be
> considered also
> for cross tone modes.
>
> Fix #1479
>
> diff -r b6ca836716a9 -r d1081e1a2f00 chirp/wouxun.py
> --- a/chirp/wouxun.py   Sun Mar 02 19:37:13 2014 -0500
> +++ b/chirp/wouxun.py   Sun Mar 09 17:22:19 2014 +0100
> @@ -673,6 +673,7 @@
>              pol = (val & 0x8000) and "R" or "N"
>              return code, pol
>
> +        tpol = False
>          if _mem.tx_tone != 0xFFFF and _mem.tx_tone > 0x2800:
>              tcode, tpol = _get_dcs(_mem.tx_tone)
>              mem.dtcs = tcode
> @@ -683,6 +684,7 @@
>          else:
>              txmode = ""
>
> +        rpol = False
>          if _mem.rx_tone != 0xFFFF and _mem.rx_tone > 0x2800:
>              rcode, rpol = _get_dcs(_mem.rx_tone)
>              mem.rx_dtcs = rcode
> @@ -703,8 +705,8 @@
>              mem.tmode = "Cross"
>              mem.cross_mode = "%s->%s" % (txmode, rxmode)
>
> -        if mem.tmode == "DTCS":
> -            mem.dtcs_polarity = "%s%s" % (tpol, rpol)
> +        # always set it even if no dtcs is used
> +        mem.dtcs_polarity = "%s%s" % (tpol or "N", rpol or "N")
>
>          if os.getenv("CHIRP_DEBUG"):
>              print "Got TX %s (%i) RX %s (%i)" % (txmode, _mem.tx_tone,
> _______________________________________________
> chirp_devel mailing list
> chirp_devel at intrepid.danplanet.com
> http://intrepid.danplanet.com/mailman/listinfo/chirp_devel
> Developer docs: http://chirp.danplanet.com/projects/chirp/wiki/Developers
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://intrepid.danplanet.com/pipermail/chirp_devel/attachments/20140310/efb1b987/attachment-0001.html 


More information about the chirp_devel mailing list