|
9 | 9 | #include <st/f0/stm32f072c(8-b)tx-pinctrl.dtsi>
|
10 | 10 | #include <dt-bindings/led/led.h>
|
11 | 11 |
|
| 12 | +#include <dt-bindings/zmk/matrix_transform.h> |
| 13 | + |
| 14 | +#include <physical_layouts.dtsi> |
| 15 | + |
12 | 16 | / {
|
13 | 17 | model = "Keeb.io BDN9 rev2";
|
14 | 18 | compatible = "keebio,bdn9", "st,stm32f072";
|
|
20 | 24 | zmk,underglow = &led_strip;
|
21 | 25 | };
|
22 | 26 |
|
| 27 | + matrix_transform: matrix_transform { |
| 28 | + compatible = "zmk,matrix-transform"; |
| 29 | + |
| 30 | + compatible = "zmk,matrix-transform"; |
| 31 | + columns = <3>; |
| 32 | + rows = <3>; |
| 33 | + map = < |
| 34 | + RC(0,0) RC(0,1) RC(0,2) |
| 35 | + RC(0,3) RC(0,4) RC(0,5) |
| 36 | + RC(0,6) RC(0,7) RC(0,8) |
| 37 | + >; |
| 38 | + }; |
| 39 | + |
| 40 | + physical_layout { |
| 41 | + compatible = "zmk,physical-layout"; |
| 42 | + |
| 43 | + display-name = "BDN9"; |
| 44 | + transform = <&matrix_transform>; |
| 45 | + |
| 46 | + keys // w h x y rot rx ry |
| 47 | + = <&key_physical_attrs 100 100 0 0 0 0 0> |
| 48 | + , <&key_physical_attrs 100 100 100 0 0 0 0> |
| 49 | + , <&key_physical_attrs 100 100 200 0 0 0 0> |
| 50 | + , <&key_physical_attrs 100 100 0 100 0 0 0> |
| 51 | + , <&key_physical_attrs 100 100 100 100 0 0 0> |
| 52 | + , <&key_physical_attrs 100 100 200 100 0 0 0> |
| 53 | + , <&key_physical_attrs 100 100 0 200 0 0 0> |
| 54 | + , <&key_physical_attrs 100 100 100 200 0 0 0> |
| 55 | + , <&key_physical_attrs 100 100 200 200 0 0 0> |
| 56 | + ; |
| 57 | + }; |
| 58 | + |
23 | 59 | kscan: kscan {
|
24 | 60 | compatible = "zmk,kscan-gpio-direct";
|
25 | 61 |
|
|
0 commit comments