Skip to content

Commit

Permalink
feat(studio): Add ortho_4x10 grid layout (zmkfirmware#2651)
Browse files Browse the repository at this point in the history
* added 4x10 grid layout

Co-authored-by: Cem Aksoylar <[email protected]>
  • Loading branch information
pabile and caksoylar authored Dec 9, 2024
1 parent 0820991 commit 7e8c542
Show file tree
Hide file tree
Showing 3 changed files with 135 additions and 0 deletions.
64 changes: 64 additions & 0 deletions app/dts/layouts/common/ortho_4x10/1x2u.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
#include <layouts/common/ortho_4x10/position_map.dtsi>
#include <physical_layouts.dtsi>

/ {
layout_ortho_4x10_1x2u: layout_ortho_4x10_1x2u {
compatible = "zmk,physical-layout";
display-name = "1x2U Space";

keys // w h x y rot rx ry
= <&key_physical_attrs 100 100 0 0 0 0 0>
, <&key_physical_attrs 100 100 100 0 0 0 0>
, <&key_physical_attrs 100 100 200 0 0 0 0>
, <&key_physical_attrs 100 100 300 0 0 0 0>
, <&key_physical_attrs 100 100 400 0 0 0 0>
, <&key_physical_attrs 100 100 500 0 0 0 0>
, <&key_physical_attrs 100 100 600 0 0 0 0>
, <&key_physical_attrs 100 100 700 0 0 0 0>
, <&key_physical_attrs 100 100 800 0 0 0 0>
, <&key_physical_attrs 100 100 900 0 0 0 0>
, <&key_physical_attrs 100 100 0 100 0 0 0>
, <&key_physical_attrs 100 100 100 100 0 0 0>
, <&key_physical_attrs 100 100 200 100 0 0 0>
, <&key_physical_attrs 100 100 300 100 0 0 0>
, <&key_physical_attrs 100 100 400 100 0 0 0>
, <&key_physical_attrs 100 100 500 100 0 0 0>
, <&key_physical_attrs 100 100 600 100 0 0 0>
, <&key_physical_attrs 100 100 700 100 0 0 0>
, <&key_physical_attrs 100 100 800 100 0 0 0>
, <&key_physical_attrs 100 100 900 100 0 0 0>
, <&key_physical_attrs 100 100 0 200 0 0 0>
, <&key_physical_attrs 100 100 100 200 0 0 0>
, <&key_physical_attrs 100 100 200 200 0 0 0>
, <&key_physical_attrs 100 100 300 200 0 0 0>
, <&key_physical_attrs 100 100 400 200 0 0 0>
, <&key_physical_attrs 100 100 500 200 0 0 0>
, <&key_physical_attrs 100 100 600 200 0 0 0>
, <&key_physical_attrs 100 100 700 200 0 0 0>
, <&key_physical_attrs 100 100 800 200 0 0 0>
, <&key_physical_attrs 100 100 900 200 0 0 0>
, <&key_physical_attrs 100 100 0 300 0 0 0>
, <&key_physical_attrs 100 100 100 300 0 0 0>
, <&key_physical_attrs 100 100 200 300 0 0 0>
, <&key_physical_attrs 100 100 300 300 0 0 0>
, <&key_physical_attrs 200 100 400 300 0 0 0>
, <&key_physical_attrs 100 100 600 300 0 0 0>
, <&key_physical_attrs 100 100 700 300 0 0 0>
, <&key_physical_attrs 100 100 800 300 0 0 0>
, <&key_physical_attrs 100 100 900 300 0 0 0>
;
};
};

&layouts_common_ortho_4x10_position_map {
layout_ortho_4x10_1x2u_posmap: layout_ortho_4x10_1x2u {
physical-layout = <&layout_ortho_4x10_1x2u>;
positions
= < 0 1 2 3 4 5 6 7 8 9>
, <10 11 12 13 14 15 16 17 18 19>
, <20 21 22 23 24 25 26 27 28 29>
, <30 31 32 33 34 39 35 36 37 38>
;
};
};

64 changes: 64 additions & 0 deletions app/dts/layouts/common/ortho_4x10/all1u.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
#include <layouts/common/ortho_4x10/position_map.dtsi>
#include <physical_layouts.dtsi>

/ {
layout_ortho_4x10_all1u: layout_ortho_4x10_all1u {
compatible = "zmk,physical-layout";
display-name = "All 1U/Grid";

keys // w h x y rot rx ry
= <&key_physical_attrs 100 100 0 0 0 0 0>
, <&key_physical_attrs 100 100 100 0 0 0 0>
, <&key_physical_attrs 100 100 200 0 0 0 0>
, <&key_physical_attrs 100 100 300 0 0 0 0>
, <&key_physical_attrs 100 100 400 0 0 0 0>
, <&key_physical_attrs 100 100 500 0 0 0 0>
, <&key_physical_attrs 100 100 600 0 0 0 0>
, <&key_physical_attrs 100 100 700 0 0 0 0>
, <&key_physical_attrs 100 100 800 0 0 0 0>
, <&key_physical_attrs 100 100 900 0 0 0 0>
, <&key_physical_attrs 100 100 0 100 0 0 0>
, <&key_physical_attrs 100 100 100 100 0 0 0>
, <&key_physical_attrs 100 100 200 100 0 0 0>
, <&key_physical_attrs 100 100 300 100 0 0 0>
, <&key_physical_attrs 100 100 400 100 0 0 0>
, <&key_physical_attrs 100 100 500 100 0 0 0>
, <&key_physical_attrs 100 100 600 100 0 0 0>
, <&key_physical_attrs 100 100 700 100 0 0 0>
, <&key_physical_attrs 100 100 800 100 0 0 0>
, <&key_physical_attrs 100 100 900 100 0 0 0>
, <&key_physical_attrs 100 100 0 200 0 0 0>
, <&key_physical_attrs 100 100 100 200 0 0 0>
, <&key_physical_attrs 100 100 200 200 0 0 0>
, <&key_physical_attrs 100 100 300 200 0 0 0>
, <&key_physical_attrs 100 100 400 200 0 0 0>
, <&key_physical_attrs 100 100 500 200 0 0 0>
, <&key_physical_attrs 100 100 600 200 0 0 0>
, <&key_physical_attrs 100 100 700 200 0 0 0>
, <&key_physical_attrs 100 100 800 200 0 0 0>
, <&key_physical_attrs 100 100 900 200 0 0 0>
, <&key_physical_attrs 100 100 0 300 0 0 0>
, <&key_physical_attrs 100 100 100 300 0 0 0>
, <&key_physical_attrs 100 100 200 300 0 0 0>
, <&key_physical_attrs 100 100 300 300 0 0 0>
, <&key_physical_attrs 100 100 400 300 0 0 0>
, <&key_physical_attrs 100 100 500 300 0 0 0>
, <&key_physical_attrs 100 100 600 300 0 0 0>
, <&key_physical_attrs 100 100 700 300 0 0 0>
, <&key_physical_attrs 100 100 800 300 0 0 0>
, <&key_physical_attrs 100 100 900 300 0 0 0>
;
};
};

&layouts_common_ortho_4x10_position_map {
layout_ortho_4x10_all1u_posmap: layout_ortho_4x10_all1u {
physical-layout = <&layout_ortho_4x10_all1u>;
positions
= < 0 1 2 3 4 5 6 7 8 9>
, <10 11 12 13 14 15 16 17 18 19>
, <20 21 22 23 24 25 26 27 28 29>
, <30 31 32 33 34 35 36 37 38 39>
;
};
};
7 changes: 7 additions & 0 deletions app/dts/layouts/common/ortho_4x10/position_map.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
/ {
layouts_common_ortho_4x10_position_map: layouts_common_ortho_4x10_position_map {
compatible = "zmk,physical-layout-position-map";

complete;
};
};

0 comments on commit 7e8c542

Please sign in to comment.