summaryrefslogtreecommitdiff
path: root/keyboards/elephant42
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/elephant42')
-rw-r--r--keyboards/elephant42/config.h22
-rw-r--r--keyboards/elephant42/elephant42.c2
-rw-r--r--keyboards/elephant42/elephant42.h35
-rw-r--r--keyboards/elephant42/info.json97
-rw-r--r--keyboards/elephant42/rules.mk1
5 files changed, 55 insertions, 102 deletions
diff --git a/keyboards/elephant42/config.h b/keyboards/elephant42/config.h
index 49ff44755a..a4d471f2c5 100644
--- a/keyboards/elephant42/config.h
+++ b/keyboards/elephant42/config.h
@@ -17,27 +17,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#pragma once
-
-/*
- * Keyboard Matrix Assignments
- *
- * Change this to how you wired your keyboard
- * COLS: AVR pins used for columns, left to right
- * ROWS: AVR pins used for rows, top to bottom
- * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
- * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
- *
- */
-#define MATRIX_ROW_PINS \
- { D4, C6, D7, E6 }
-#define MATRIX_COL_PINS \
- { F4, F5, F6, F7, B1, B3 }
-
-/* COL2ROW, ROW2COL */
-#define DIODE_DIRECTION COL2ROW
-
-#define RGB_DI_PIN D3
-#ifdef RGB_DI_PIN
# define RGBLED_SPLIT { 27, 27 }
# define RGBLED_NUM 54 // backlight x42 + underglow x12
# define RGBLIGHT_HUE_STEP 8
@@ -54,7 +33,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
# define RGBLIGHT_EFFECT_RGB_TEST
# define RGBLIGHT_EFFECT_ALTERNATING
# define RGBLIGHT_EFFECT_TWINKLE
-#endif
#ifdef RGB_MATRIX_ENABLE
# define SPLIT_TRANSPORT_MIRROR
diff --git a/keyboards/elephant42/elephant42.c b/keyboards/elephant42/elephant42.c
index a459442231..1ffb5e8083 100644
--- a/keyboards/elephant42/elephant42.c
+++ b/keyboards/elephant42/elephant42.c
@@ -14,7 +14,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "elephant42.h"
+#include "quantum.h"
#if defined(RGB_MATRIX_ENABLE)
led_config_t g_led_config = {
diff --git a/keyboards/elephant42/elephant42.h b/keyboards/elephant42/elephant42.h
deleted file mode 100644
index ad79c1e1fc..0000000000
--- a/keyboards/elephant42/elephant42.h
+++ /dev/null
@@ -1,35 +0,0 @@
-/* Copyright 2021 illness072
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-
-#pragma once
-
-#include "quantum.h"
-
-#define LAYOUT( \
- L00, L01, L02, L03, L04, L05, R00, R01, R02, R03, R04, R05, \
- L10, L11, L12, L13, L14, L15, R10, R11, R12, R13, R14, R15, \
- L21, L22, L23, L24, L25, R20, R21, R22, R23, R24, \
- L30, L31, L32, L33, R30, R31, R32, R33 \
-) { \
- { L00, L01, L02, L03, L04, L05 }, \
- { L10, L11, L12, L13, L14, L15 }, \
- { KC_NO, L21, L22, L23, L24, L25 }, \
- { KC_NO, KC_NO, L30, L31, L32, L33 }, \
- { R05, R04, R03, R02, R01, R00 }, \
- { R15, R14, R13, R12, R11, R10 }, \
- { KC_NO, R24, R23, R22, R21, R20 }, \
- { KC_NO, KC_NO, R33, R32, R31, R30 } \
-}
diff --git a/keyboards/elephant42/info.json b/keyboards/elephant42/info.json
index 161ec776cd..8bbaf67179 100644
--- a/keyboards/elephant42/info.json
+++ b/keyboards/elephant42/info.json
@@ -8,63 +8,74 @@
"pid": "0x0721",
"device_version": "0.0.1"
},
+ "rgb_matrix": {
+ "driver": "WS2812"
+ },
+ "matrix_pins": {
+ "cols": ["F4", "F5", "F6", "F7", "B1", "B3"],
+ "rows": ["D4", "C6", "D7", "E6"]
+ },
+ "diode_direction": "COL2ROW",
"split": {
"soft_serial_pin": "D2"
},
+ "ws2812": {
+ "pin": "D3"
+ },
"processor": "atmega32u4",
"bootloader": "caterina",
"layouts": {
"LAYOUT": {
"layout": [
- {"label":"Tab", "x":0, "y":1.6},
- {"label":"Q", "x":1, "y":1.1},
- {"label":"W", "x":2, "y":0.3},
- {"label":"E", "x":3, "y":0},
- {"label":"R", "x":4, "y":0.6},
- {"label":"T", "x":5, "y":0.8},
+ {"matrix": [0, 0], "x": 0, "y": 1.6},
+ {"matrix": [0, 1], "x": 1, "y": 1.1},
+ {"matrix": [0, 2], "x": 2, "y": 0.3},
+ {"matrix": [0, 3], "x": 3, "y": 0},
+ {"matrix": [0, 4], "x": 4, "y": 0.6},
+ {"matrix": [0, 5], "x": 5, "y": 0.8},
+
+ {"matrix": [4, 5], "x": 10.5, "y": 0.8},
+ {"matrix": [4, 4], "x": 11.5, "y": 0.6},
+ {"matrix": [4, 3], "x": 12.5, "y": 0},
+ {"matrix": [4, 2], "x": 13.5, "y": 0.3},
+ {"matrix": [4, 1], "x": 14.5, "y": 1.1},
+ {"matrix": [4, 0], "x": 15.5, "y": 1.6},
- {"label":"Y", "x":10.5, "y":0.8},
- {"label":"U", "x":11.5, "y":0.6},
- {"label":"I", "x":12.5, "y":0},
- {"label":"O", "x":13.5, "y":0.3},
- {"label":"P", "x":14.5, "y":1.1},
- {"label":"\\", "x":15.5, "y":1.6},
+ {"matrix": [1, 0], "x": 0, "y": 2.6},
+ {"matrix": [1, 1], "x": 1, "y": 2.1},
+ {"matrix": [1, 2], "x": 2, "y": 1.3},
+ {"matrix": [1, 3], "x": 3, "y": 1},
+ {"matrix": [1, 4], "x": 4, "y": 1.6},
+ {"matrix": [1, 5], "x": 5, "y": 1.8},
- {"label":"Ctrl", "x":0, "y":2.6},
- {"label":"A", "x":1, "y":2.1},
- {"label":"S", "x":2, "y":1.3},
- {"label":"D", "x":3, "y":1},
- {"label":"F", "x":4, "y":1.6},
- {"label":"G", "x":5, "y":1.8},
+ {"matrix": [5, 5], "x": 10.5, "y": 1.8},
+ {"matrix": [5, 4], "x": 11.5, "y": 1.6},
+ {"matrix": [5, 3], "x": 12.5, "y": 1},
+ {"matrix": [5, 2], "x": 13.5, "y": 1.3},
+ {"matrix": [5, 1], "x": 14.5, "y": 2.1},
+ {"matrix": [5, 0], "x": 15.5, "y": 2.6},
- {"label":"H", "x":10.5, "y":1.8},
- {"label":"J", "x":11.5, "y":1.6},
- {"label":"K", "x":12.5, "y":1},
- {"label":"L", "x":13.5, "y":1.3},
- {"label":":", "x":14.5, "y":2.1},
- {"label":"\"", "x":15.5, "y":2.6},
+ {"matrix": [2, 1], "x": 1, "y": 3.1},
+ {"matrix": [2, 2], "x": 2, "y": 2.3},
+ {"matrix": [2, 3], "x": 3, "y": 2},
+ {"matrix": [2, 4], "x": 4, "y": 2.6},
+ {"matrix": [2, 5], "x": 5, "y": 2.8},
- {"label":"Z", "x":1, "y":3.1},
- {"label":"X", "x":2, "y":2.3},
- {"label":"C", "x":3, "y":2},
- {"label":"V", "x":4, "y":2.6},
- {"label":"B", "x":5, "y":2.8},
+ {"matrix": [6, 5], "x": 10.5, "y": 2.8},
+ {"matrix": [6, 4], "x": 11.5, "y": 2.6},
+ {"matrix": [6, 3], "x": 12.5, "y": 2},
+ {"matrix": [6, 2], "x": 13.5, "y": 2.3},
+ {"matrix": [6, 1], "x": 14.5, "y": 3.1},
- {"label":"N", "x":10.5, "y":2.8},
- {"label":"M", "x":11.5, "y":2.6},
- {"label":"<", "x":12.5, "y":2},
- {"label":">", "x":13.5, "y":2.3},
- {"label":"?", "x":14.5, "y":3.1},
+ {"matrix": [3, 2], "x": 3.5, "y": 4},
+ {"matrix": [3, 3], "x": 4.5, "y": 4},
+ {"matrix": [3, 4], "x": 5.5, "y": 4},
+ {"matrix": [3, 5], "x": 6.5, "y": 4},
- {"label":"Alt", "x":3.5, "y":4.0},
- {"label":"Cmd", "x":4.5, "y":4.0},
- {"label":"Lower", "x":5.5, "y":4.0},
- {"label":"Shift", "x":6.5, "y":4.0},
-
- {"label":"Del", "x":9.25, "y":4.0},
- {"label":"Raise", "x":10.25, "y":4.0},
- {"label":"Enter", "x":11.25, "y":4.0},
- {"label":"Backspace", "x":12.25, "y":4.0}
+ {"matrix": [7, 5], "x": 9.25, "y": 4},
+ {"matrix": [7, 4], "x": 10.25, "y": 4},
+ {"matrix": [7, 3], "x": 11.25, "y": 4},
+ {"matrix": [7, 2], "x": 12.25, "y": 4}
]
}
}
diff --git a/keyboards/elephant42/rules.mk b/keyboards/elephant42/rules.mk
index 66270aae47..db121c92e3 100644
--- a/keyboards/elephant42/rules.mk
+++ b/keyboards/elephant42/rules.mk
@@ -10,7 +10,6 @@ NKRO_ENABLE = no # Enable N-Key Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
RGB_MATRIX_ENABLE = yes
-RGB_MATRIX_DRIVER = WS2812
AUDIO_ENABLE = no # Audio output
SPLIT_KEYBOARD = yes
OLED_ENABLE = yes