aboutsummaryrefslogtreecommitdiff
path: root/quantum
diff options
context:
space:
mode:
authorChris Broekema <broekema-github@fuzzms.nl>2021-12-24 23:31:15 +0100
committerGitHub <noreply@github.com>2021-12-24 14:31:15 -0800
commitc4b03509da094c6dd72def69edff86d29326aeaa (patch)
treeedb8fba588f9f1a05a6049b78aa42b58cf4b4862 /quantum
parent435fa2c391348f604f122dadba4f2af9306d085c (diff)
downloadqmk_firmware-c4b03509da094c6dd72def69edff86d29326aeaa.tar.gz
qmk_firmware-c4b03509da094c6dd72def69edff86d29326aeaa.zip
Save a single byte of memory for joystick buttons (#15555)
Co-authored-by: Joel Challis <git@zvecr.com>
Diffstat (limited to 'quantum')
-rw-r--r--quantum/joystick.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/quantum/joystick.h b/quantum/joystick.h
index 87dbc24af..9156491ac 100644
--- a/quantum/joystick.h
+++ b/quantum/joystick.h
@@ -50,7 +50,7 @@ extern joystick_config_t joystick_axes[JOYSTICK_AXES_COUNT];
50enum joystick_status { JS_INITIALIZED = 1, JS_UPDATED = 2 }; 50enum joystick_status { JS_INITIALIZED = 1, JS_UPDATED = 2 };
51 51
52typedef struct { 52typedef struct {
53 uint8_t buttons[JOYSTICK_BUTTON_COUNT / 8 + 1]; 53 uint8_t buttons[(JOYSTICK_BUTTON_COUNT - 1) / 8 + 1];
54 54
55 int16_t axes[JOYSTICK_AXES_COUNT]; 55 int16_t axes[JOYSTICK_AXES_COUNT];
56 uint8_t status : 2; 56 uint8_t status : 2;