28 Dec
2012
28 Dec
'12
8:39 p.m.
On Fri, Dec 28, 2012 at 3:24 PM, Tom Hayward esarfl@gmail.com wrote:
On Fri, Dec 28, 2012 at 3:10 PM, Dan Smith dsmith@danplanet.com wrote:
return field[0].get_raw() == "\xFF"
return int(field) in [0, 16665]
Hmm, can you explain this?
No, I can't explain it. 16665 is the magic number used in the PX-777 to indicate no tone. Here's an example:
struct { rx_freq: 4:[(15390000)] tx_freq: 4:[(15390000)] rx_tone: 2:[(16665)] tx_tone: 2:[(16665)]
...and that would be because lbcd 0xFF 0xFF == 16665d.
Should I add a get_raw() method to arrayDataElement? Then do this:
return field.get_raw() in [0, 0xFFFF]
The only reason I'm using int for the comparison is because that's the coercion that's available in arrayDataElement.
Tom KD7LXL