diff options
author | Ryan <fauxpark@gmail.com> | 2023-03-29 15:54:34 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-29 15:54:34 +1100 |
commit | 4869b8061c187f6476f8f14b839dd2c2c9f74dd2 (patch) | |
tree | 085ba6c614b0cc649a664b6e9e8829ee6f1fe593 /keyboards/amjkeyboard | |
parent | 06664e8a94116b5d40b2348ec89ba2fc6248ec16 (diff) |
Move ortho & numpad layouts to data driven (#20183)
Co-authored-by: Nick Brassel <nick@tzarc.org>
Diffstat (limited to 'keyboards/amjkeyboard')
-rwxr-xr-x | keyboards/amjkeyboard/amj40/amj40.h | 109 | ||||
-rw-r--r-- | keyboards/amjkeyboard/amj40/info.json | 342 | ||||
-rw-r--r-- | keyboards/amjkeyboard/amjpad/amjpad.h | 58 | ||||
-rw-r--r-- | keyboards/amjkeyboard/amjpad/info.json | 61 |
4 files changed, 230 insertions, 340 deletions
diff --git a/keyboards/amjkeyboard/amj40/amj40.h b/keyboards/amjkeyboard/amj40/amj40.h deleted file mode 100755 index 14ea383811..0000000000 --- a/keyboards/amjkeyboard/amj40/amj40.h +++ /dev/null @@ -1,109 +0,0 @@ -/* Copyright 2017 Fabian Topfstedt - * Copyright 2021 James Young (@noroadsleft) - * - * 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 XXX KC_NO - -/* AMJ40 ver2.0 staggered layouts - * ,-----------------------------------------------. - * |00 |01 |02 |03 |04 |05 |06 |07 |08 |09 |0a |0b | - * |-----------------------------------------------| - * |10 |11 |12 |13 |14 |15 |16 |17 |18 |19 |1b | - * |-----------------------------------------------| - * |20 |22 |23 |24 |25 |26 |27 |28 |29 |2a |2b | - * |-----------------------------------------------| - * |30 |31 |32 | 34 |35 |39 |3a |3b | Layout 1 Bottom Row - * `-----------------------------------------------' - * ,-----------------------------------------------. - * |30 |31 |32 | 35 |3a |3b | Layout 2 - * `-----------------------------------------------' - * ,-----------------------------------------------. - * |30 |31 |32 | 34 | 35 |39 |3a |3b | Layout 3 - * `-----------------------------------------------' - * ,-----------------------------------------------. - * |30 |31 |32 | 35 |3a |3b | Layout 4 - * `-----------------------------------------------' - */ - -// a.k.a. Layout 1 or Layout 3 (matrix is the same for both) -#define LAYOUT( \ - k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, \ - k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1b, \ - k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, \ - k30, k31, k32, k34, k35, k39, k3a, k3b \ -) { \ - {k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b}, \ - {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, XXX, k1b}, \ - {k20, XXX, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b}, \ - {k30, k31, k32, XXX, k34, k35, XXX, XXX, XXX, k39, k3a, k3b} \ -} - -// a.k.a. Layout 2 or Layout 4 (matrix is the same for both) -#define LAYOUT_625u_space( \ - k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, \ - k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1b, \ - k20, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, \ - k30, k31, k32, k35, k3a, k3b \ -) { \ - { k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b }, \ - { k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, XXX, k1b }, \ - { k20, XXX, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b }, \ - { k30, k31, k32, XXX, XXX, k35, XXX, XXX, XXX, XXX, k3a, k3b } \ -} - -/* AMJ40 ver2.0 ortholinear layouts - * ,-----------------------------------------------. - * |00 |01 |02 |03 |04 |05 |06 |07 |08 |09 |0a |0b | - * |-----------------------------------------------| - * |10 |11 |12 |13 |14 |15 |16 |17 |18 |19 |1a |1b | - * |-----------------------------------------------| - * |20 |21 |22 |23 |24 |25 |26 |27 |28 |29 |2a |2b | - * |-----------------------------------------------| - * |30 |31 |32 |33 |34 | 35 |38 |39 |3a |3b | 2.75u Spacebar - * `-----------------------------------------------' - * ,-----------------------------------------------. - * |30 |31 |32 | 35 |39 |3a |3b | 6u Spacebar - * `-----------------------------------------------' - */ - -// equivalent to LAYOUT_all -#define LAYOUT_ortho_275u_space( \ - k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, \ - k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, \ - k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, \ - k30, k31, k32, k33, k34, k35, k38, k39, k3a, k3b \ -) { \ - { k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b }, \ - { k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b }, \ - { k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b }, \ - { k30, k31, k32, k33, k34, k35, XXX, XXX, k38, k39, k3a, k3b } \ -} - -#define LAYOUT_ortho_600u_space( \ - k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, \ - k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, \ - k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, \ - k30, k31, k32, k35, k39, k3a, k3b \ -) { \ - { k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b }, \ - { k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b }, \ - { k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b }, \ - { k30, k31, k32, XXX, XXX, k35, XXX, XXX, XXX, k39, k3a, k3b } \ -} diff --git a/keyboards/amjkeyboard/amj40/info.json b/keyboards/amjkeyboard/amj40/info.json index 60eeb456f4..c92c50d7fd 100644 --- a/keyboards/amjkeyboard/amj40/info.json +++ b/keyboards/amjkeyboard/amj40/info.json @@ -26,201 +26,201 @@ "layouts": { "LAYOUT": { "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}, + {"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}, - {"x":0, "y":1, "w":1.25}, - {"x":1.25, "y":1}, - {"x":2.25, "y":1}, - {"x":3.25, "y":1}, - {"x":4.25, "y":1}, - {"x":5.25, "y":1}, - {"x":6.25, "y":1}, - {"x":7.25, "y":1}, - {"x":8.25, "y":1}, - {"x":9.25, "y":1}, - {"x":10.25, "y":1, "w":1.75}, + {"matrix": [1, 0], "x": 0, "y": 1, "w": 1.25}, + {"matrix": [1, 1], "x": 1.25, "y": 1}, + {"matrix": [1, 2], "x": 2.25, "y": 1}, + {"matrix": [1, 3], "x": 3.25, "y": 1}, + {"matrix": [1, 4], "x": 4.25, "y": 1}, + {"matrix": [1, 5], "x": 5.25, "y": 1}, + {"matrix": [1, 6], "x": 6.25, "y": 1}, + {"matrix": [1, 7], "x": 7.25, "y": 1}, + {"matrix": [1, 8], "x": 8.25, "y": 1}, + {"matrix": [1, 9], "x": 9.25, "y": 1}, + {"matrix": [1, 11], "x": 10.25, "y": 1, "w": 1.75}, - {"x":0, "y":2, "w":1.75}, - {"x":1.75, "y":2}, - {"x":2.75, "y":2}, - {"x":3.75, "y":2}, - {"x":4.75, "y":2}, - {"x":5.75, "y":2}, - {"x":6.75, "y":2}, - {"x":7.75, "y":2}, - {"x":8.75, "y":2}, - {"x":9.75, "y":2, "w":1.25}, - {"x":11, "y":2}, + {"matrix": [2, 0], "x": 0, "y": 2, "w": 1.75}, + {"matrix": [2, 2], "x": 1.75, "y": 2}, + {"matrix": [2, 3], "x": 2.75, "y": 2}, + {"matrix": [2, 4], "x": 3.75, "y": 2}, + {"matrix": [2, 5], "x": 4.75, "y": 2}, + {"matrix": [2, 6], "x": 5.75, "y": 2}, + {"matrix": [2, 7], "x": 6.75, "y": 2}, + {"matrix": [2, 8], "x": 7.75, "y": 2}, + {"matrix": [2, 9], "x": 8.75, "y": 2}, + {"matrix": [2, 10], "x": 9.75, "y": 2, "w": 1.25}, + {"matrix": [2, 11], "x": 11, "y": 2}, - {"x":0, "y":3, "w":1.25}, - {"x":1.25, "y":3}, - {"x":2.25, "y":3, "w":1.25}, - {"x":3.5, "y":3, "w":2.25}, - {"x":5.75, "y":3, "w":2.75}, - {"x":8.5, "y":3, "w":1.25}, - {"x":9.75, "y":3}, - {"x":10.75, "y":3, "w":1.25} + {"matrix": [3, 0], "x": 0, "y": 3, "w": 1.25}, + {"matrix": [3, 1], "x": 1.25, "y": 3}, + {"matrix": [3, 2], "x": 2.25, "y": 3, "w": 1.25}, + {"matrix": [3, 4], "x": 3.5, "y": 3, "w": 2.25}, + {"matrix": [3, 5], "x": 5.75, "y": 3, "w": 2.75}, + {"matrix": [3, 9], "x": 8.5, "y": 3, "w": 1.25}, + {"matrix": [3, 10], "x": 9.75, "y": 3}, + {"matrix": [3, 11], "x": 10.75, "y": 3, "w": 1.25} ] }, "LAYOUT_625u_space": { "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}, + {"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}, - {"x":0, "y":1, "w":1.25}, - {"x":1.25, "y":1}, - {"x":2.25, "y":1}, - {"x":3.25, "y":1}, - {"x":4.25, "y":1}, - {"x":5.25, "y":1}, - {"x":6.25, "y":1}, - {"x":7.25, "y":1}, - {"x":8.25, "y":1}, - {"x":9.25, "y":1}, - {"x":10.25, "y":1, "w":1.75}, + {"matrix": [1, 0], "x": 0, "y": 1, "w": 1.25}, + {"matrix": [1, 1], "x": 1.25, "y": 1}, + {"matrix": [1, 2], "x": 2.25, "y": 1}, + {"matrix": [1, 3], "x": 3.25, "y": 1}, + {"matrix": [1, 4], "x": 4.25, "y": 1}, + {"matrix": [1, 5], "x": 5.25, "y": 1}, + {"matrix": [1, 6], "x": 6.25, "y": 1}, + {"matrix": [1, 7], "x": 7.25, "y": 1}, + {"matrix": [1, 8], "x": 8.25, "y": 1}, + {"matrix": [1, 9], "x": 9.25, "y": 1}, + {"matrix": [1, 11], "x": 10.25, "y": 1, "w": 1.75}, - {"x":0, "y":2, "w":1.75}, - {"x":1.75, "y":2}, - {"x":2.75, "y":2}, - {"x":3.75, "y":2}, - {"x":4.75, "y":2}, - {"x":5.75, "y":2}, - {"x":6.75, "y":2}, - {"x":7.75, "y":2}, - {"x":8.75, "y":2}, - {"x":9.75, "y":2, "w":1.25}, - {"x":11, "y":2}, + {"matrix": [2, 0], "x": 0, "y": 2, "w": 1.75}, + {"matrix": [2, 2], "x": 1.75, "y": 2}, + {"matrix": [2, 3], "x": 2.75, "y": 2}, + {"matrix": [2, 4], "x": 3.75, "y": 2}, + {"matrix": [2, 5], "x": 4.75, "y": 2}, + {"matrix": [2, 6], "x": 5.75, "y": 2}, + {"matrix": [2, 7], "x": 6.75, "y": 2}, + {"matrix": [2, 8], "x": 7.75, "y": 2}, + {"matrix": [2, 9], "x": 8.75, "y": 2}, + {"matrix": [2, 10], "x": 9.75, "y": 2, "w": 1.25}, + {"matrix": [2, 11], "x": 11, "y": 2}, - {"x":0, "y":3, "w":1.25}, - {"x":1.25, "y":3}, - {"x":2.25, "y":3}, - {"x":3.25, "y":3, "w":6.25}, - {"x":9.5, "y":3, "w":1.25}, - {"x":10.75, "y":3, "w":1.25} + {"matrix": [3, 0], "x": 0, "y": 3, "w": 1.25}, + {"matrix": [3, 1], "x": 1.25, "y": 3}, + {"matrix": [3, 2], "x": 2.25, "y": 3}, + {"matrix": [3, 5], "x": 3.25, "y": 3, "w": 6.25}, + {"matrix": [3, 10], "x": 9.5, "y": 3, "w": 1.25}, + {"matrix": [3, 11], "x": 10.75, "y": 3, "w": 1.25} ] }, "LAYOUT_ortho_600u_space": { "layout": [ - {"label":"K00 (F4,F1)", "x":0, "y":0}, - {"label":"K01 (F4,F0)", "x":1, "y":0}, - {"label":"K02 (F4,E6)", "x":2, "y":0}, - {"label":"K03 (F4,C7)", "x":3, "y":0}, - {"label":"K04 (F4,C6)", "x":4, "y":0}, - {"label":"K05 (F4,B0)", "x":5, "y":0}, - {"label":"K06 (F4,D4)", "x":6, "y":0}, - {"label":"K07 (F4,B1)", "x":7, "y":0}, - {"label":"K08 (F4,B7)", "x":8, "y":0}, - {"label":"K09 (F4,B5)", "x":9, "y":0}, - {"label":"K0A (F4,B4)", "x":10, "y":0}, - {"label":"K0B (F4,D7)", "x":11, "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}, - {"label":"K10 (F5,F1)", "x":0, "y":1}, - {"label":"K11 (F5,F0)", "x":1, "y":1}, - {"label":"K12 (F5,E6)", "x":2, "y":1}, - {"label":"K13 (F5,C7)", "x":3, "y":1}, - {"label":"K14 (F5,C6)", "x":4, "y":1}, - {"label":"K15 (F5,B0)", "x":5, "y":1}, - {"label":"K16 (F5,D4)", "x":6, "y":1}, - {"label":"K17 (F5,B1)", "x":7, "y":1}, - {"label":"K18 (F5,B7)", "x":8, "y":1}, - {"label":"K19 (F5,B5)", "x":9, "y":1}, - {"label":"K1A (F5,B4)", "x":10, "y":1}, - {"label":"K1B (F5,D7)", "x":11, "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}, - {"label":"K20 (F6,F1)", "x":0, "y":2}, - {"label":"K21 (F6,F0)", "x":1, "y":2}, - {"label":"K22 (F6,E6)", "x":2, "y":2}, - {"label":"K23 (F6,C7)", "x":3, "y":2}, - {"label":"K24 (F6,C6)", "x":4, "y":2}, - {"label":"K25 (F6,B0)", "x":5, "y":2}, - {"label":"K26 (F6,D4)", "x":6, "y":2}, - {"label":"K27 (F6,B1)", "x":7, "y":2}, - {"label":"K28 (F6,B7)", "x":8, "y":2}, - {"label":"K29 (F6,B5)", "x":9, "y":2}, - {"label":"K2A (F6,B4)", "x":10, "y":2}, - {"label":"K2B (F6,D7)", "x":11, "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}, - {"label":"K30 (F7,F1)", "x":0, "y":3}, - {"label":"K31 (F7,F0)", "x":1, "y":3}, - {"label":"K32 (F7,E6)", "x":2, "y":3}, - {"label":"K35 (F7,B0)", "x":3, "y":3, "w":6}, - {"label":"K39 (F7,B5)", "x":9, "y":3}, - {"label":"K3A (F7,B4)", "x":10, "y":3}, - {"label":"K3B (F7,D7)", "x":11, "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, 5], "x": 3, "y": 3, "w": 6}, + {"matrix": [3, 9], "x": 9, "y": 3}, + {"matrix": [3, 10], "x": 10, "y": 3}, + {"matrix": [3, 11], "x": 11, "y": 3} ] }, "LAYOUT_ortho_275u_space": { "layout": [ - {"label":"K00 (F4,F1)", "x":0, "y":0}, - {"label":"K01 (F4,F0)", "x":1, "y":0}, - {"label":"K02 (F4,E6)", "x":2, "y":0}, - {"label":"K03 (F4,C7)", "x":3, "y":0}, - {"label":"K04 (F4,C6)", "x":4, "y":0}, - {"label":"K05 (F4,B0)", "x":5, "y":0}, - {"label":"K06 (F4,D4)", "x":6, "y":0}, - {"label":"K07 (F4,B1)", "x":7, "y":0}, - {"label":"K08 (F4,B7)", "x":8, "y":0}, - {"label":"K09 (F4,B5)", "x":9, "y":0}, - {"label":"K0A (F4,B4)", "x":10, "y":0}, - {"label":"K0B (F4,D7)", "x":11, "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}, - {"label":"K10 (F5,F1)", "x":0, "y":1}, - {"label":"K11 (F5,F0)", "x":1, "y":1}, - {"label":"K12 (F5,E6)", "x":2, "y":1}, - {"label":"K13 (F5,C7)", "x":3, "y":1}, - {"label":"K14 (F5,C6)", "x":4, "y":1}, - {"label":"K15 (F5,B0)", "x":5, "y":1}, - {"label":"K16 (F5,D4)", "x":6, "y":1}, - {"label":"K17 (F5,B1)", "x":7, "y":1}, - {"label":"K18 (F5,B7)", "x":8, "y":1}, - {"label":"K19 (F5,B5)", "x":9, "y":1}, - {"label":"K1A (F5,B4)", "x":10, "y":1}, - {"label":"K1B (F5,D7)", "x":11, "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}, - {"label":"K20 (F6,F1)", "x":0, "y":2}, - {"label":"K21 (F6,F0)", "x":1, "y":2}, - {"label":"K22 (F6,E6)", "x":2, "y":2}, - {"label":"K23 (F6,C7)", "x":3, "y":2}, - {"label":"K24 (F6,C6)", "x":4, "y":2}, - {"label":"K25 (F6,B0)", "x":5, "y":2}, - {"label":"K26 (F6,D4)", "x":6, "y":2}, - {"label":"K27 (F6,B1)", "x":7, "y":2}, - {"label":"K28 (F6,B7)", "x":8, "y":2}, - {"label":"K29 (F6,B5)", "x":9, "y":2}, - {"label":"K2A (F6,B4)", "x":10, "y":2}, - {"label":"K2B (F6,D7)", "x":11, "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}, - {"label":"K30 (F7,F1)", "x":0, "y":3}, - {"label":"K31 (F7,F0)", "x":1, "y":3}, - {"label":"K32 (F7,E6)", "x":2, "y":3}, - {"label":"K33 (F7,C7)", "x":3, "y":3}, - {"label":"K34 (F7,C6)", "x":4, "y":3}, - {"label":"K35 (F7,B0)", "x":5, "y":3, "w":2.75}, - {"label":"K38 (F7,B7)", "x":7.75, "y":3, "w":1.25}, - {"label":"K39 (F7,B5)", "x":9, "y":3}, - {"label":"K3A (F7,B4)", "x":10, "y":3}, - {"label":"K3B (F7,D7)", "x":11, "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, "w": 2.75}, + {"matrix": [3, 8], "x": 7.75, "y": 3, "w": 1.25}, + {"matrix": [3, 9], "x": 9, "y": 3}, + {"matrix": [3, 10], "x": 10, "y": 3}, + {"matrix": [3, 11], "x": 11, "y": 3} ] } } diff --git a/keyboards/amjkeyboard/amjpad/amjpad.h b/keyboards/amjkeyboard/amjpad/amjpad.h deleted file mode 100644 index 976a7ab041..0000000000 --- a/keyboards/amjkeyboard/amjpad/amjpad.h +++ /dev/null @@ -1,58 +0,0 @@ -#pragma once - -#include "quantum.h" - -// readability -#define XXX KC_NO - -/* AMJPAD matrix layout - * ,-------------------. - * | 00 | 01 | 02 | 03 | - * |----|----|----|----| - * | 10 | 11 | 12 | 13 | - * |----|----|----|----| - * | 20 | 21 | 22 | | - * |----|----|----| 23 | - * | 30 | 31 | 32 | | - * |----|----|----|----| - * | 40 | 41 | 42 | | - * |----|----|----| 43 | - * | 50 | 52 | | - * `-------------------' - */ -// The first section contains all of the arguments -// The second converts the arguments into a two-dimensional array -#define LAYOUT_numpad_6x4( \ - k00, k01, k02, k03, \ - k10, k11, k12, k13, \ - k20, k21, k22, \ - k30, k31, k32, k23, \ - k40, k41, k42, \ - k50, k52, k43 \ -) { \ - { k00, k01, k02, k03 }, \ - { k10, k11, k12, k13 }, \ - { k20, k21, k22, k23 }, \ - { k30, k31, k32, XXX }, \ - { k40, k41, k42, k43 }, \ - { k50, XXX, k52, XXX } \ -} - -#define LAYOUT_ortho_6x4( \ - k00, k01, k02, k03, \ - k10, k11, k12, k13, \ - k20, k21, k22, k23, \ - k30, k31, k32, k33, \ - k40, k41, k42, k43, \ - k50, k51, k52, k53 \ -) { \ - { k00, k01, k02, k03 }, \ - { k10, k11, k12, k13 }, \ - { k20, k21, k22, k23 }, \ - { k30, k31, k32, k33 }, \ - { k40, k41, k42, k43 }, \ - { k50, k51, k52, k53 } \ -} - -void matrix_init_user(void); -void matrix_scan_user(void); diff --git a/keyboards/amjkeyboard/amjpad/info.json b/keyboards/amjkeyboard/amjpad/info.json index 3bd3a7f24c..05292cc53d 100644 --- a/keyboards/amjkeyboard/amjpad/info.json +++ b/keyboards/amjkeyboard/amjpad/info.json @@ -26,10 +26,67 @@ "community_layouts": ["numpad_6x4", "ortho_6x4"], "layouts": { "LAYOUT_numpad_6x4": { - "layout": [{"label":"k00", "x":0, "y":0}, {"label":"k01", "x":1, "y":0}, {"label":"k02", "x":2, "y":0}, {"label":"k03", "x":3, "y":0}, {"label":"k10", "x":0, "y":1}, {"label":"k11", "x":1, "y":1}, {"label":"k12", "x":2, "y":1}, {"label":"k13", "x":3, "y":1}, {"label":"k20", "x":0, "y":2}, {"label":"k21", "x":1, "y":2}, {"label":"k22", "x":2, "y":2}, {"label":"k30", "x":0, "y":3}, {"label":"k31", "x":1, "y":3}, {"label":"k32", "x":2, "y":3}, {"label":"k23", "x":3, "y":2, "h":2}, {"label":"k40", "x":0, "y":4}, {"label":"k41", "x":1, "y":4}, {"label":"k42", "x":2, "y":4}, {"label":"k50", "x":0, "y":5, "w":2}, {"label":"k52", "x":2, "y":5}, {"label":"k43", "x":3, "y":4, "h":2}] + "layout": [ + {"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": [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": [2, 0], "x": 0, "y": 2}, + {"matrix": [2, 1], "x": 1, "y": 2}, + {"matrix": [2, 2], "x": 2, "y": 2}, + + {"matrix": [3, 0], "x": 0, "y": 3}, + {"matrix": [3, 1], "x": 1, "y": 3}, + {"matrix": [3, 2], "x": 2, "y": 3}, + {"matrix": [2, 3], "x": 3, "y": 2, "h": 2}, + + {"matrix": [4, 0], "x": 0, "y": 4}, + {"matrix": [4, 1], "x": 1, "y": 4}, + {"matrix": [4, 2], "x": 2, "y": 4}, + + {"matrix": [5, 0], "x": 0, "y": 5, "w": 2}, + {"matrix": [5, 2], "x": 2, "y": 5}, + {"matrix": [4, 3], "x": 3, "y": 4, "h": 2} + ] }, "LAYOUT_ortho_6x4": { - "layout": [{"label":"k00", "x":0, "y":0}, {"label":"k01", "x":1, "y":0}, {"label":"k02", "x":2, "y":0}, {"label":"k03", "x":3, "y":0}, {"label":"k10", "x":0, "y":1}, {"label":"k11", "x":1, "y":1}, {"label":"k12", "x":2, "y":1}, {"label":"k13", "x":3, "y":1}, {"label":"k20", "x":0, "y":2}, {"label":"k21", "x":1, "y":2}, {"label":"k22", "x":2, "y":2}, {"label":"k23", "x":3, "y":2}, {"label":"k30", "x":0, "y":3}, {"label":"k31", "x":1, "y":3}, {"label":"k32", "x":2, "y":3}, {"label":"k33", "x":3, "y":3}, {"label":"k40", "x":0, "y":4}, {"label":"k41", "x":1, "y":4}, {"label":"k42", "x":2, "y":4}, {"label":"k43", "x":3, "y":4}, {"label":"k50", "x":0, "y":5}, {"label":"k51", "x":1, "y":5}, {"label":"k52", "x":2, "y":5}, {"label":"k53", "x":3, "y":5}] + "layout": [ + {"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": [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": [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": [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": [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": [5, 0], "x": 0, "y": 5}, + {"matrix": [5, 1], "x": 1, "y": 5}, + {"matrix": [5, 2], "x": 2, "y": 5}, + {"matrix": [5, 3], "x": 3, "y": 5} + ] } } } |