summaryrefslogtreecommitdiff
path: root/keyboards/terrazzo
diff options
context:
space:
mode:
authorRyan <fauxpark@gmail.com>2023-02-26 09:45:12 +1100
committerGitHub <noreply@github.com>2023-02-26 09:45:12 +1100
commit7e0299117b389b1c7fcdfa2f20891ba2287ea771 (patch)
tree00bb5bb7b3b73a9de365d1839ba7d41240d439f1 /keyboards/terrazzo
parent314f6c1ddba09851b33e4f3b4bd43bdbc55f9628 (diff)
Move encoder config to data driven (#19923)
Co-authored-by: Nick Brassel <nick@tzarc.org>
Diffstat (limited to 'keyboards/terrazzo')
-rw-r--r--keyboards/terrazzo/config.h38
-rw-r--r--keyboards/terrazzo/info.json7
2 files changed, 7 insertions, 38 deletions
diff --git a/keyboards/terrazzo/config.h b/keyboards/terrazzo/config.h
index 75ca5885a1..6c0cbb80b9 100644
--- a/keyboards/terrazzo/config.h
+++ b/keyboards/terrazzo/config.h
@@ -25,44 +25,6 @@
#define DIODE_DIRECTION COL2ROW
-/* ROTARY ENCODERS */
-
-/* 4 encoder positions are supported. With multiple
-encoder support when using the extra pins of
-Elite-C controller.
-
-Use the following configuration guides for your
-encoder layout. */
-
-/* PRO MICRO CONFIGURATIONS */
-
-/* If using a Pro Micro, only 1 encoder may be used,
-and only in the top or bottom position.
-Top and bottom encoders share the same net,
-so there is only one configuration. */
-
-/* TOP or BOTTOM */
-// #define ENCODERS_PAD_A { C6 }
-// #define ENCODERS_PAD_B { D4 }
-
-/* ELITE-C ONLY CONFIGURATIONS */
-
-/* TOP 3
- Default configuration */
-#define ENCODERS_PAD_A { C6 , B7, C7 }
-#define ENCODERS_PAD_B { D4 , D5, F1 }
-
-/* BOTTOM 3 */
-// #define ENCODERS_PAD_A { B7, C7, C6 }
-// #define ENCODERS_PAD_B { D5, F1, D4 }
-
-/* BOTTOM 2 */
-// #define ENCODERS_PAD_A { C7, C6 }
-// #define ENCODERS_PAD_B { F1, D4 }
-
-
-#define ENCODER_RESOLUTION 2
-
#ifdef LED_MATRIX_ENABLE
#define LED_DRIVER_ADDR_1 0x74
diff --git a/keyboards/terrazzo/info.json b/keyboards/terrazzo/info.json
index 36382c4648..fb59374d1d 100644
--- a/keyboards/terrazzo/info.json
+++ b/keyboards/terrazzo/info.json
@@ -8,6 +8,13 @@
"pid": "0x545A",
"device_version": "0.0.2"
},
+ "encoder": {
+ "rotary": [
+ {"pin_a": "C6", "pin_b": "D4", "resolution": 2},
+ {"pin_a": "B7", "pin_b": "D5", "resolution": 2},
+ {"pin_a": "C7", "pin_b": "F1", "resolution": 2}
+ ]
+ },
"processor": "atmega32u4",
"bootloader": "atmel-dfu",
"layouts": {