Make the Arduino HID library work with the firmware.

This commit is contained in:
László Monda
2017-03-04 01:10:20 +01:00
parent cb3b9b362b
commit c49593fe51
3 changed files with 9 additions and 9 deletions

View File

@@ -24,7 +24,7 @@ THE SOFTWARE.
#ifndef __CONSUMER_API_H__
#define __CONSUMER_API_H__
enum ConsumerKeycode : uint16_t {
typedef enum {
// Some keys might only work with linux
CONSUMER_POWER = 0x30,
CONSUMER_SLEEP = 0x32,
@@ -442,6 +442,6 @@ enum ConsumerKeycode : uint16_t {
HID_CONSUMER_AC_SPLIT = 0x29A, // HID type SEL
HID_CONSUMER_AC_DISRIBUTE_HORIZONTALLY = 0x29B, // HID type SEL
HID_CONSUMER_AC_DISTRIBUTE_VERTICALLY = 0x29C, // HID type SEL
};
} consumer_keycode_t;
#endif

View File

@@ -25,7 +25,7 @@ THE SOFTWARE.
#define __IMPROVED_KEY_LAYOUTS_H__
// Hut1_12v2.pdf
enum KeyboardKeycode : uint8_t {
typedef enum {
KEY_RESERVED = 0,
KEY_ERROR_ROLLOVER = 1,
KEY_POST_FAIL = 2,
@@ -485,10 +485,10 @@ enum KeyboardKeycode : uint8_t {
HID_KEYBOARD_RIGHT_SHIFT = 0xE5,
HID_KEYBOARD_RIGHT_ALT = 0xE6,
HID_KEYBOARD_RIGHT_GUI = 0xE7,
};
} keyboard_keycode_t;
// Keyboard Leds
enum KeyboardLeds : uint8_t {
typedef enum {
LED_NUM_LOCK = (1 << 0),
LED_CAPS_LOCK = (1 << 1),
LED_SCROLL_LOCK = (1 << 2),
@@ -497,10 +497,10 @@ enum KeyboardLeds : uint8_t {
LED_POWER = (1 << 5),
LED_SHIFT = (1 << 6),
LED_DO_NOT_DISTURB = (1 << 7),
};
} keyboard_leds_t;
#define SHIFT 0x80
static const uint8_t _asciimap[] PROGMEM =
uint8_t_asciimap[] =
{
KEY_RESERVED, // NUL
KEY_RESERVED, // SOH

View File

@@ -24,7 +24,7 @@ THE SOFTWARE.
#ifndef __SYSTEM_API_H__
#define __SYSTEM_API_H__
enum SystemKeycode : uint8_t {
typedef enum {
SYSTEM_POWER_DOWN = 0x81,
SYSTEM_SLEEP = 0x82,
SYSTEM_WAKE_UP = 0x83,
@@ -69,6 +69,6 @@ enum SystemKeycode : uint8_t {
HID_SYSTEM_DISPLAY_TOGGLE_INT_SLASH_EXT = 0xB5, // HID type OSC
HID_SYSTEM_DISPLAY_SWAP_PRIMARY_SLASH_SECONDARY = 0xB6, // HID type OSC
HID_SYSTEM_DISPLAY_LCD_AUTOSCALE = 0xB7, // HID type OSC
};
} system_keycode_t;
#endif