diff options
author | NicoHood <NicoHood@users.noreply.github.com> | 2015-10-10 12:49:45 +0200 |
---|---|---|
committer | NicoHood <NicoHood@users.noreply.github.com> | 2015-10-10 12:49:45 +0200 |
commit | e3977037aea0a8cf4e4b9d518c39747514745e7c (patch) | |
tree | a2f309daa6d5dae392d4612812852baa18dd73d3 /libraries/HID/HID.h | |
parent | 290167f705edd807e21c492578ba2413bb665b6c (diff) |
Added official HID definitions
Since the HID library adds some general HID definitions and structs, it is very useful to also include this in a custom library.
If you dupe the information you have problems of redeclaration.
Having those defintions inside the official HID library is essential for a good working additional HID API.
Diffstat (limited to 'libraries/HID/HID.h')
-rw-r--r-- | libraries/HID/HID.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/libraries/HID/HID.h b/libraries/HID/HID.h index b282c20..77a9f24 100644 --- a/libraries/HID/HID.h +++ b/libraries/HID/HID.h @@ -40,6 +40,20 @@ #define HID_REPORT_DESCRIPTOR_TYPE 0x22 #define HID_PHYSICAL_DESCRIPTOR_TYPE 0x23 +// HID subclass HID1.11 Page 8 4.2 Subclass +#define HID_SUBCLASS_NONE 0 +#define HID_SUBCLASS_BOOT_INTERFACE 1 + +// HID Keyboard/Mouse bios compatible protocols HID1.11 Page 9 4.3 Protocols +#define HID_PROTOCOL_NONE 0 +#define HID_PROTOCOL_KEYBOARD 1 +#define HID_PROTOCOL_MOUSE 2 + +// Normal or bios protocol (Keyboard/Mouse) HID1.11 Page 54 7.2.5 Get_Protocol Request +// "protocol" variable is used for this purpose. +#define HID_BOOT_PROTOCOL 0 +#define HID_REPORT_PROTOCOL 1 + typedef struct { uint8_t len; // 9 |