From 2bc1a5d0083b68fe904a00fc82eaf63b0a5fc2ff Mon Sep 17 00:00:00 2001 From: Michiel van Leeuwen Date: Mon, 4 Nov 2024 14:25:14 +0100 Subject: [PATCH] Add HID class codes --- usb_protocol/types/descriptors/hid.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/usb_protocol/types/descriptors/hid.py b/usb_protocol/types/descriptors/hid.py index e05e557..e314d05 100644 --- a/usb_protocol/types/descriptors/hid.py +++ b/usb_protocol/types/descriptors/hid.py @@ -9,6 +9,18 @@ from ..descriptor import \ DescriptorField, DescriptorNumber, DescriptorFormat +class HidInterfaceClassCodes(IntEnum): + HID = 0x03 + +class HidInterfaceSubclassCodes(IntEnum): + NO_SUBCLASS = 0 + BOOT = 1 + +class HidInterfaceProtocols(IntEnum): + NONE = 0 + KEYBOARD = 1 + MOUSE = 2 + class HidClassSpecificDescriptorTypes(IntEnum): CS_UNDEFINED = 0x20 CS_HID = 0x21