mirror of
https://github.com/spice2x/spice2x.github.io.git
synced 2026-10-01 19:28:19 +03:00
Updated HID lights (markdown)
@@ -8,12 +8,16 @@ The [HID usage spec](https://www.usb.org/sites/default/files/hut1_6.pdf) is main
|
||||
|
||||
For lights, the `LED Page (0x08)` is the most commonly used, but you are not limited to those.
|
||||
|
||||
It also helps to understand how [Windows HID API](https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/hidpi/ns-hidpi-_hidp_caps) works, which is what spice uses. Both `OutputButtonCaps` and `OutputValueCaps` are used. Button caps are on/off values, and value caps are range values (variable brightness).
|
||||
|
||||
## Dumping USB capabilities and testing
|
||||
|
||||
Launch `spice.exe -cfg -sysdump all` to show a dump of HID devices detected by spice.
|
||||
|
||||
To test, go to Lights tab, and open the drop down. Your device should appear there, and you should be able to see the list of output capabilities of your device. Press `Turn On` to have spice send "on" signal to your device over the Windows HID stack.
|
||||
|
||||
Spice does support variable brightness, as long as the output capability you are exposing also exposes a range, not a
|
||||
|
||||
## Sample code
|
||||
|
||||
[Arduino-HID-Lighting](https://github.com/mon/Arduino-HID-Lighting) - read this first.
|
||||
|
||||
Reference in New Issue
Block a user