Project

General

Profile

Actions

Feature #10650

open

Extra memory field cannot display/set integer.

Added by Declan Rieb over 1 year ago. Updated over 1 year ago.

Status:
New
Priority:
Normal
Assignee:
Category:
UI Features
Target version:
Start date:
06/17/2023
Due date:
% Done:

0%

Estimated time:
Chirp Version:
next
Model affected:
(all; FTn most closely)
I read the instructions above:

Description

The FT1D has a per-memory setting allowing the S-Meter to be adjusted (level 1-9). It’s perfect for including as an extra memory value, but mem.extra does not allow the RadioSettingValueInteger() to work (it complains of an "Unsupported mem.extra type”


Files

chirp_debug-z2q7ggv3.txt (2.39 KB) chirp_debug-z2q7ggv3.txt Declan Rieb, 06/17/2023 05:49 PM
Actions #1

Updated by Declan Rieb over 1 year ago

I include a debug from a MODIFIED ft1d.py that implements several boolean and one integer extra display.

Actions #2

Updated by Dan Smith over 1 year ago

  • Category set to UI Features
  • Assignee set to Dan Smith
  • Target version set to chirp-py3

This is just for expanded extra settings in the memory editor, right? Presumably right click->properties works for integers, yeah?

Actions #3

Updated by Declan Rieb over 1 year ago

Yes this is for expanded extra settings. Properties doesn't help because the whole column doesn't appear. ...Integer works fine in the settings menus. Code snippet for extras follows:

def _get_mem_extra(self, mem, _mem):
    mem.extra = RadioSettingGroup('Extra', 'extra')

    ams = _mem.digmode == 1
    rs = RadioSetting('ysf_ams', 'AMS mode',
                      RadioSettingValueBoolean(ams))
    rs.set_doc("Automatic digital mode, only applied to DN")
    mem.extra.append(rs)

...
rs = RadioSetting("smeter", "SQL S-METER",
RadioSettingValueInteger(0, 9, int(_mem.smeter)))
rs.set_doc("S-Meter Squelch level 0-9")
mem.extra.append(rs)

The smeter one brings up the
"WARNING: Unsupported mem.extra type RadioSettingValueInteger"
message and there's no column associated with it.
Warning appears in expand_extra_col() in wxui/memedit.py at line 864; get_column_for_extra() at line 548 seems to specify that only String, ValueList and Boolean are allowed. There might be reasons for not allowing Integer as well? I suppose I could generate a ValueList with integer values instead?

Actions #4

Updated by Dan Smith over 1 year ago

Yeah I just want to make sure I understand what you say is missing. I'm not sure why "properties doesn't help".. the user can still edit them that way, and there's no real need to compare lots of memories' s-meter values right?

Anyway, I can add it, but the reason it's not implemented is because we have no integer-rendering column right now to add it easily. Everything else is a float or choice. Rendering it as a choice seems reasonable since it's just ten options. If it was 0-256 or something then integer would definitely be the way.

Actions #5

Updated by Declan Rieb over 1 year ago

Thanks for the explanation. The extra limitations was a surprise.

That's a plenty good enough reason, especially with a decent workaround available. (Using Float would also be possible, but it's not allowed as an extra either.)

And NOW I get the properties comment. You meant in the Browser tab. Since the field doesn't show via memedit, it's not properties-editable. I can only access it in browser, which is only available in Developer mode.

You can reject or defer this request (until I bollix the ValueList. :))

Actions #6

Updated by Dan Smith over 1 year ago

No, not in the browser, because that wouldn't be usable for regular users. I mean right-click on the memory (or multiples) and choose properties.

But no, we can leave this open and I can add it at some point.

Actions

Also available in: Atom PDF