summaryrefslogtreecommitdiff
path: root/keyboards/punk75
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/punk75')
-rw-r--r--keyboards/punk75/config.h16
-rw-r--r--keyboards/punk75/info.json155
-rw-r--r--keyboards/punk75/punk75.c2
-rw-r--r--keyboards/punk75/punk75.h43
4 files changed, 81 insertions, 135 deletions
diff --git a/keyboards/punk75/config.h b/keyboards/punk75/config.h
index ba9c6fdc71..a8b9af7999 100644
--- a/keyboards/punk75/config.h
+++ b/keyboards/punk75/config.h
@@ -17,24 +17,8 @@ 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 { D6, D5, C1, C0, D7 }
-#define MATRIX_COL_PINS { C2, C3, C6, C5, C4, A7, A6, A5, A4, B4, A3, B3, A2, B2, A1 }
#define LED A0
-/* COL2ROW, ROW2COL*/
-#define DIODE_DIRECTION COL2ROW
-
#define USB_MAX_POWER_CONSUMPTION 500
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
diff --git a/keyboards/punk75/info.json b/keyboards/punk75/info.json
index b232007bb2..81f2bcc818 100644
--- a/keyboards/punk75/info.json
+++ b/keyboards/punk75/info.json
@@ -8,6 +8,11 @@
"pid": "0x0001",
"device_version": "0.0.1"
},
+ "matrix_pins": {
+ "cols": ["C2", "C3", "C6", "C5", "C4", "A7", "A6", "A5", "A4", "B4", "A3", "B3", "A2", "B2", "A1"],
+ "rows": ["D6", "D5", "C1", "C0", "D7"]
+ },
+ "diode_direction": "COL2ROW",
"encoder": {
"rotary": [
{"pin_a": "D0", "pin_b": "D1"},
@@ -20,85 +25,85 @@
"layouts": {
"LAYOUT_ortho_5x15": {
"layout": [
- {"x":0, "y":0},
- {"x":1, "y":0},
- {"x":2, "y":0},
- {"x":3, "y":0},
- {"x":4, "y":0},
- {"x":5, "y":0},
- {"x":6, "y":0},
- {"x":7, "y":0},
- {"x":8, "y":0},
- {"x":9, "y":0},
- {"x":10, "y":0},
- {"x":11, "y":0},
- {"x":12, "y":0},
- {"x":13, "y":0},
- {"x":14, "y":0},
+ {"matrix": [0, 0], "x": 0, "y": 0},
+ {"matrix": [0, 1], "x": 1, "y": 0},
+ {"matrix": [0, 2], "x": 2, "y": 0},
+ {"matrix": [0, 3], "x": 3, "y": 0},
+ {"matrix": [0, 4], "x": 4, "y": 0},
+ {"matrix": [0, 5], "x": 5, "y": 0},
+ {"matrix": [0, 6], "x": 6, "y": 0},
+ {"matrix": [0, 7], "x": 7, "y": 0},
+ {"matrix": [0, 8], "x": 8, "y": 0},
+ {"matrix": [0, 9], "x": 9, "y": 0},
+ {"matrix": [0, 10], "x": 10, "y": 0},
+ {"matrix": [0, 11], "x": 11, "y": 0},
+ {"matrix": [0, 12], "x": 12, "y": 0},
+ {"matrix": [0, 13], "x": 13, "y": 0},
+ {"matrix": [0, 14], "x": 14, "y": 0},
- {"x":0, "y":1},
- {"x":1, "y":1},
- {"x":2, "y":1},
- {"x":3, "y":1},
- {"x":4, "y":1},
- {"x":5, "y":1},
- {"x":6, "y":1},
- {"x":7, "y":1},
- {"x":8, "y":1},
- {"x":9, "y":1},
- {"x":10, "y":1},
- {"x":11, "y":1},
- {"x":12, "y":1},
- {"x":13, "y":1},
- {"x":14, "y":1},
+ {"matrix": [1, 0], "x": 0, "y": 1},
+ {"matrix": [1, 1], "x": 1, "y": 1},
+ {"matrix": [1, 2], "x": 2, "y": 1},
+ {"matrix": [1, 3], "x": 3, "y": 1},
+ {"matrix": [1, 4], "x": 4, "y": 1},
+ {"matrix": [1, 5], "x": 5, "y": 1},
+ {"matrix": [1, 6], "x": 6, "y": 1},
+ {"matrix": [1, 7], "x": 7, "y": 1},
+ {"matrix": [1, 8], "x": 8, "y": 1},
+ {"matrix": [1, 9], "x": 9, "y": 1},
+ {"matrix": [1, 10], "x": 10, "y": 1},
+ {"matrix": [1, 11], "x": 11, "y": 1},
+ {"matrix": [1, 12], "x": 12, "y": 1},
+ {"matrix": [1, 13], "x": 13, "y": 1},
+ {"matrix": [1, 14], "x": 14, "y": 1},
- {"x":0, "y":2},
- {"x":1, "y":2},
- {"x":2, "y":2},
- {"x":3, "y":2},
- {"x":4, "y":2},
- {"x":5, "y":2},
- {"x":6, "y":2},
- {"x":7, "y":2},
- {"x":8, "y":2},
- {"x":9, "y":2},
- {"x":10, "y":2},
- {"x":11, "y":2},
- {"x":12, "y":2},
- {"x":13, "y":2},
- {"x":14, "y":2},
+ {"matrix": [2, 0], "x": 0, "y": 2},
+ {"matrix": [2, 1], "x": 1, "y": 2},
+ {"matrix": [2, 2], "x": 2, "y": 2},
+ {"matrix": [2, 3], "x": 3, "y": 2},
+ {"matrix": [2, 4], "x": 4, "y": 2},
+ {"matrix": [2, 5], "x": 5, "y": 2},
+ {"matrix": [2, 6], "x": 6, "y": 2},
+ {"matrix": [2, 7], "x": 7, "y": 2},
+ {"matrix": [2, 8], "x": 8, "y": 2},
+ {"matrix": [2, 9], "x": 9, "y": 2},
+ {"matrix": [2, 10], "x": 10, "y": 2},
+ {"matrix": [2, 11], "x": 11, "y": 2},
+ {"matrix": [2, 12], "x": 12, "y": 2},
+ {"matrix": [2, 13], "x": 13, "y": 2},
+ {"matrix": [2, 14], "x": 14, "y": 2},
- {"x":0, "y":3},
- {"x":1, "y":3},
- {"x":2, "y":3},
- {"x":3, "y":3},
- {"x":4, "y":3},
- {"x":5, "y":3},
- {"x":6, "y":3},
- {"x":7, "y":3},
- {"x":8, "y":3},
- {"x":9, "y":3},
- {"x":10, "y":3},
- {"x":11, "y":3},
- {"x":12, "y":3},
- {"x":13, "y":3},
- {"x":14, "y":3},
+ {"matrix": [3, 0], "x": 0, "y": 3},
+ {"matrix": [3, 1], "x": 1, "y": 3},
+ {"matrix": [3, 2], "x": 2, "y": 3},
+ {"matrix": [3, 3], "x": 3, "y": 3},
+ {"matrix": [3, 4], "x": 4, "y": 3},
+ {"matrix": [3, 5], "x": 5, "y": 3},
+ {"matrix": [3, 6], "x": 6, "y": 3},
+ {"matrix": [3, 7], "x": 7, "y": 3},
+ {"matrix": [3, 8], "x": 8, "y": 3},
+ {"matrix": [3, 9], "x": 9, "y": 3},
+ {"matrix": [3, 10], "x": 10, "y": 3},
+ {"matrix": [3, 11], "x": 11, "y": 3},
+ {"matrix": [3, 12], "x": 12, "y": 3},
+ {"matrix": [3, 13], "x": 13, "y": 3},
+ {"matrix": [3, 14], "x": 14, "y": 3},
- {"x":0, "y":4},
- {"x":1, "y":4},
- {"x":2, "y":4},
- {"x":3, "y":4},
- {"x":4, "y":4},
- {"x":5, "y":4},
- {"x":6, "y":4},
- {"x":7, "y":4},
- {"x":8, "y":4},
- {"x":9, "y":4},
- {"x":10, "y":4},
- {"x":11, "y":4},
- {"x":12, "y":4},
- {"x":13, "y":4},
- {"x":14, "y":4}
+ {"matrix": [4, 0], "x": 0, "y": 4},
+ {"matrix": [4, 1], "x": 1, "y": 4},
+ {"matrix": [4, 2], "x": 2, "y": 4},
+ {"matrix": [4, 3], "x": 3, "y": 4},
+ {"matrix": [4, 4], "x": 4, "y": 4},
+ {"matrix": [4, 5], "x": 5, "y": 4},
+ {"matrix": [4, 6], "x": 6, "y": 4},
+ {"matrix": [4, 7], "x": 7, "y": 4},
+ {"matrix": [4, 8], "x": 8, "y": 4},
+ {"matrix": [4, 9], "x": 9, "y": 4},
+ {"matrix": [4, 10], "x": 10, "y": 4},
+ {"matrix": [4, 11], "x": 11, "y": 4},
+ {"matrix": [4, 12], "x": 12, "y": 4},
+ {"matrix": [4, 13], "x": 13, "y": 4},
+ {"matrix": [4, 14], "x": 14, "y": 4}
]
}
}
diff --git a/keyboards/punk75/punk75.c b/keyboards/punk75/punk75.c
index 045e3c2669..aaabefb5aa 100644
--- a/keyboards/punk75/punk75.c
+++ b/keyboards/punk75/punk75.c
@@ -14,7 +14,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "punk75.h"
+#include "quantum.h"
void matrix_init_kb(void) {
// Set our LED pin as output
diff --git a/keyboards/punk75/punk75.h b/keyboards/punk75/punk75.h
deleted file mode 100644
index 6e89e5d2a7..0000000000
--- a/keyboards/punk75/punk75.h
+++ /dev/null
@@ -1,43 +0,0 @@
-/* Copyright 2020 dsanchezseco
- *
- * 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"
-
-/* This is a shortcut to help you visually see your layout.
- *
- * The first section contains all of the arguments representing the physical
- * layout of the board and position of the keys.
- *
- * The second converts the arguments into a two-dimensional array which
- * represents the switch matrix.
- */
-#define LAYOUT_ortho_5x15( \
- k01, k06, k11, k16, k21, k26, k31, k36, k41, k46, k51, k56, k61, k66, k71, \
- k02, k07, k12, k17, k22, k27, k32, k37, k42, k47, k52, k57, k62, k67, k72, \
- k03, k08, k13, k18, k23, k28, k33, k38, k43, k48, k53, k58, k63, k68, k73, \
- k04, k09, k14, k19, k24, k29, k34, k39, k44, k49, k54, k59, k64, k69, k74, \
- k05, k10, k15, k20, k25, k30, k35, k40, k45, k50, k55, k60, k65, k70, k75 \
-) { \
- { k01, k06, k11, k16, k21, k26, k31, k36, k41, k46, k51, k56, k61, k66, k71 }, \
- { k02, k07, k12, k17, k22, k27, k32, k37, k42, k47, k52, k57, k62, k67, k72 }, \
- { k03, k08, k13, k18, k23, k28, k33, k38, k43, k48, k53, k58, k63, k68, k73 }, \
- { k04, k09, k14, k19, k24, k29, k34, k39, k44, k49, k54, k59, k64, k69, k74 }, \
- { k05, k10, k15, k20, k25, k30, k35, k40, k45, k50, k55, k60, k65, k70, k75 } \
-}
-
-//TODO: other layouts with the 2u keys