diff options
author | Nick Brassel <nick@tzarc.org> | 2023-02-28 11:22:29 +1100 |
---|---|---|
committer | Nick Brassel <nick@tzarc.org> | 2023-02-28 11:22:29 +1100 |
commit | bacec14073b2e897d5a52caf12de5a6a1f7b4078 (patch) | |
tree | d4e3e57aac1a829a191831efd2e62c8a43217885 /keyboards/macrocat | |
parent | d70e9b8659a7fbbd7069fd542bd07e67e04327a1 (diff) | |
parent | b865b9e1706ad28ae4882bd2e0331e98808295fa (diff) |
Merge remote-tracking branch 'upstream/develop'
Diffstat (limited to 'keyboards/macrocat')
-rw-r--r-- | keyboards/macrocat/config.h | 5 | ||||
-rw-r--r-- | keyboards/macrocat/info.json | 5 | ||||
-rw-r--r-- | keyboards/macrocat/macrocat.c | 4 |
3 files changed, 7 insertions, 7 deletions
diff --git a/keyboards/macrocat/config.h b/keyboards/macrocat/config.h index 851cfe7427..0d14bca0ea 100644 --- a/keyboards/macrocat/config.h +++ b/keyboards/macrocat/config.h @@ -3,9 +3,4 @@ #pragma once -#include "config_common.h" - -/* rotary encoder */ -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } #define ENCODER_SWITCH B7 diff --git a/keyboards/macrocat/info.json b/keyboards/macrocat/info.json index 421f1283e1..47dbbc6d9a 100644 --- a/keyboards/macrocat/info.json +++ b/keyboards/macrocat/info.json @@ -24,6 +24,11 @@ "pid": "0x8086", "vid": "0x2022" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2"} + ] + }, "layout_aliases": { "LAYOUT_numpad_4x4": "LAYOUT_ortho_4x4" }, diff --git a/keyboards/macrocat/macrocat.c b/keyboards/macrocat/macrocat.c index aec76d1912..f00bb01410 100644 --- a/keyboards/macrocat/macrocat.c +++ b/keyboards/macrocat/macrocat.c @@ -126,12 +126,12 @@ void encoder_double_click(void) { void encoder_triple_click(void) { tap_code(KC_MPRV); } -void matrix_init_kb() { +void matrix_init_kb(void) { matrix_init_user(); setPinInputHigh(ENCODER_SWITCH); } -void matrix_scan_kb() { +void matrix_scan_kb(void) { matrix_scan_user(); if (readPin(ENCODER_SWITCH)) { if (encoder_pressed) { // release switch |