summary refs log tree commit diff
path: root/keyboards/opendeck
diff options
context:
space:
mode:
authorRyan <fauxpark@gmail.com>2023-03-29 15:54:34 +1100
committerGitHub <noreply@github.com>2023-03-29 15:54:34 +1100
commit4869b8061c187f6476f8f14b839dd2c2c9f74dd2 (patch)
tree085ba6c614b0cc649a664b6e9e8829ee6f1fe593 /keyboards/opendeck
parent06664e8a94116b5d40b2348ec89ba2fc6248ec16 (diff)
Move ortho & numpad layouts to data driven (#20183)
Co-authored-by: Nick Brassel <nick@tzarc.org>
Diffstat (limited to 'keyboards/opendeck')
-rw-r--r--keyboards/opendeck/32/info.json41
-rw-r--r--keyboards/opendeck/32/rev1/info.json43
-rw-r--r--keyboards/opendeck/32/rev1/rev1.h14
3 files changed, 42 insertions, 56 deletions
diff --git a/keyboards/opendeck/32/info.json b/keyboards/opendeck/32/info.json
index 8e22d925b1..137a988c6d 100644
--- a/keyboards/opendeck/32/info.json
+++ b/keyboards/opendeck/32/info.json
@@ -5,46 +5,5 @@
         "vid": "0x4345",
         "pid": "0x2EC0",
         "device_version": "0.0.1"
-    },
-    "layouts": {
-        "LAYOUT_ortho_4x8": {
-            "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":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":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":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 }
-            ]
-        }
     }
 }
diff --git a/keyboards/opendeck/32/rev1/info.json b/keyboards/opendeck/32/rev1/info.json
index 06d5626fa9..df4d338fc0 100644
--- a/keyboards/opendeck/32/rev1/info.json
+++ b/keyboards/opendeck/32/rev1/info.json
@@ -5,5 +5,46 @@
     },
     "diode_direction": "COL2ROW",
     "processor": "atmega32u4",
-    "bootloader": "atmel-dfu"
+    "bootloader": "atmel-dfu",
+    "layouts": {
+        "LAYOUT_ortho_4x8": {
+            "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": [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": [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": [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": [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}
+            ]
+        }
+    }
 }
diff --git a/keyboards/opendeck/32/rev1/rev1.h b/keyboards/opendeck/32/rev1/rev1.h
index 9c208df8a8..69777d95ab 100644
--- a/keyboards/opendeck/32/rev1/rev1.h
+++ b/keyboards/opendeck/32/rev1/rev1.h
@@ -29,17 +29,3 @@
 // Note: The default is to not wrap and to send F13-F24 with combinations of shift/control/alt as these
 // are immediately usable in most software (e.g. OBS and DCSB for streaming) without using AHK.
 //#define KC_WRAPPER_KEY KC_F24
-
-// clang-format off
-#define LAYOUT_ortho_4x8( \
-    Q00, Q01, Q02, Q03, Q04, Q05, Q06, Q07, \
-    Q10, Q11, Q12, Q13, Q14, Q15, Q16, Q17, \
-    Q20, Q21, Q22, Q23, Q24, Q25, Q26, Q27, \
-    Q30, Q31, Q32, Q33, Q34, Q35, Q36, Q37  \
-) { \
-    {Q00, Q01, Q02, Q03, Q04, Q05, Q06, Q07}, \
-    {Q10, Q11, Q12, Q13, Q14, Q15, Q16, Q17}, \
-    {Q20, Q21, Q22, Q23, Q24, Q25, Q26, Q27}, \
-    {Q30, Q31, Q32, Q33, Q34, Q35, Q36, Q37}  \
-}
-// clang-format on