Repository: pwr-Solaar/Solaar

Issue:
Being able to disable onboard profiles of at least G502 SE Hero Logitech Mouse is removed in newest version.
**Information**
<!-- The version of Solaar in this repository has more features than released versions.  Update to this version before asking for a new feature. -->
- Solaar version (`solaar --version` and `git describe --tags`): 1.1.11
- Distribution: Arch Linux
- Kernel version (ex. `uname -srmo`): Linux 6.7.5-arch1-1 x86_64 GNU/Linux
- Output of `solaar show` for the target device (if applicable): 


<details>

```
solaar version 1.1.11


G502 SE Hero Gaming Mouse
     Device path  : /dev/hidraw5
     USB id       : 046d:C08B
     Codename     : G502 Hero
     Kind         : mouse
     Protocol     : HID++ 4.2
     Report Rate : 2ms
     Serial number: 
     Model ID:      C08B00000000
     Unit ID:       3531470E
          Firmware: U1  27.03.B0010
        Bootloader: BOT 81.00.B0002
     Supports 19 HID++ 2.0 features:
         0: ROOT                   {0000} V0     
         1: FEATURE SET            {0001} V0     
         2: COLOR LED EFFECTS      {8070} V3     
            LED Control (saved): Device
            LED Control        : Device
            LEDs Primary        : None
            LEDs Logo        : None
         3: DEVICE FW VERSION      {0003} V2     
            Firmware: Firmware U1  27.03.B0010 C08B
            Firmware: Bootloader BOT 81.00.B0002 AAE6
            Unit ID: 3531470E  Model ID: C08B00000000  Transport IDs: {'usbid': 'C08B'}
         4: DEVICE NAME            {0005} V0     
            Name: G502 HERO Gaming Mouse
            Kind: mouse
         5: LED CONTROL            {1300} V0     
         6: unknown:18A1           {18A1} V0    internal, hidden 
         7: unknown:1E00           {1E00} V0    hidden 
         8: unknown:1E22           {1E22} V0    internal, hidden 
         9: unknown:1EB0           {1EB0} V0    internal, hidden 
        10: ADJUSTABLE DPI         {2201} V1     
            Sensitivity (DPI) (saved): 2400
            Sensitivity (DPI)        : 2400
        11: REPORT RATE            {8060} V0     
            Report Rate: 2ms
            Report Rate (saved): 2ms
            Report Rate        : 2ms
        12: ONBOARD PROFILES       {8100} V0     
            Device Mode: Host
        13: MOUSE BUTTON SPY       {8110} V0     
        14: DFUCONTROL SIGNED      {00C2} V0     
        15: unknown:1801           {1801} V0    internal, hidden 
        16: DEVICE RESET           {1802} V0    internal, hidden 
        17: CONFIG DEVICE PROPS    {1806} V5    internal, hidden 
        18: unknown:18B1           {18B1} V0    internal, hidden 
     Battery status unavailable.
```
</details>


**Is your feature request related to a problem? Please describe.**
Newest version removes the feature of disabling onboard profiles.

**Describe the solution you'd like**
Returning the feature. 

**Describe alternatives you've considered**
Probably being able to create and remove profiles.

**Additional context**
If it was not clear, I mean this feature.
![image](https://github.com/pwr-Solaar/Solaar/assets/91419952/b9a11f1a-e982-4052-9f2f-b693f641f2c1)



Discussion:
I reverted to previous version(1.1.10), so I guess it is not supposed to be an urgent update.
I have a similar mouse and this is what I see in 1.1.11:
![Screenshot from 2024-02-19 10-41-47](https://github.com/pwr-Solaar/Solaar/assets/6618235/73bc6fa0-7d54-47de-83e4-0f2b5b958d98)

What are the contents of `~/.config/solaar/config.yaml`?
Run Solaar version 1.1.11 as `solaar -ddd` and post the output.  Expect that the field for Onboard Profiles may first show up as blank, but when you unlock it and click on the choice box you will be shown several alternatives.  This is due to an upgrade to the setting that now allows you to switch between onboard profiles and dump, edit, and load onboard profiles.  (See the release notes for 1.1.11.)
```
- 1.1.11
- _NAME: G502 SE Hero Gaming Mouse
  _absent: [hi-res-scroll, lowres-scroll-mode, hires-smooth-invert, hires-smooth-resolution, hires-scroll-mode, scroll-ratchet, smart-shift, thumb-scroll-invert,
    thumb-scroll-mode, report_rate_extended, pointer_speed, speed-change, backlight, backlight_level, backlight_duration_hands_out, backlight_duration_hands_in,
    backlight_duration_powered, backlight-timed, fn-swap, reprogrammable-keys, persistent-remappable-keys, divert-keys, disable-keyboard-keys, crown-smooth,
    divert-crown, divert-gkeys, m-key-leds, mr-key-led, multiplatform, change-host, gesture2-gestures, gesture2-divert, gesture2-params, sidetone, equalizer,
    adc_power_management]
  _battery: 0x0
  _modelId: C08B00000000
  _sensitive: {dpi: false, led_control: false, onboard_profiles: false, report_rate: false}
  _unitId: 3531470E
  dpi: 0x960
  led_control: 0x0
  onboard_profiles: 0x2
  report_rate: 0x2
```

Running `solaar -ddd` opens this window 
![image](https://github.com/pwr-Solaar/Solaar/assets/91419952/644ee0ed-f013-42e6-842b-9a84a563f71f)
and in the terminal returns this

<details>


```
2024-02-19 19:47:43,121,121     INFO [MainThread] solaar.gtk: version 1.1.11, language en_US (UTF-8)
2024-02-19 19:47:43,209,209     INFO [MainThread] logitech_receiver.diversion: GDK Keymap set up
2024-02-19 19:47:43,215,215    DEBUG [MainThread] solaar.ui.tray: using StatusIcon
2024-02-19 19:47:43,218,218     INFO [MainThread] solaar.upower: connected to system dbus, watching for suspend/resume events
2024-02-19 19:47:43,220,220    DEBUG [MainThread] solaar.ui: startup registered=True, remote=False
2024-02-19 19:47:43,220,220    DEBUG [AsyncUI] solaar.tasks: started
2024-02-19 19:47:43,220,220     INFO [MainThread] solaar.ui.notify: starting desktop notifications
2024-02-19 19:47:43,246,246     INFO [MainThread] solaar.listener: starting receiver listening threads
2024-02-19 19:47:43,324,324  WARNING [MainThread] hidapi.udev: Report Descriptor not processed for DEVICE /dev/hidraw0 BID 0003 VID 000003F0 PID 00000B92: Expecting 16 usages but got 1
2024-02-19 19:47:43,328,328  WARNING [MainThread] hidapi.udev: Report Descriptor not processed for DEVICE /dev/hidraw2 BID 0003 VID 00001A2C PID 00004C5E: Expecting 48 usages but got 256
2024-02-19 19:47:43,331,331     INFO [MainThread] hidapi.udev: Found device /dev/hidraw5 BID 0003 VID 0000046D PID 0000C08B HID++ True True USB 1 1
2024-02-19 19:47:43,331,331     INFO [MainThread] solaar.listener: receiver event add DeviceInfo(path='/dev/hidraw5', bus_id=3, vendor_id='046D', product_id='C08B', interface=1, driver='hid-generic', manufacturer=None, product=None, serial='0E82314E3138', release=None, isDevice=True, hidpp_short=True, hidpp_long=True)
2024-02-19 19:47:43,331,331     INFO [MainThread] hidapi.udev: OPEN PATH /dev/hidraw5
2024-02-19 19:47:43,331,331     INFO [ReceiverListener:hidraw5] logitech_receiver.listener: started with <Device(255,C08B,G502 SE Hero Gaming Mouse,)> (14)
2024-02-19 19:47:43,331,331     INFO [ReceiverListener:hidraw5] solaar.listener: <Device(255,C08B,G502 SE Hero Gaming Mouse,)>: notifications listener has started (14)
2024-02-19 19:47:43,331,331    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) pinging device 255
2024-02-19 19:47:43,331,331     INFO [ReceiverListener:hidraw5] logitech_receiver.base: New lock <_ThreadedHandle(/dev/hidraw5)>
2024-02-19 19:47:43,331,331    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 001F 00006700000000000000000000000000]
2024-02-19 19:47:43,332,332    DEBUG [MainThread] solaar.ui: activate
2024-02-19 19:47:43,335,335    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 001F 04026700000000000000000000000000]
2024-02-19 19:47:43,335,335     INFO [ReceiverListener:hidraw5] solaar.listener: status_changed <Device(255,C08B,G502 SE Hero Gaming Mouse,)>: paired online, {'NOTIFICATION FLAGS': False} (0) 
2024-02-19 19:47:43,336,336    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) pinging device 255
2024-02-19 19:47:43,336,336    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 001D 0000E500000000000000000000000000]
2024-02-19 19:47:43,339,339    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 001D 0402E500000000000000000000000000]
2024-02-19 19:47:43,341,341    DEBUG [ReceiverListener:hidraw5] solaar.configuration: load => ['1.1.11', {'_NAME': 'G502 SE Hero Gaming Mouse', '_absent': ['hi-res-scroll', 'lowres-scroll-mode', 'hires-smooth-invert', 'hires-smooth-resolution', 'hires-scroll-mode', 'scroll-ratchet', 'smart-shift', 'thumb-scroll-invert', 'thumb-scroll-mode', 'report_rate_extended', 'pointer_speed', 'speed-change', 'backlight', 'backlight_level', 'backlight_duration_hands_out', 'backlight_duration_hands_in', 'backlight_duration_powered', 'backlight-timed', 'fn-swap', 'reprogrammable-keys', 'persistent-remappable-keys', 'divert-keys', 'disable-keyboard-keys', 'crown-smooth', 'divert-crown', 'divert-gkeys', 'm-key-leds', 'mr-key-led', 'multiplatform', 'change-host', 'gesture2-gestures', 'gesture2-divert', 'gesture2-params', 'sidetone', 'equalizer', 'adc_power_management'], '_battery': 0, '_modelId': 'C08B00000000', '_sensitive': {'dpi': False, 'led_control': False, 'onboard_profiles': False, 'report_rate': False}, '_unitId': '3531470E', 'dpi': 2400, 'led_control': 0, 'onboard_profiles': 2, 'report_rate': 2}]
2024-02-19 19:47:43,341,341    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 000F 00010000000000000000000000000000]
2024-02-19 19:47:43,345,345    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 000F 01000100000000000000000000000000]
2024-02-19 19:47:43,345,345    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 010E 00000000000000000000000000000000]
2024-02-19 19:47:43,349,349    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 010E 12000000000000000000000000000000]
2024-02-19 19:47:43,349,349    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0008 00030000000000000000000000000000]
2024-02-19 19:47:43,350,350    DEBUG [MainThread] solaar.ui: status changed: <Device(255,C08B,G502 SE Hero Gaming Mouse,)> (NONE) None
2024-02-19 19:47:43,350,350    DEBUG [MainThread] solaar.ui.icons: icon theme paths: ['/home/bogo/.local/share/icons', '/home/bogo/.icons', '/home/bogo/.local/share/flatpak/exports/share/icons', '/var/lib/flatpak/exports/share/icons', '/usr/local/share/icons', '/usr/share/icons', '/home/bogo/.local/share/flatpak/exports/share/pixmaps', '/var/lib/flatpak/exports/share/pixmaps', '/usr/local/share/pixmaps', '/usr/share/pixmaps']
2024-02-19 19:47:43,350,350    DEBUG [MainThread] solaar.ui.icons: battery icon for None:None = battery-missing
2024-02-19 19:47:43,350,350    DEBUG [MainThread] solaar.ui.tray: picked device with lowest battery: None
2024-02-19 19:47:43,352,352    DEBUG [MainThread] solaar.ui.window: new device row ('/dev/hidraw5', 255, True, 'G502 Hero', 'input-mouse', None, None, <Device(255,C08B,G502 SE Hero Gaming Mouse,)>) at index 0
2024-02-19 19:47:43,353,353    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0008 03000200000000000000000000000000]
2024-02-19 19:47:43,353,353     INFO [MainThread] hidapi.udev: OPEN PATH /dev/hidraw5
2024-02-19 19:47:43,353,353    DEBUG [MainThread] logitech_receiver.base: (23) <= w[11 FF 0009 00030000000000000000000000000000]
2024-02-19 19:47:43,357,357    DEBUG [MainThread] logitech_receiver.base: (23) => r[11 FF 0009 03000200000000000000000000000000]
2024-02-19 19:47:43,357,357    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 030C 00000000000000000000000000000000]
2024-02-19 19:47:43,361,361    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 030C 023531470E0008C08B00000000000000]
2024-02-19 19:47:43,361,361    DEBUG [MainThread] logitech_receiver.base: (23) <= w[11 FF 030C 00000000000000000000000000000000]
2024-02-19 19:47:43,365,365    DEBUG [MainThread] logitech_receiver.base: (23) => r[11 FF 030C 023531470E0008C08B00000000000000]
2024-02-19 19:47:43,365,365    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 000D 81000000000000000000000000000000]
2024-02-19 19:47:43,369,369    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 000D 0C000000000000000000000000000000]
2024-02-19 19:47:43,369,369    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0C5C 00000000000000000000000000000000]
2024-02-19 19:47:43,373,373    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0C5C 00000000000000000000000000000000]
2024-02-19 19:47:43,373,373    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0C5A 01000000000000000000000000000000]
2024-02-19 19:47:43,377,377    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0C5A 010101FF010201FF010301FF010401FF]
2024-02-19 19:47:43,377,377    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0C5C 01000004000000000000000000000000]
2024-02-19 19:47:43,381,381    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0C5C 010201FF010301FF010401FF010501FF]
2024-02-19 19:47:43,381,381    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0C58 01000008000000000000000000000000]
2024-02-19 19:47:43,385,385    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0C58 010301FF010401FF010501FFFFFF5531]
2024-02-19 19:47:43,385,385    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0C59 0100000C000000000000000000000000]
2024-02-19 19:47:43,389,389    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0C59 010401FF010501FFFFFF553132372E30]
2024-02-19 19:47:43,389,389    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0C59 01000010000000000000000000000000]
2024-02-19 19:47:43,393,393    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0C59 010501FFFFFF553132372E30335F4230]
2024-02-19 19:47:43,393,393    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0C5D 01000014000000000000000000000000]
2024-02-19 19:47:43,397,397    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0C5D FFFF553132372E30335F423030313000]
2024-02-19 19:47:43,398,398    ERROR [ReceiverListener:hidraw5] logitech_receiver.settings_templates: check_feature onboard_profiles [ONBOARD PROFILES] error int() argument must be a string, a bytes-like object or a real number, not 'NoneType'
Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/logitech_receiver/settings_templates.py", line 1531, in check_feature
    detected = sclass.build(device)
               ^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/logitech_receiver/settings.py", line 240, in build
    validator = validator_class.build(cls, device, **cls.validator_options)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/logitech_receiver/settings_templates.py", line 488, in build
    return cls(choices=_NamedInts.list(profiles_list), byte_count=2) if len(profiles_list) > 1 else None
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/logitech_receiver/common.py", line 156, in list
    return NamedInts(**values)
           ^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/logitech_receiver/common.py", line 143, in __init__
    values = {k: NamedInt(v, _readable_name(k)) for (k, v) in elements.items()}
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/logitech_receiver/common.py", line 143, in <dictcomp>
    values = {k: NamedInt(v, _readable_name(k)) for (k, v) in elements.items()}
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/logitech_receiver/common.py", line 73, in __new__
    obj = int.__new__(cls, value)
          ^^^^^^^^^^^^^^^^^^^^^^^
TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType'

2024-02-19 19:47:43,398,398    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 000E 80600000000000000000000000000000]
2024-02-19 19:47:43,403,403    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 000E 0B000000000000000000000000000000]
2024-02-19 19:47:43,403,403    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0B08 00000000000000000000000000000000]
2024-02-19 19:47:43,407,407    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0B08 8B000000000000000000000000000000]
2024-02-19 19:47:43,407,407    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings_templates: check_feature report_rate [REPORT RATE] detected <Setting([feature:choice] G502 Hero:report_rate=None)>
2024-02-19 19:47:43,407,407    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0009 22010000000000000000000000000000]
2024-02-19 19:47:43,411,411    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0009 0A000100000000000000000000000000]
2024-02-19 19:47:43,411,411    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0A1E 00000000000000000000000000000000]
2024-02-19 19:47:43,415,415    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0A1E 000064E0326400000000000000000000]
2024-02-19 19:47:43,416,416    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings_templates: check_feature dpi [ADJUSTABLE DPI] detected <Setting([feature:choice] G502 Hero:dpi=None)>
2024-02-19 19:47:43,416,416    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 000B 80700000000000000000000000000000]
2024-02-19 19:47:43,421,421    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 000B 02000300000000000000000000000000]
2024-02-19 19:47:43,421,421    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings_templates: check_feature led_control [COLOR LED EFFECTS] detected <Setting([feature:choice] G502 Hero:led_control=None)>
2024-02-19 19:47:43,421,421    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 020C 00000000000000000000000000000000]
2024-02-19 19:47:43,425,425    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 020C 02000300000000000000000000000000]
2024-02-19 19:47:43,425,425    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 021C 00000000000000000000000000000000]
2024-02-19 19:47:43,429,429    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 021C 00000104000000000000000000000000]
2024-02-19 19:47:43,429,429    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0229 00000000000000000000000000000000]
2024-02-19 19:47:43,433,433    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0229 00000000000000000000000000000000]
2024-02-19 19:47:43,433,433    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 022A 00010000000000000000000000000000]
2024-02-19 19:47:43,437,437    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 022A 00010001000500000000000000000000]
2024-02-19 19:47:43,437,437    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 022C 00020000000000000000000000000000]
2024-02-19 19:47:43,441,441    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 022C 0002000AC00503E00000000000000000]
2024-02-19 19:47:43,441,441    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0229 00030000000000000000000000000000]
2024-02-19 19:47:43,445,445    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0229 00030003C00503E00000000000000000]
2024-02-19 19:47:43,445,445    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0219 01000000000000000000000000000000]
2024-02-19 19:47:43,449,449    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0219 01000204000000000000000000000000]
2024-02-19 19:47:43,449,449    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 022C 01000000000000000000000000000000]
2024-02-19 19:47:43,453,453    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 022C 01000000000000000000000000000000]
2024-02-19 19:47:43,453,453    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0228 01010000000000000000000000000000]
2024-02-19 19:47:43,457,457    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0228 01010001000500000000000000000000]
2024-02-19 19:47:43,457,457    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0229 01020000000000000000000000000000]
2024-02-19 19:47:43,461,461    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0229 0102000AC00503E00000000000000000]
2024-02-19 19:47:43,461,461    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 022A 01030000000000000000000000000000]
2024-02-19 19:47:43,465,465    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 022A 01030003C00503E00000000000000000]
2024-02-19 19:47:43,465,465    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings_templates: check_feature led_zone_ [COLOR LED EFFECTS] detected [<Setting([feature:hetero] G502 Hero:led_zone_1=None)>, <Setting([feature:hetero] G502 Hero:led_zone_2=None)>]
2024-02-19 19:47:43,466,466     INFO [ReceiverListener:hidraw5] logitech_receiver.status: <Device(255,C08B,G502 SE Hero Gaming Mouse,)> pushing device settings [<Setting([feature:choice] G502 Hero:report_rate=None)>, <Setting([feature:choice] G502 Hero:dpi=None)>, <Setting([feature:choice] G502 Hero:led_control=None)>, <Setting([feature:hetero] G502 Hero:led_zone_1=None)>, <Setting([feature:hetero] G502 Hero:led_zone_2=None)>]
2024-02-19 19:47:43,466,466    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 000F 21210000000000000000000000000000]
2024-02-19 19:47:43,467,467    DEBUG [AsyncUI] logitech_receiver.settings: report_rate: cached value 2 on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,469,469    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 000F 00000000000000000000000000000000]
2024-02-19 19:47:43,469,469    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: report_rate: apply (<Device(255,C08B,G502 SE Hero Gaming Mouse,)>)
2024-02-19 19:47:43,469,469    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: report_rate: cached value 2 on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,469,469    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: report_rate: write 2 to <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,469,469    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: report_rate: prepare write(2) => b'\x02'
2024-02-19 19:47:43,469,469    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0B2E 02000000000000000000000000000000]
2024-02-19 19:47:43,472,472    DEBUG [AsyncUI] logitech_receiver.settings: dpi: cached value 2400 on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,472,472    DEBUG [AsyncUI] logitech_receiver.settings: led_control: cached value 0 on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,473,473    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0B2E 00000000000000000000000000000000]
2024-02-19 19:47:43,473,473    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: dpi: apply (<Device(255,C08B,G502 SE Hero Gaming Mouse,)>)
2024-02-19 19:47:43,473,473    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: dpi: cached value 2400 on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,473,473    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: dpi: write 2400 to <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,473,473    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: dpi: prepare write(2400) => b'\x00\t`'
2024-02-19 19:47:43,473,473    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0A3D 00096000000000000000000000000000]
2024-02-19 19:47:43,478,478    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0A3D 00000000000000000000000000000000]
2024-02-19 19:47:43,478,478    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: led_control: apply (<Device(255,C08B,G502 SE Hero Gaming Mouse,)>)
2024-02-19 19:47:43,478,478    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: led_control: cached value 0 on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,478,478    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: led_control: write 0 to <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,478,478    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: led_control: prepare write(0) => b'\x00'
2024-02-19 19:47:43,478,478     INFO [AsyncUI] hidapi.udev: OPEN PATH /dev/hidraw5
2024-02-19 19:47:43,478,478    DEBUG [AsyncUI] logitech_receiver.base: (24) <= w[11 FF 02EA 00000000000000000000000000000000]
2024-02-19 19:47:43,482,482    DEBUG [AsyncUI] logitech_receiver.base: (24) => r[11 FF 02EA 0001FFFFFF0000000000000000000000]
2024-02-19 19:47:43,482,482    DEBUG [AsyncUI] logitech_receiver.settings: led_zone_1: read value None on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,482,482    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 028A 00000000000000000000000000000000]
2024-02-19 19:47:43,486,486    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 028A 00000000000000000000000000000000]
2024-02-19 19:47:43,486,486    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: led_zone_1: apply (<Device(255,C08B,G502 SE Hero Gaming Mouse,)>)
2024-02-19 19:47:43,486,486    DEBUG [AsyncUI] logitech_receiver.base: (24) <= w[11 FF 02EF 01000000000000000000000000000000]
2024-02-19 19:47:43,491,491    DEBUG [AsyncUI] logitech_receiver.base: (24) => r[11 FF 02EF 0101FFFFFF0000000000000000000000]
2024-02-19 19:47:43,491,491    DEBUG [AsyncUI] logitech_receiver.settings: led_zone_2: read value None on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,491,491    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 02EF 00000000000000000000000000000000]
2024-02-19 19:47:43,495,495    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 02EF 0001FFFFFF0000000000000000000000]
2024-02-19 19:47:43,495,495    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: led_zone_1: read value None on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,495,495    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: led_zone_2: apply (<Device(255,C08B,G502 SE Hero Gaming Mouse,)>)
2024-02-19 19:47:43,495,495    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 02EE 01000000000000000000000000000000]
2024-02-19 19:47:43,499,499    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 02EE 0101FFFFFF0000000000000000000000]
2024-02-19 19:47:43,499,499    DEBUG [ReceiverListener:hidraw5] logitech_receiver.settings: led_zone_2: read value None on <Device(255,C08B,G502 SE Hero Gaming Mouse,)>
2024-02-19 19:47:43,499,499    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) pinging device 255
2024-02-19 19:47:43,499,499    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) <= w[11 FF 0018 00008300000000000000000000000000]
2024-02-19 19:47:43,503,503    DEBUG [ReceiverListener:hidraw5] logitech_receiver.base: (14) => r[11 FF 0018 04028300000000000000000000000000]
2024-02-19 19:47:43,503,503     INFO [ReceiverListener:hidraw5] solaar.listener: status_changed <Device(255,C08B,G502 SE Hero Gaming Mouse,)>: paired online, {'NOTIFICATION FLAGS': False} (0) initialization
2024-02-19 19:47:43,503,503    DEBUG [MainThread] solaar.ui: status changed: <Device(255,C08B,G502 SE Hero Gaming Mouse,)> (NONE) initialization
2024-02-19 19:47:43,503,503    DEBUG [MainThread] solaar.ui.icons: battery icon for None:None = battery-missing
2024-02-19 19:47:43,504,504    DEBUG [MainThread] solaar.ui.tray: picked device with lowest battery: None
```

</details>

This is what it looked like in the previous version
![image](https://github.com/pwr-Solaar/Solaar/assets/91419952/cd5953f3-7c03-4cfe-b965-6e7aa87e8548)
It looks as if your mouse is returning information that Solaar is not expecting.  Do you know how many onboard profiles your mouse has?
Sorry, I can't say for sure, but I believe it's either 5 or 11.
Five might be the number in marketing material.    What counts is the number of profile sectors that have been created.

In any case, PR #2314 should fix your problem (given the information I have on onboard profiles.)  If not, post output of `bin/solaar -ddd`.

To clone and use Solar from its GitHub repository
```
git clone https://github.com/pwr-Solaar/Solaar.git
cd Solaar
```
Run Solaar as bin/solaar from this directory.


To run PR #2314, first clone Solaar if you have not already done so and cd to the clone directory.  The first time you download the pull request, fetch it into a new branch and checkout that branch, as in:
```
git fetch origin pull/2314/head:pull_2314
git checkout pull_2314
```
To download a new version of the pull request, fetch it and then set your pull branch to the new fetch, as in:
```
git checkout pull_2314
git fetch origin pull/2314/head
git reset --hard FETCH_HEAD
```


Resolving patch:
diff --git a/lib/logitech_receiver/__init__.py b/lib/logitech_receiver/__init__.py
--- a/lib/logitech_receiver/__init__.py
+++ b/lib/logitech_receiver/__init__.py
@@ -15,27 +15,12 @@
 ## You should have received a copy of the GNU General Public License along
 ## with this program; if not, write to the Free Software Foundation, Inc.,
 ## 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-"""Low-level interface for devices connected through a Logitech Universal
-Receiver (UR).
+"""Low-level interface for devices using Logitech HID++ protocol.
 
 Uses the HID api exposed through hidapi.py, a Python thin layer over a native
 implementation.
-
-Incomplete. Based on a bit of documentation, trial-and-error, and guesswork.
-
-References:
-http://julien.danjou.info/blog/2012/logitech-k750-linux-support
-http://6xq.net/git/lars/lshidpp.git/plain/doc/
 """
 
 import logging
 
 logger = logging.getLogger(__name__)
-logger.setLevel(logging.root.level)
-# if logging.root.level > logging.DEBUG:
-#     logger.addHandler(logging.NullHandler())
-#     logger.propagate = 0
-
-del logging
-
-__version__ = "0.9"
diff --git a/lib/logitech_receiver/descriptors.py b/lib/logitech_receiver/descriptors.py
--- a/lib/logitech_receiver/descriptors.py
+++ b/lib/logitech_receiver/descriptors.py
@@ -226,7 +226,7 @@ def get_btid(btid):
 _D("Wireless Illuminated Keyboard K800 new", codename="K800 new", protocol=4.5, wpid="406E")
 _D("Wireless Keyboard K470", codename="K470", protocol=4.5, wpid="4075")
 _D("MX Keys Keyboard", codename="MX Keys", protocol=4.5, wpid="408A", btid=0xB35B)
-_D("G915 TKL LIGHTSPEED Wireless RGB Mechanical Gaming Keyboard", codename="G915 TKL", protocol=4.2, wpid="408E", sbid=0xC343)
+_D("G915 TKL LIGHTSPEED Wireless RGB Mechanical Gaming Keyboard", codename="G915 TKL", protocol=4.2, wpid="408E", usbid=0xC343)
 _D("Illuminated Keyboard", codename="Illuminated", protocol=1.0, usbid=0xC318, interface=1)
 _D("G213 Prodigy Gaming Keyboard", codename="G213", usbid=0xC336, interface=1)
 _D("G512 RGB Mechanical Gaming Keyboard", codename="G512", usbid=0xC33C, interface=1)
diff --git a/lib/logitech_receiver/settings_templates.py b/lib/logitech_receiver/settings_templates.py
--- a/lib/logitech_receiver/settings_templates.py
+++ b/lib/logitech_receiver/settings_templates.py
@@ -498,8 +498,9 @@ class OnboardProfiles(_Setting):
     description = _("Enable an onboard profile, which controls report rate, sensitivity, and button actions")
     feature = _F.ONBOARD_PROFILES
     choices_universe = _NamedInts(Disabled=0)
-    for i in range(1, 6):
+    for i in range(1, 16):
         choices_universe[i] = f"Profile {i}"
+        choices_universe[i + 0x100] = f"Read-Only Profile {i}"
     validator_class = _ChoicesV
 
     class rw_class:
@@ -531,7 +532,7 @@ def build(cls, setting_class, device):
             profiles_list = [setting_class.choices_universe[0]]
             if headers:
                 for sector, enabled in headers:
-                    if enabled:
+                    if enabled and setting_class.choices_universe[sector]:
                         profiles_list.append(setting_class.choices_universe[sector])
             return cls(choices=_NamedInts.list(profiles_list), byte_count=2) if len(profiles_list) > 1 else None
 


Test patch: