summaryrefslogtreecommitdiffstats
path: root/keyboards/adafruit
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/adafruit')
-rw-r--r--keyboards/adafruit/macropad/config.h1
-rw-r--r--keyboards/adafruit/macropad/info.json33
-rw-r--r--keyboards/adafruit/macropad/keymaps/default/keymap.c2
-rw-r--r--keyboards/adafruit/macropad/keymaps/peterfalken/keymap.c2
-rw-r--r--keyboards/adafruit/macropad/keymaps/via/keymap.c2
-rw-r--r--keyboards/adafruit/macropad/macropad.c14
-rw-r--r--keyboards/adafruit/macropad/rules.mk2
7 files changed, 23 insertions, 33 deletions
diff --git a/keyboards/adafruit/macropad/config.h b/keyboards/adafruit/macropad/config.h
index af72251dac..08db87fefe 100644
--- a/keyboards/adafruit/macropad/config.h
+++ b/keyboards/adafruit/macropad/config.h
@@ -54,7 +54,6 @@
#ifdef RGB_MATRIX_ENABLE
/* RGB Defines */
-# define RGB_DI_PIN GP19
# define RGB_MATRIX_LED_COUNT 12
# define RGBLED_NUM 12
diff --git a/keyboards/adafruit/macropad/info.json b/keyboards/adafruit/macropad/info.json
index 75c859adb1..febf1e61f6 100644
--- a/keyboards/adafruit/macropad/info.json
+++ b/keyboards/adafruit/macropad/info.json
@@ -13,9 +13,16 @@
{"pin_a": "GP18", "pin_b": "GP17"}
]
},
+ "rgb_matrix": {
+ "driver": "WS2812"
+ },
"bootmagic": {
"matrix": [1, 2]
},
+ "ws2812": {
+ "pin": "GP19",
+ "driver": "vendor"
+ },
"processor": "RP2040",
"bootloader": "rp2040",
"matrix_pins": {
@@ -30,19 +37,19 @@
"layouts": {
"LAYOUT": {
"layout": [
- {"x":2, "y":0, "matrix": [0, 2]},
- {"x":0, "y":1, "matrix": [1, 0]},
- {"x":1, "y":1, "matrix": [1, 1]},
- {"x":2, "y":1, "matrix": [1, 2]},
- {"x":0, "y":2, "matrix": [2, 0]},
- {"x":1, "y":2, "matrix": [2, 1]},
- {"x":2, "y":2, "matrix": [2, 2]},
- {"x":0, "y":3, "matrix": [3, 0]},
- {"x":1, "y":3, "matrix": [3, 1]},
- {"x":2, "y":3, "matrix": [3, 2]},
- {"x":0, "y":4, "matrix": [4, 0]},
- {"x":1, "y":4, "matrix": [4, 1]},
- {"x":2, "y":4, "matrix": [4, 2]}
+ {"x": 2, "y": 0, "matrix": [0, 2]},
+ {"x": 0, "y": 1, "matrix": [1, 0]},
+ {"x": 1, "y": 1, "matrix": [1, 1]},
+ {"x": 2, "y": 1, "matrix": [1, 2]},
+ {"x": 0, "y": 2, "matrix": [2, 0]},
+ {"x": 1, "y": 2, "matrix": [2, 1]},
+ {"x": 2, "y": 2, "matrix": [2, 2]},
+ {"x": 0, "y": 3, "matrix": [3, 0]},
+ {"x": 1, "y": 3, "matrix": [3, 1]},
+ {"x": 2, "y": 3, "matrix": [3, 2]},
+ {"x": 0, "y": 4, "matrix": [4, 0]},
+ {"x": 1, "y": 4, "matrix": [4, 1]},
+ {"x": 2, "y": 4, "matrix": [4, 2]}
]
}
}
diff --git a/keyboards/adafruit/macropad/keymaps/default/keymap.c b/keyboards/adafruit/macropad/keymaps/default/keymap.c
index 808b202df4..642f0300d3 100644
--- a/keyboards/adafruit/macropad/keymaps/default/keymap.c
+++ b/keyboards/adafruit/macropad/keymaps/default/keymap.c
@@ -34,7 +34,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};
#ifdef ENCODER_MAP_ENABLE
-const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = {
+const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
[0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
[1] = { ENCODER_CCW_CW(_______, _______) },
};
diff --git a/keyboards/adafruit/macropad/keymaps/peterfalken/keymap.c b/keyboards/adafruit/macropad/keymaps/peterfalken/keymap.c
index f931263347..f232a99861 100644
--- a/keyboards/adafruit/macropad/keymaps/peterfalken/keymap.c
+++ b/keyboards/adafruit/macropad/keymaps/peterfalken/keymap.c
@@ -14,7 +14,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};
#ifdef ENCODER_MAP_ENABLE
-const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = {
+const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
[0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
};
#endif
diff --git a/keyboards/adafruit/macropad/keymaps/via/keymap.c b/keyboards/adafruit/macropad/keymaps/via/keymap.c
index 80efd80f2d..cb2e480025 100644
--- a/keyboards/adafruit/macropad/keymaps/via/keymap.c
+++ b/keyboards/adafruit/macropad/keymaps/via/keymap.c
@@ -48,7 +48,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};
#ifdef ENCODER_MAP_ENABLE
-const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][2] = {
+const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
[0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
[1] = { ENCODER_CCW_CW(_______, _______) },
[2] = { ENCODER_CCW_CW(_______, _______) },
diff --git a/keyboards/adafruit/macropad/macropad.c b/keyboards/adafruit/macropad/macropad.c
index 398d0bbdfd..6661e43909 100644
--- a/keyboards/adafruit/macropad/macropad.c
+++ b/keyboards/adafruit/macropad/macropad.c
@@ -65,17 +65,3 @@ void audio_off_user(void) {
writePinLow(SPEAKER_SHUTDOWN);
}
#endif
-
-#ifdef ENCODER_ENABLE
-bool encoder_update_kb(uint8_t index, bool clockwise) {
- if (!encoder_update_user(index, clockwise)) { return false; }
- if (index == 0) {
- if (clockwise) {
- tap_code_delay(KC_VOLU, 10);
- } else {
- tap_code_delay(KC_VOLD, 10);
- }
- }
- return true;
-}
-#endif
diff --git a/keyboards/adafruit/macropad/rules.mk b/keyboards/adafruit/macropad/rules.mk
index fd1ecf7cbc..23b15d77fc 100644
--- a/keyboards/adafruit/macropad/rules.mk
+++ b/keyboards/adafruit/macropad/rules.mk
@@ -13,8 +13,6 @@ AUDIO_ENABLE = yes # Audio output
AUDIO_DRIVER = pwm_hardware
ENCODER_ENABLE = yes
RGB_MATRIX_ENABLE = yes
-RGB_MATRIX_DRIVER = WS2812
-WS2812_DRIVER = vendor
OLED_ENABLE = yes
OLED_DRIVER = custom
# Project specific files