Hi Cody,

 

Thanks for submitting these! I just reviewed these and did some tests. I’m not too sure I understand what the intent was here, so I wanted to pose a question to the list.

 

For CHIRP in general - does “off” mean:

a)  duplex / repeater shift is disabled and the radio should operate in simplex mode

or

b) Tx is inhibited

 

I don’t see “off” listed as an option on other radios such as the VX-6.

 

If I change an existing simplex channel from “(None)” to “off” – the radio gives an error. Is that what was intended?

 

For issue 2891 – I think it would be cleaner to simply remove the extra “” from line 275, rather than stripping it from the array as its assigned to the rf object in line 367. Is the extra “”, “” needed in line 275 to effectively 1-index the duplex value instead? If not, it seems like we could just strip it out and assign the array as-is. This is how the VX-6 and most other drivers work.

 

73,

Patrick

KG7NSC

 

Sent from Mail for Windows 10

 

 


From: Cody P Schafer via chirp_devel
Sent: Friday, October 2, 2015 5:47 PM
To: chirp_devel@intrepid.danplanet.com
Subject: [chirp_devel] [PATCH 2 of 2] drivers/ft60: add support for "off"duplex mode (#2891)

 

 

# HG changeset patch

# User Cody P Schafer <dev@codyps.com>

# Date 1443833114 14400

#      Fri Oct 02 20:45:14 2015 -0400

# Node ID 2628a7decd6363fc5875c4ad5e84fc0323737c32

# Parent  f599c685d5cc42229028905e63f606358e05462b

drivers/ft60: add support for "off" duplex mode (#2891)

 

By using a tx frequency of '0', the radio (or at least my ft60) refuses to

transmit (gives "ERROR" on the screen) when the PTT key is pressed.

 

diff --git a/chirp/drivers/ft60.py b/chirp/drivers/ft60.py

--- a/chirp/drivers/ft60.py

+++ b/chirp/drivers/ft60.py

@@ -272,7 +272,7 @@

u8 checksum;

"""

-DUPLEX = ["", "", "-", "+", "split"]

+DUPLEX = ["", "", "-", "+", "split", "off"]

TMODES = ["", "Tone", "TSQL", "TSQL-R", "DTCS"]

POWER_LEVELS = [chirp_common.PowerLevel("High", watts=5.0),

                 chirp_common.PowerLevel("Mid", watts=2.0),

@@ -703,7 +703,10 @@

         mem.offset = int(_mem.offset) * 50000

         mem.duplex = DUPLEX[_mem.duplex]

         if mem.duplex == "split":

-            mem.offset = _decode_freq(_mem.tx_freq)

+            if int(_mem.tx_freq) == 0:

+                mem.duplex = "off"

+            else:

+                mem.offset = _decode_freq(_mem.tx_freq)

         mem.tmode = TMODES[_mem.tmode]

         mem.rtone = chirp_common.TONES[_mem.tone]

         mem.dtcs = chirp_common.DTCS_CODES[_mem.dtcs]

@@ -747,6 +750,9 @@

             _mem.tx_freq, flags = _encode_freq(mem.offset)

             _mem.tx_freq[0].set_bits(flags)

             _mem.offset = 0

+        elif mem.duplex == "off":

+            _mem.tx_freq = 0

+            _mem.offset = 0

         else:

             _mem.tx_freq = 0

             _mem.offset = mem.offset / 50000

_______________________________________________

chirp_devel mailing list

chirp_devel@intrepid.danplanet.com

http://intrepid.danplanet.com/mailman/listinfo/chirp_devel

Developer docs: http://chirp.danplanet.com/projects/chirp/wiki/Developers