<div dir="ltr"><div>There are only the two lists so far and there may never be another, so I suppose we could. However, it's not the same</div><div>for all radio variants. I wanted to make this explicit, so I built the "legal" list on a radio-by-radio basis to make it clear</div><div>that each new variant will need to decide on its own list. the It's a stylistic choice, but I thought the "remove" construct</div><div>was better as a self-documenting way to make it clear that the legal list must be a subset of the coded list.<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Feb 28, 2019 at 6:52 AM Dan Smith via chirp_devel <<a href="mailto:chirp_devel@intrepid.danplanet.com">chirp_devel@intrepid.danplanet.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">> @@ -1023,7 +1018,22 @@<br>
> Pkeys = 2 # number of programmable keys on the FT-4<br>
> namelen = 6 # length of the mem name display on the FT-4 front-panel<br>
> id_str = b'IFT-35R\x00\x00V100\x00\x00'<br>
> -<br>
> + # names for the setmode function for the programmable keys. Mode zero means<br>
> + # that the key is programmed for a memory not a setmode.<br>
> + SETMODES = [<br>
> + "mem", "apo", "ar bep", "ar int", "beclo", #00-04<br>
> + "beep", "bell", "cw id", "cw wrt", "dc vlt", #05-09<br>
> + "dcs cod", "dt dly", "dt set", "dtc spd", "edg.bep", #10-14<br>
> + "lamp", "led.bsy", "led.tx", "lock", "m/t-cl", #15-19<br>
> + "mem.del", "mem.tag", "pag.abk", "pag.cdr", "pag.cdt", #20-24<br>
> + "pri.rvt", "pswd", "pswdwt", "rf sql", "rpt.ars", #25-29<br>
> + "rpt.frq", "rpt.sft", "rxsave", "scn.lmp", "scn.rsm", #30-34<br>
> + "skip", "sql.typ", "step", "tn frq", "tot", #35-39<br>
> + "tx pwr", "tx save", "vfo.spl", "vox", "wfm.rcv", #40-44<br>
> + "w/n.dev", "wx.alert" #45-46<br>
> + ]<br>
> + legal_steps = list(STEP_CODE)<br>
> + legal_steps.remove(6.25) #should not remove if euro version<br>
> <br>
> # don't register the FT-65 in the production version until it is tested<br>
> # @directory.register<br>
> @@ -1038,7 +1048,6 @@<br>
> # VHF, RX (136000000, 174000000)<br>
> # UHF, RX (400000000, 480000000)<br>
> ]<br>
> - valid_bands = [(108000000, 520000000), (700000000, 999990000)]<br>
> _valid_chars = chirp_common.CHARSET_ASCII<br>
> numblocks = 0x215 # number of 16-byte blocks in the radio<br>
> _memsize = 16 * numblocks # used by CHIRP file loader to guess radio type<br>
> @@ -1046,4 +1055,20 @@<br>
> Pkeys = 4 # number of programmable keys on the FT-65<br>
> namelen = 8 # length of the mem name display on the FT-65 front panel<br>
> id_str=b'IH-420\x00\x00\x00V100\x00\x00'<br>
> + # names for the setmode function for the programmable keys. Mode zero means<br>
> + # that the key is programmed for a memory not a setmode.<br>
> + SETMODES = [<br>
> + "mem", "apo", "arts", "battsave", "b-ch.l/o", # 00-04<br>
> + "beep", "bell", "compander", "ctcss", "cw id", # 05-09<br>
> + "dc volt", "dcs code", "dtmf set", "dtmf wrt", "edg bep", # 10-14<br>
> + "key lock", "lamp", "ledbsy", "mem del", "mon/t-cl", # 15-19<br>
> + "name tag", "pager", "password", "pri.rvt", "repeater", # 20-24<br>
> + "resume", "rf.sql", "scn.lamp", "skip", "sql type", # 25-29 <br>
> + "step", "tot", "tx pwr", "tx save", "vfo.spl", # 30-34<br>
> + "vox", "wfm.rcv", "wide/nar", "wx alert", "scramble" # 35-39<br>
> + ]<br>
<br>
This list is the same as the one above, right? Can we define that in one place and use it in both?<br>
<br>
--Dan<br>
<br>
_______________________________________________<br>
chirp_devel mailing list<br>
<a href="mailto:chirp_devel@intrepid.danplanet.com" target="_blank">chirp_devel@intrepid.danplanet.com</a><br>
<a href="http://intrepid.danplanet.com/mailman/listinfo/chirp_devel" rel="noreferrer" target="_blank">http://intrepid.danplanet.com/mailman/listinfo/chirp_devel</a><br>
Developer docs: <a href="http://chirp.danplanet.com/projects/chirp/wiki/Developers" rel="noreferrer" target="_blank">http://chirp.danplanet.com/projects/chirp/wiki/Developers</a><br>
</blockquote></div>