mirror of
https://github.com/qmk/qmk_firmware.git
synced 2026-10-24 09:51:54 +02:00
Joystick 16-bit support (#10439)
* Joystick 16-bit support * Add variable joystick axes resolution * Moved #define statements to .h files * Moved definitions to quantum/joystick.h Removed duplicate definitions from usb_descriptor.h and process_joysick.h Adjust process_joystick.c and usb_descriptor.c to use the pre-computed "JOYSTICK_RESOLUTION" value which contains the logical maximum value of a joystick axis * Cleaning up unnecessary code * Update docs/feature_joystick.md Co-authored-by: Ryan <fauxpark@gmail.com> * Workaround to joystick.h not being included to report.h * Removed unnecessary newlines, updated report.h Changed JOYSTICK_AXES_RESOLUTION conditional in report.h Co-authored-by: Ryan <fauxpark@gmail.com>
This commit is contained in:
@@ -192,7 +192,11 @@ typedef struct {
|
||||
|
||||
typedef struct {
|
||||
#if JOYSTICK_AXES_COUNT > 0
|
||||
int8_t axes[JOYSTICK_AXES_COUNT];
|
||||
# if JOYSTICK_AXES_RESOLUTION > 8
|
||||
int16_t axes[JOYSTICK_AXES_COUNT];
|
||||
# else
|
||||
int8_t axes[JOYSTICK_AXES_COUNT];
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if JOYSTICK_BUTTON_COUNT > 0
|
||||
|
||||
Reference in New Issue
Block a user