HID++ 2.0 'set' operations (SetSidetone, SetAutoSleep, SetMicGain etc.) frequently respond with an empty ACK — just the echoed request_id with no data bytes after. device.feature_request() strips the request_id echo and returns the remaining payload, so our reply variable is b"" for these successful writes. The old check `if not reply:` evaluates b"" as falsy, so we returned None from Setting.write, which the GUI interpreted as "Read/write operation failed" — even though the device actually succeeded. Change the check to `if reply is None:` so empty bytes (success) pass through and only genuine transport failures (None return from base.request) are flagged as errors. Also add an INFO log on the real failure path so the user can tell from the log whether a write reached the device. This likely fixes the G522 sidetone / mic-gain / auto-sleep "Read/write operation failed" reports — all of those features return empty ACKs for set operations. |
||
|---|---|---|
| .. | ||
| hid_parser | ||
| hidapi | ||
| keysyms | ||
| logitech_receiver | ||
| solaar | ||