3 Jul
2013
3 Jul
'13
4:48 p.m.
Hi Jim,
Thanks for working on this, and sorry for the delay in responding.
def _do_upload(radio):
- _ident_radio(radio)
- ident = _ident_radio(radio)
- # VHF/UHF = "\x04" or "\x42" (original)
- # VHF/220 = "\x02"
Can you actually set these as constants at the top of the file, like STEPS, STEP_LIST, etc?
- radio_upper_band = ident[3:4]
- image_upper_band = _upper_band_from_image(radio)
- if image_upper_band == "\x02" or radio_upper_band == "\x02":
Then you can use those here instead of the raw hex, for more clarity.
if image_upper_band != radio_upper_band:
raise errors.RadioError("Image not supportted by radio")
"supported" is misspelled.
Thanks!
--
Dan Smith
www.danplanet.com
KK7DS