[chirp_devel] [PATCH] [uv-b5] fix for proper display of STEP setting value
Dan Smith
Sun Oct 20 07:45:12 PDT 2013
> + options = ["5.00K", "6.25K", "10.00K", "12.50K", "20.00K", "25.00K"]
> + if _mem.step != 0xFF:
> + val1 = _mem.step
> + else:
> + val1 = 0
> + rs = RadioSetting("step", "Steps",
> + RadioSettingValueList(options,
> + options[val1]))
> + mem.extra.append(rs)
> +
Hmm, this is exposing step as a feature for the channel, but I think it
should expose it properly in mem.tuning_step like the rest of them. We
keep the mem.features as a grab-bag of non-standard things that chirp
doesn't really support natively (like, voice scrambler, etc). But, we
have a field for tuning_step.
So, I think you need to expose a set of valid_tuning_steps in
get_features() and populate mem.tuning_step with something from that
list. It should be mostly like what you've got here, although (very
roughly):
VALID_STEPS = [5.0, 6.25, 10.0, 12.5, 20.0, 25.0]
def get_features(self):
...
rf.valid_tuning_steps = VALID_STEPS
rf.has_tuning_step = True
def get_memory(self, number):
...
mem.tuning_step = VALID_STEPS[_mem.step]
This will make it show up in the spreadsheet view like the other radios.
Make sense?
Thanks Jim!
--
Dan Smith
www.danplanet.com
KK7DS
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 490 bytes
Desc: OpenPGP digital signature
Url : http://intrepid.danplanet.com/pipermail/chirp_devel/attachments/20131020/2b852b6a/attachment-0001.bin
More information about the chirp_devel
mailing list