diff options
author | Ryan <fauxpark@gmail.com> | 2022-09-27 18:37:13 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-27 18:37:13 +1000 |
commit | be8907d634ac8967de1ae2ac8346b845f738c9e6 (patch) | |
tree | 5a56127946000bbd648f8a5f52d90eb6711be222 /keyboards/handwired/onekey | |
parent | fb400f2ac2c57fa0fc82ca803f6450b818bb32f9 (diff) |
Further refactoring of joystick feature (#18437)
Diffstat (limited to 'keyboards/handwired/onekey')
-rw-r--r-- | keyboards/handwired/onekey/keymaps/joystick/keymap.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/keyboards/handwired/onekey/keymaps/joystick/keymap.c b/keyboards/handwired/onekey/keymaps/joystick/keymap.c index 7a2f138b28..c74707e931 100644 --- a/keyboards/handwired/onekey/keymaps/joystick/keymap.c +++ b/keyboards/handwired/onekey/keymaps/joystick/keymap.c @@ -10,11 +10,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { void matrix_scan_user() { int16_t val = (((uint32_t)timer_read() % 5000 - 2500) * 255) / 5000; - - if (val != joystick_status.axes[1]) { - joystick_status.axes[1] = val; - joystick_status.status |= JS_UPDATED; - } + joystick_set_axis(1, val); } // Joystick config |