webhid icon indicating copy to clipboard operation
webhid copied to clipboard

Add helpers for reading/writing report fields by usage

Open nondebug opened this issue 5 years ago • 0 comments

The Windows HID API has a number of helper functions for reading and writing report buffers, it would be handy if WebHID offered something similar so that applications can read or write reports without needing to first parse the HIDDevice.collections member.

Initialization HidP_InitializeReportForID

Get field by usage HidP_GetUsages HidP_GetUsagesEx HidP_GetUsageValue HidP_GetScaledUsageValue HidP_GetUsageValueArray

Get field by data index HidP_GetData

Set field by usage HidP_SetUsages HidP_UnsetUsages HidP_SetUsageValue HidP_SetScaledUsageValue HidP_SetUsageValueArray

Set field by data index HidP_SetData

nondebug avatar Dec 02 '20 03:12 nondebug