Fix flexible array errors
This commit is contained in:
parent
12557b5489
commit
583718f453
8 changed files with 46 additions and 51 deletions
|
|
@ -39,9 +39,9 @@ THE SOFTWARE.
|
|||
|
||||
typedef union{
|
||||
// Absolute mouse report: 8 buttons, 2 absolute axis, wheel
|
||||
uint8_t whole8[];
|
||||
uint16_t whole16[];
|
||||
uint32_t whole32[];
|
||||
uint8_t whole8[0];
|
||||
uint16_t whole16[0];
|
||||
uint32_t whole32[0];
|
||||
struct{
|
||||
uint8_t buttons;
|
||||
int16_t xAxis;
|
||||
|
|
|
|||
|
|
@ -450,9 +450,9 @@ enum ConsumerKeycode : uint16_t {
|
|||
|
||||
typedef union {
|
||||
// Every usable Consumer key possible, up to 4 keys presses possible
|
||||
uint8_t whole8[];
|
||||
uint16_t whole16[];
|
||||
uint32_t whole32[];
|
||||
uint8_t whole8[0];
|
||||
uint16_t whole16[0];
|
||||
uint32_t whole32[0];
|
||||
ConsumerKeycode keys[4];
|
||||
struct {
|
||||
ConsumerKeycode key1;
|
||||
|
|
@ -482,4 +482,3 @@ protected:
|
|||
|
||||
// Implementation is inline
|
||||
#include "ConsumerAPI.hpp"
|
||||
|
||||
|
|
|
|||
|
|
@ -29,9 +29,9 @@ THE SOFTWARE.
|
|||
|
||||
typedef union{
|
||||
// Low level key report: up to 6 keys and shift, ctrl etc at once
|
||||
uint8_t whole8[];
|
||||
uint16_t whole16[];
|
||||
uint32_t whole32[];
|
||||
uint8_t whole8[0];
|
||||
uint16_t whole16[0];
|
||||
uint32_t whole32[0];
|
||||
struct{
|
||||
uint8_t modifiers;
|
||||
uint8_t reserved;
|
||||
|
|
@ -74,4 +74,3 @@ private:
|
|||
|
||||
// Implementation is inline
|
||||
#include "DefaultKeyboardAPI.hpp"
|
||||
|
||||
|
|
|
|||
|
|
@ -41,9 +41,9 @@ THE SOFTWARE.
|
|||
|
||||
typedef union {
|
||||
// 32 Buttons, 6 Axis, 2 D-Pads
|
||||
uint8_t whole8[];
|
||||
uint16_t whole16[];
|
||||
uint32_t whole32[];
|
||||
uint8_t whole8[0];
|
||||
uint16_t whole16[0];
|
||||
uint32_t whole32[0];
|
||||
uint32_t buttons;
|
||||
|
||||
struct{
|
||||
|
|
@ -127,4 +127,3 @@ protected:
|
|||
|
||||
// Implementation is inline
|
||||
#include "GamepadAPI.hpp"
|
||||
|
||||
|
|
|
|||
|
|
@ -39,9 +39,9 @@ THE SOFTWARE.
|
|||
|
||||
typedef union{
|
||||
// Mouse report: 8 buttons, position, wheel
|
||||
uint8_t whole8[];
|
||||
uint16_t whole16[];
|
||||
uint32_t whole32[];
|
||||
uint8_t whole8[0];
|
||||
uint16_t whole16[0];
|
||||
uint32_t whole32[0];
|
||||
struct{
|
||||
uint8_t buttons;
|
||||
int8_t xAxis;
|
||||
|
|
@ -53,9 +53,9 @@ typedef union{
|
|||
typedef union{
|
||||
// BootMouse report: 3 buttons, position
|
||||
// Wheel is not supported by boot protocol
|
||||
uint8_t whole8[];
|
||||
uint16_t whole16[];
|
||||
uint32_t whole32[];
|
||||
uint8_t whole8[0];
|
||||
uint16_t whole16[0];
|
||||
uint32_t whole32[0];
|
||||
struct{
|
||||
uint8_t buttons;
|
||||
int8_t xAxis;
|
||||
|
|
|
|||
|
|
@ -32,9 +32,9 @@ THE SOFTWARE.
|
|||
|
||||
typedef union{
|
||||
// Modifier + keymap + 1 custom key
|
||||
uint8_t whole8[];
|
||||
uint16_t whole16[];
|
||||
uint32_t whole32[];
|
||||
uint8_t whole8[0];
|
||||
uint16_t whole16[0];
|
||||
uint32_t whole32[0];
|
||||
struct{
|
||||
uint8_t modifiers;
|
||||
uint8_t keys[NKRO_KEY_COUNT / 8];
|
||||
|
|
@ -62,4 +62,3 @@ private:
|
|||
|
||||
// Implementation is inline
|
||||
#include "NKROKeyboardAPI.hpp"
|
||||
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ enum SystemKeycode : uint8_t {
|
|||
|
||||
typedef union{
|
||||
// Every usable system control key possible
|
||||
uint8_t whole8[];
|
||||
uint8_t whole8[0];
|
||||
uint8_t key;
|
||||
} HID_SystemControlReport_Data_t;
|
||||
|
||||
|
|
|
|||
|
|
@ -54,17 +54,17 @@ THE SOFTWARE.
|
|||
|
||||
typedef union{
|
||||
// a RAWHID_TX_SIZE byte buffer for tx
|
||||
uint8_t whole8[];
|
||||
uint16_t whole16[];
|
||||
uint32_t whole32[];
|
||||
uint8_t whole8[0];
|
||||
uint16_t whole16[0];
|
||||
uint32_t whole32[0];
|
||||
uint8_t buff[RAWHID_TX_SIZE];
|
||||
} HID_RawKeyboardTXReport_Data_t;
|
||||
|
||||
typedef union{
|
||||
// a RAWHID_TX_SIZE byte buffer for rx
|
||||
uint8_t whole8[];
|
||||
uint16_t whole16[];
|
||||
uint32_t whole32[];
|
||||
uint8_t whole8[0];
|
||||
uint16_t whole16[0];
|
||||
uint32_t whole32[0];
|
||||
uint8_t buff[RAWHID_RX_SIZE];
|
||||
} HID_RawKeyboardRXReport_Data_t;
|
||||
|
||||
|
|
@ -177,4 +177,3 @@ protected:
|
|||
int featureLength;
|
||||
};
|
||||
extern RawHID_ RawHID;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue