Skip to content

Commit

Permalink
Merge branch 'main' into Form-studio-2
Browse files Browse the repository at this point in the history
  • Loading branch information
ReFil committed Oct 4, 2024
2 parents 0789a6e + 29b39f2 commit 89c8f0a
Show file tree
Hide file tree
Showing 118 changed files with 3,527 additions and 823 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-user-config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ on:

jobs:
matrix:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
name: Fetch Build Keyboards
outputs:
build_matrix: ${{ env.build_matrix }}
Expand Down
1 change: 1 addition & 0 deletions app/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ menuconfig ZMK_BLE
select BT_SMP_APP_PAIRING_ACCEPT
select BT_PERIPHERAL
select BT_DIS
imply BT_DEVICE_NAME_DYNAMIC
imply BT_SETTINGS if !ARCH_POSIX
imply SETTINGS if !ARCH_POSIX
imply ZMK_BATTERY_REPORTING if !ARCH_POSIX
Expand Down
90 changes: 89 additions & 1 deletion app/boards/arm/adv360pro/adv360pro.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
#include <dt-bindings/led/led.h>
#include <dt-bindings/zmk/matrix_transform.h>

#include <physical_layouts.dtsi>

#include "adv360pro-pinctrl.dtsi"

/ {
Expand All @@ -24,7 +26,7 @@
zmk,kscan = &kscan0;
zmk,backlight = &backlight;
zmk,battery = &vbatt;
zmk,matrix-transform = &default_transform;
zmk,physical-layout = &default_layout;
zmk,underglow = &led_strip;
};

Expand All @@ -44,6 +46,92 @@
>;
};

default_layout: default_layout {
compatible = "zmk,physical-layout";
display-name = "Default";

transform = <&default_transform>;

keys // w h x y rot rx ry
= <&key_physical_attrs 125 100 0 25 0 0 0>
, <&key_physical_attrs 100 100 125 25 0 0 0>
, <&key_physical_attrs 100 100 225 0 0 0 0>
, <&key_physical_attrs 100 100 325 0 0 0 0>
, <&key_physical_attrs 100 100 425 0 0 0 0>
, <&key_physical_attrs 100 100 525 0 0 0 0>
, <&key_physical_attrs 100 100 625 0 0 0 0>
, <&key_physical_attrs 100 100 1075 0 0 0 0>
, <&key_physical_attrs 100 100 1175 0 0 0 0>
, <&key_physical_attrs 100 100 1275 0 0 0 0>
, <&key_physical_attrs 100 100 1375 0 0 0 0>
, <&key_physical_attrs 100 100 1475 0 0 0 0>
, <&key_physical_attrs 100 100 1575 25 0 0 0>
, <&key_physical_attrs 125 100 1675 25 0 0 0>
, <&key_physical_attrs 125 100 0 125 0 0 0>
, <&key_physical_attrs 100 100 125 125 0 0 0>
, <&key_physical_attrs 100 100 225 100 0 0 0>
, <&key_physical_attrs 100 100 325 100 0 0 0>
, <&key_physical_attrs 100 100 425 100 0 0 0>
, <&key_physical_attrs 100 100 525 100 0 0 0>
, <&key_physical_attrs 100 100 625 100 0 0 0>
, <&key_physical_attrs 100 100 1075 100 0 0 0>
, <&key_physical_attrs 100 100 1175 100 0 0 0>
, <&key_physical_attrs 100 100 1275 100 0 0 0>
, <&key_physical_attrs 100 100 1375 100 0 0 0>
, <&key_physical_attrs 100 100 1475 100 0 0 0>
, <&key_physical_attrs 100 100 1575 125 0 0 0>
, <&key_physical_attrs 125 100 1675 125 0 0 0>
, <&key_physical_attrs 125 100 0 225 0 0 0>
, <&key_physical_attrs 100 100 125 225 0 0 0>
, <&key_physical_attrs 100 100 225 200 0 0 0>
, <&key_physical_attrs 100 100 325 200 0 0 0>
, <&key_physical_attrs 100 100 425 200 0 0 0>
, <&key_physical_attrs 100 100 525 200 0 0 0>
, <&key_physical_attrs 100 100 625 200 0 0 0>
, <&key_physical_attrs 100 100 675 400 1500 525 400>
, <&key_physical_attrs 100 100 775 400 1500 525 400>
, <&key_physical_attrs 100 100 925 400 (-1500) 1275 400>
, <&key_physical_attrs 100 100 1025 400 (-1500) 1275 400>
, <&key_physical_attrs 100 100 1075 200 0 0 0>
, <&key_physical_attrs 100 100 1175 200 0 0 0>
, <&key_physical_attrs 100 100 1275 200 0 0 0>
, <&key_physical_attrs 100 100 1375 200 0 0 0>
, <&key_physical_attrs 100 100 1475 200 0 0 0>
, <&key_physical_attrs 100 100 1575 225 0 0 0>
, <&key_physical_attrs 125 100 1675 225 0 0 0>
, <&key_physical_attrs 125 100 0 325 0 0 0>
, <&key_physical_attrs 100 100 125 325 0 0 0>
, <&key_physical_attrs 100 100 225 300 0 0 0>
, <&key_physical_attrs 100 100 325 300 0 0 0>
, <&key_physical_attrs 100 100 425 300 0 0 0>
, <&key_physical_attrs 100 100 525 300 0 0 0>
, <&key_physical_attrs 100 100 775 500 1500 525 400>
, <&key_physical_attrs 100 100 925 500 (-1500) 1275 400>
, <&key_physical_attrs 100 100 1175 300 0 0 0>
, <&key_physical_attrs 100 100 1275 300 0 0 0>
, <&key_physical_attrs 100 100 1375 300 0 0 0>
, <&key_physical_attrs 100 100 1475 300 0 0 0>
, <&key_physical_attrs 100 100 1575 325 0 0 0>
, <&key_physical_attrs 125 100 1675 325 0 0 0>
, <&key_physical_attrs 125 100 0 425 0 0 0>
, <&key_physical_attrs 100 100 125 425 0 0 0>
, <&key_physical_attrs 100 100 225 400 0 0 0>
, <&key_physical_attrs 100 100 325 400 0 0 0>
, <&key_physical_attrs 100 100 425 400 0 0 0>
, <&key_physical_attrs 100 200 575 500 1500 525 400>
, <&key_physical_attrs 100 200 675 500 1500 525 400>
, <&key_physical_attrs 100 100 775 600 1500 525 400>
, <&key_physical_attrs 100 100 925 600 (-1500) 1275 400>
, <&key_physical_attrs 100 200 1025 500 (-1500) 1275 400>
, <&key_physical_attrs 100 200 1125 500 (-1500) 1275 400>
, <&key_physical_attrs 100 100 1275 400 0 0 0>
, <&key_physical_attrs 100 100 1375 400 0 0 0>
, <&key_physical_attrs 100 100 1475 400 0 0 0>
, <&key_physical_attrs 100 100 1575 425 0 0 0>
, <&key_physical_attrs 125 100 1675 425 0 0 0>
;
};

// Node name must match original "EXT_POWER" label to preserve user settings.
EXT_POWER {
compatible = "zmk,ext-power-generic";
Expand Down
36 changes: 36 additions & 0 deletions app/boards/arm/bdn9/bdn9_rev2.dts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
#include <st/f0/stm32f072c(8-b)tx-pinctrl.dtsi>
#include <dt-bindings/led/led.h>

#include <dt-bindings/zmk/matrix_transform.h>

#include <physical_layouts.dtsi>

/ {
model = "Keeb.io BDN9 rev2";
compatible = "keebio,bdn9", "st,stm32f072";
Expand All @@ -20,6 +24,38 @@
zmk,underglow = &led_strip;
};

matrix_transform: matrix_transform {
compatible = "zmk,matrix-transform";

compatible = "zmk,matrix-transform";
columns = <3>;
rows = <3>;
map = <
RC(0,0) RC(0,1) RC(0,2)
RC(0,3) RC(0,4) RC(0,5)
RC(0,6) RC(0,7) RC(0,8)
>;
};

physical_layout {
compatible = "zmk,physical-layout";

display-name = "BDN9";
transform = <&matrix_transform>;

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 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 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>
;
};

kscan: kscan {
compatible = "zmk,kscan-gpio-direct";

Expand Down
2 changes: 0 additions & 2 deletions app/boards/arm/bt60/bt60.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
zephyr,sram = &sram0;
zephyr,flash = &flash0;
zmk,battery = &vbatt;
zmk,kscan = &kscan0;
zmk,matrix-transform = &default_transform;
};

sensors: sensors {
Expand Down
35 changes: 21 additions & 14 deletions app/boards/arm/bt60/bt60_v1.dts
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,16 @@

/dts-v1/;
#include "bt60.dtsi"
#include <layouts/common/60percent/all1u.dtsi>
#include <layouts/common/60percent/ansi.dtsi>
#include <layouts/common/60percent/hhkb.dtsi>
#include <layouts/common/60percent/iso.dtsi>


/ {
chosen {
zmk,kscan = &kscan0;
zmk,matrix-transform = &ansi_transform;
zmk,physical-layout = &layout_60_ansi;
};

ansi_transform: keymap_transform_0 {
Expand Down Expand Up @@ -66,19 +70,6 @@
>;
};

split_transform: keymap_transform_4 {
compatible = "zmk,matrix-transform";
columns = <15>;
rows = <5>;
map = <
RC(0,0) RC(0,1) RC(0,2) RC(0,3) RC(0,4) RC(0,5) RC(0,6) RC(0,7) RC(0,8) RC(0,9) RC(0,10) RC(0,11) RC(0,12) RC(0,13) RC(0,14)
RC(1,0) RC(1,1) RC(1,2) RC(1,3) RC(1,4) RC(1,5) RC(1,6) RC(1,7) RC(1,8) RC(1,9) RC(1,10) RC(1,11) RC(1,12) RC(1,13)
RC(2,0) RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,6) RC(2,7) RC(2,8) RC(2,9) RC(2,10) RC(2,11) RC(2,13)
RC(3,0) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7) RC(3,8) RC(3,9) RC(3,10) RC(3,11) RC(3,12) RC(3,14)
RC(4,0) RC(4,1) RC(4,2) RC(4,6) RC(4,10) RC(4,11) RC(4,12) RC(4,13)
>;
};

kscan0: kscan_0 {
compatible = "zmk,kscan-gpio-matrix";
wakeup-source;
Expand Down Expand Up @@ -112,3 +103,19 @@
;
};
};

&layout_60_ansi {
transform = <&ansi_transform>;
};

&layout_60_iso {
transform = <&iso_transform>;
};

&layout_60_all1u {
transform = <&all_1u_transform>;
};

&layout_60_hhkb {
transform = <&hhkb_transform>;
};
49 changes: 11 additions & 38 deletions app/boards/arm/bt60/bt60_v1.keymap
Original file line number Diff line number Diff line change
Expand Up @@ -2,26 +2,25 @@
#include <dt-bindings/zmk/keys.h>
#include <dt-bindings/zmk/bt.h>

#define ANSI true
//#define HHKB true
//#define ISO true
//#define ALL_1U true
//#define SPLIT_BKSP_RSHFT true
#define ANSI
//#define HHKB
//#define ISO
//#define ALL_1U



/ {
chosen {
#ifdef ANSI
zmk,matrix-transform = &ansi_transform;
#elif defined(HHKB)
zmk,matrix-transform = &hhkb_transform;
zmk,physical-layout = &layout_60_ansi;
#elif defined(ISO)
zmk,matrix-transform = &iso_transform;
zmk,physical-layout = &layout_60_iso;
#elif defined(ALL_1U)
zmk,matrix-transform = &all_1u_transform;
zmk,physical-layout = &layout_60_all1u;
#elif defined(HHKB)
zmk,physical-layout = &layout_60_hhkb;
#else
zmk,matrix-transform = &split_transform;
#error "Layout not defined, please define a layout by uncommenting the appropriate line in bt60_v1.keymap"
#endif
};

Expand Down Expand Up @@ -148,33 +147,7 @@
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
};
#else
default_layer {
// ------------------------------------------------------------------------------------------
// | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = |BSPC| DEL |
// | TAB | Q | W | E | R | T | Y | U | I | O | P | [ | ] | \ |
// | CAPS | A | S | D | F | G | H | J | K | L | ; | ' | ENTER |
// | SHIFT | Z | X | C | V | B | N | M | , | . | / | SHIFT | 1 |
// | CTL | WIN | ALT | SPACE | ALT | 1 | CTRL |
// ------------------------------------------------------------------------------------------
bindings = <
&kp ESC &kp N1 &kp N2 &kp N3 &kp N4 &kp N5 &kp N6 &kp N7 &kp N8 &kp N9 &kp N0 &kp MINUS &kp EQUAL &kp BSPC &kp DEL
&kp TAB &kp Q &kp W &kp E &kp R &kp T &kp Y &kp U &kp I &kp O &kp P &kp LBKT &kp RBKT &kp BSLH
&kp CLCK &kp A &kp S &kp D &kp F &kp G &kp H &kp J &kp K &kp L &kp SEMI &kp SQT &kp RET
&kp LSHFT &kp Z &kp X &kp C &kp V &kp B &kp N &kp M &kp COMMA &kp DOT &kp FSLH &kp RSHFT &mo 1
&kp LCTRL &kp LGUI &kp LALT &kp SPACE &kp RALT &kp RGUI &kp C_MENU &kp RCTRL
>;
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
};
raise {
bindings = <
&kp GRAVE &kp F1 &kp F2 &kp F3 &kp F4 &kp F5 &kp F6 &kp F7 &kp F8 &kp F9 &kp F10 &kp F11 &kp F12 &kp DEL &trans
&trans &trans &kp UP &trans &trans &trans &trans &trans &kp INS &trans &kp PSCRN &kp SLCK &kp PAUSE_BREAK &sys_reset
&trans &kp LEFT &kp DOWN &kp RIGHT &trans &trans &trans &trans &trans &trans &kp HOME &kp PG_UP &bootloader
&kp C_PREV &kp C_VOL_DN &kp C_VOL_UP &kp C_MUTE &trans &trans &trans &trans &trans &kp END &kp PG_DN &kp C_NEXT &trans
&bt BT_PRV &bt BT_NXT &trans &trans &trans &trans &trans &bt BT_CLR
>;
sensor-bindings = <&inc_dec_kp C_VOL_UP C_VOL_DN>;
};
#error "Layout not defined, please define a layout by uncommenting the appropriate line in bt60_v2.keymap"
#endif
};
};
8 changes: 6 additions & 2 deletions app/boards/arm/bt60/bt60_v1_hs.dts
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@

/dts-v1/;
#include "bt60.dtsi"

#include <layouts/common/60percent/ansi.dtsi>

/ {
chosen {
zmk,kscan = &kscan0;
zmk,matrix-transform = &default_transform;
zmk,physical-layout = &layout_60_ansi;
};

default_transform: keymap_transform_0 {
Expand Down Expand Up @@ -60,3 +60,7 @@
;
};
};

&layout_60_ansi {
transform = <&default_transform>;
};
10 changes: 5 additions & 5 deletions app/boards/arm/bt60/bt60_v1_hs.keymap
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@

default_layer {
// ------------------------------------------------------------------------------------------
// | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | BSPC | DEL
// | TAB | Q | W | E | R | T | Y | U | I | O | P | [ | ] | | |
// | ESC | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | BSPC |
// | TAB | Q | W | E | R | T | Y | U | I | O | P | [ | ] | | |
// | CAPS | A | S | D | F | G | H | J | K | L | ; | ' | ENTER |
// | SHIFT | Z | X | C | V | B | N | M | , | . | / | SHIFT |
// | CTL | WIN | ALT | SPACE | ALT | 1 | MENU | CTRL |
// | CTL | WIN | ALT | SPACE | ALT | 1 | MENU | CTRL |
// ------------------------------------------------------------------------------------------
bindings = <
&kp ESC &kp N1 &kp N2 &kp N3 &kp N4 &kp N5 &kp N6 &kp N7 &kp N8 &kp N9 &kp N0 &kp MINUS &kp EQUAL &kp BSPC &bt BT_CLR
&kp ESC &kp N1 &kp N2 &kp N3 &kp N4 &kp N5 &kp N6 &kp N7 &kp N8 &kp N9 &kp N0 &kp MINUS &kp EQUAL &kp BSPC
&kp TAB &kp Q &kp W &kp E &kp R &kp T &kp Y &kp U &kp I &kp O &kp P &kp LBKT &kp RBKT &kp BSLH
&kp CLCK &kp A &kp S &kp D &kp F &kp G &kp H &kp J &kp K &kp L &kp SEMI &kp SQT &kp RET
&kp LSHFT &kp Z &kp X &kp C &kp V &kp B &kp N &kp M &kp COMMA &kp DOT &kp FSLH &kp RSHFT
Expand All @@ -25,7 +25,7 @@
};
raise {
bindings = <
&kp GRAVE &kp F1 &kp F2 &kp F3 &kp F4 &kp F5 &kp F6 &kp F7 &kp F8 &kp F9 &kp F10 &kp F11 &kp F12 &kp DEL &trans
&kp GRAVE &kp F1 &kp F2 &kp F3 &kp F4 &kp F5 &kp F6 &kp F7 &kp F8 &kp F9 &kp F10 &kp F11 &kp F12 &kp DEL
&trans &trans &kp UP &trans &trans &trans &trans &trans &kp INS &trans &kp PSCRN &kp SLCK &kp PAUSE_BREAK &sys_reset
&trans &kp LEFT &kp DOWN &kp RIGHT &trans &trans &trans &trans &trans &trans &kp HOME &kp PG_UP &bootloader
&kp C_PREV &kp C_VOL_DN &kp C_VOL_UP &kp C_MUTE &trans &trans &trans &trans &trans &kp END &kp PG_DN &kp C_NEXT
Expand Down
Loading

0 comments on commit 89c8f0a

Please sign in to comment.