# HG changeset patch # User Jens Jensen # Date 1385343068 21600 # Sun Nov 24 19:31:08 2013 -0600 # Node ID a03a1e9a3c99c1bcd85fe4c4a0501d3d02f68980 # Parent 19a873724b4d8ab1e3c4236d6b5ce541e85a27dd [uv-b5] more acks for radio (0x29) #1263 diff -r 19a873724b4d -r a03a1e9a3c99 chirp/uvb5.py --- a/chirp/uvb5.py Wed Nov 27 09:15:52 2013 -0800 +++ b/chirp/uvb5.py Sun Nov 24 19:31:08 2013 -0600 @@ -194,8 +194,8 @@ raise errors.RadioError("Invalid response for address 0x%04x" % i) radio.pipe.write("\x06") ack = radio.pipe.read(1) - if ack not in ('\x48', '\x74', '\x78', '\x1f'): - print util.hexprint(ack) + if ack not in UVB5_ACKS: + print "ack received:", util.hexprint(ack) raise errors.RadioError("Unexpected response") data += result[4:] do_status(radio, "from", i) @@ -224,6 +224,7 @@ } POWER_LEVELS = [chirp_common.PowerLevel("Low", watts=1), chirp_common.PowerLevel("High", watts=5)] +UVB5_ACKS = ['\x48', '\x74', '\x78', '\x1f', '\x29'] @directory.register class BaofengUVB5(chirp_common.CloneModeRadio,