-
Notifications
You must be signed in to change notification settings - Fork 0
Description
Summary
As expressed in JnyJny/busylight#417 (I have left a comment there explaining it)
TLDR: Windows HID driver API requires an additional mandatory byte before the data buffer when writing. This byte is the Report ID, and it can be left as 0x00
for most, if not all HID devices here.
Afaik in Linux, this Report ID also exists as a byte before the data buffer, BUT it may be omitted when devices only have a single supported HID report, unlike Windows, hence why it has been working. So this should probably also be addressed in case where a device has multiple supported reports.
Devices using Serial communication should not be affected by this, and will cause issues if treated the same JnyJny/busylight#439 JnyJny/busylight#437
Hence, currently match self.platform
in light.py
is incorrect, as:
Windows 11
is not an exception to this HID behavior (verified by trying to use a Luxafor Flag, it fails because it requires this byte)- Devices using Serial communication should not have this byte added (haven't tested it yet, but the expected behavior is that devices like BusyTag will fail on
Windows 10
)
Due to this, the previously attempted fix JnyJny/busylight#450 was also incorrect
@JnyJny Hope this will be of help in understanding when to add this additional byte :)
Platform
Windows 11 x86_64
Version
uvx busylight v0.45.1
Python version
Python 3.12.6