Skip to content

Commit

Permalink
add studio support
Browse files Browse the repository at this point in the history
  • Loading branch information
mike1808 committed Sep 16, 2024
1 parent a6f3bde commit 791f8d1
Show file tree
Hide file tree
Showing 10 changed files with 152 additions and 12 deletions.
2 changes: 1 addition & 1 deletion config/boards/shields/hillside_view/hillside_view.conf
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,4 @@ CONFIG_I2C=y
CONFIG_PINNACLE=y
CONFIG_NFCT_PINS_AS_GPIOS=y
CONFIG_INPUT=y
CONFIG_INPUT_PINNACLE=y

12 changes: 11 additions & 1 deletion config/boards/shields/hillside_view/hillside_view.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,20 @@

#include <dt-bindings/zmk/matrix_transform.h>
#include <dt-bindings/led/led.h>
#include "layouts.dtsi"

&hsv_6col_layout {
transform = <&default_transform>;
};

&hsv_5col_layout {
transform = <&five_column_transform>;
};

/ {
chosen: chosen {
zmk,kscan = &kscan0;
zmk,matrix_transform = &default_transform;
zmk,physical-layout = &hsv_6col_layout;
zmk,underglow = &led_strip;
};

Expand All @@ -30,6 +39,7 @@ RC(2,0) RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5)
RC(3,5) RC(3,6)
RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,7) RC(3,8) RC(3,9) RC(3,10)
>;

};

five_column_transform: keymap_transform_1 {
Expand Down
4 changes: 1 addition & 3 deletions config/boards/shields/hillside_view/hillside_view_left.conf
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,4 @@ CONFIG_GPIO=y

CONFIG_I2C=y
CONFIG_PINCTRL=y
CONFIG_INPUT_PINNACLE=y

CONFIG_ZMK_USB_LOGGING=y
# CONFIG_INPUT_PINNACLE=y
3 changes: 0 additions & 3 deletions config/boards/shields/hillside_view/hillside_view_right.conf
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ CONFIG_GPIO=y

CONFIG_I2C=y
CONFIG_PINCTRL=y
CONFIG_INPUT_PINNACLE=y

# CONFIG_ZMK_USB_LOGGING=y


### Low latency Bluetooth for point devoce ###
Expand Down
131 changes: 131 additions & 0 deletions config/boards/shields/hillside_view/layouts.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,131 @@
#include <physical_layouts.dtsi>

/ {
hsv_6col_layout: hsv_6col_layout {
compatible = "zmk,physical-layout";
display-name = "Six Columns";

keys // w h x y rot rx ry
= <&key_physical_attrs 100 100 0 55 (-1000) 100 15>
, <&key_physical_attrs 100 100 100 55 (-1000) 100 15>
, <&key_physical_attrs 100 100 229 27 (-500) 0 15>
, <&key_physical_attrs 100 100 360 0 0 0 0>
, <&key_physical_attrs 100 100 459 27 0 0 0>
, <&key_physical_attrs 100 100 560 40 0 0 0>
, <&key_physical_attrs 100 100 1100 40 0 0 0>
, <&key_physical_attrs 100 100 1200 27 0 0 0>
, <&key_physical_attrs 100 100 1300 0 0 0 0>
, <&key_physical_attrs 100 100 1430 27 500 0 15>
, <&key_physical_attrs 100 100 1560 55 1000 1560 15>
, <&key_physical_attrs 100 100 1660 55 1000 1760 15>
, <&key_physical_attrs 100 100 0 152 (-1000) 100 15>
, <&key_physical_attrs 100 100 100 152 (-1000) 100 15>
, <&key_physical_attrs 100 100 229 127 (-500) 0 15>
, <&key_physical_attrs 100 100 360 100 0 0 0>
, <&key_physical_attrs 100 100 459 127 0 0 0>
, <&key_physical_attrs 100 100 560 140 0 0 0>
, <&key_physical_attrs 100 100 1100 140 0 0 0>
, <&key_physical_attrs 100 100 1200 127 0 0 0>
, <&key_physical_attrs 100 100 1300 100 0 0 0>
, <&key_physical_attrs 100 100 1430 127 500 0 15>
, <&key_physical_attrs 100 100 1560 152 1000 1560 15>
, <&key_physical_attrs 100 100 1660 152 1000 1760 15>
, <&key_physical_attrs 100 100 0 252 (-1000) 100 15>
, <&key_physical_attrs 100 100 100 252 (-1000) 0 15>
, <&key_physical_attrs 100 100 229 227 (-500) 0 15>
, <&key_physical_attrs 100 100 360 200 0 0 0>
, <&key_physical_attrs 100 100 459 227 0 0 0>
, <&key_physical_attrs 100 100 560 240 0 0 0>
, <&key_physical_attrs 100 100 1100 240 0 0 0>
, <&key_physical_attrs 100 100 1200 227 0 0 0>
, <&key_physical_attrs 100 100 1300 200 0 0 0>
, <&key_physical_attrs 100 100 1430 227 500 0 15>
, <&key_physical_attrs 100 100 1560 252 1000 0 15>
, <&key_physical_attrs 100 100 1660 252 1000 1760 15>
, <&key_physical_attrs 100 100 400 225 3000 440 805>
, <&key_physical_attrs 100 100 1260 225 (-3000) 1300 805>
, <&key_physical_attrs 100 100 400 327 0 0 0>
, <&key_physical_attrs 100 100 400 327 1500 440 805>
, <&key_physical_attrs 100 100 400 327 3000 440 805>
, <&key_physical_attrs 100 100 400 327 4500 440 805>
, <&key_physical_attrs 100 100 1260 327 (-4500) 1300 805>
, <&key_physical_attrs 100 100 1260 327 (-3000) 1300 805>
, <&key_physical_attrs 100 100 1260 327 (-1500) 1300 805>
, <&key_physical_attrs 100 100 1260 327 0 0 0>
;
};

hsv_5col_layout: hsv_5col_layout {
compatible = "zmk,physical-layout";
display-name = "Five Column";

keys // w h x y rot rx ry
= <&key_physical_attrs 100 100 0 55 (-1000) 0 15>
, <&key_physical_attrs 100 100 129 27 (-500) 0 15>
, <&key_physical_attrs 100 100 260 0 0 0 0>
, <&key_physical_attrs 100 100 359 27 0 0 0>
, <&key_physical_attrs 100 100 459 40 0 0 0>
, <&key_physical_attrs 100 100 1000 40 0 0 0>
, <&key_physical_attrs 100 100 1100 27 0 0 0>
, <&key_physical_attrs 100 100 1200 0 0 0 0>
, <&key_physical_attrs 100 100 1330 27 500 0 15>
, <&key_physical_attrs 100 100 1460 55 1000 1460 15>
, <&key_physical_attrs 100 100 0 152 (-1000) 0 15>
, <&key_physical_attrs 100 100 129 127 (-500) 0 15>
, <&key_physical_attrs 100 100 260 100 0 0 0>
, <&key_physical_attrs 100 100 359 127 0 0 0>
, <&key_physical_attrs 100 100 459 140 0 0 0>
, <&key_physical_attrs 100 100 1000 140 0 0 0>
, <&key_physical_attrs 100 100 1100 127 0 0 0>
, <&key_physical_attrs 100 100 1200 100 0 0 0>
, <&key_physical_attrs 100 100 1330 127 500 0 15>
, <&key_physical_attrs 100 100 1460 152 1000 1460 15>
, <&key_physical_attrs 100 100 0 252 (-1000) 0 15>
, <&key_physical_attrs 100 100 129 227 (-500) 0 15>
, <&key_physical_attrs 100 100 260 200 0 0 0>
, <&key_physical_attrs 100 100 359 227 0 0 0>
, <&key_physical_attrs 100 100 459 240 0 0 0>
, <&key_physical_attrs 100 100 1000 240 0 0 0>
, <&key_physical_attrs 100 100 1100 227 0 0 0>
, <&key_physical_attrs 100 100 1200 200 0 0 0>
, <&key_physical_attrs 100 100 1330 227 500 0 15>
, <&key_physical_attrs 100 100 1460 252 1000 0 15>
, <&key_physical_attrs 100 100 300 225 3000 340 805>
, <&key_physical_attrs 100 100 1160 225 (-3000) 1200 805>
, <&key_physical_attrs 100 100 300 327 0 0 0>
, <&key_physical_attrs 100 100 300 327 1500 340 805>
, <&key_physical_attrs 100 100 300 327 3000 340 805>
, <&key_physical_attrs 100 100 300 327 4500 340 805>
, <&key_physical_attrs 100 100 1160 327 (-4500) 1200 805>
, <&key_physical_attrs 100 100 1160 327 (-3000) 1200 805>
, <&key_physical_attrs 100 100 1160 327 (-1500) 1200 805>
, <&key_physical_attrs 100 100 1160 327 0 0 0>
;
};

hsv_position_map {
compatible = "zmk,physical-layout-position-map";

complete;

twelve {
physical-layout = <&hsv_6col_layout>;
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 40 41 42 43 44 45 >;
};

ten {
physical-layout = <&hsv_5col_layout>;
positions
= <40 0 1 2 3 4 5 6 7 8 9 41>
, <42 10 11 12 13 14 15 16 17 18 19 43>
, <44 20 21 22 23 24 25 26 27 28 29 45>
, < 30 31 >
, < 32 33 34 35 36 37 38 39 >;
};
};
};
5 changes: 5 additions & 0 deletions config/hillside_view.conf
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
CONFIG_ZMK_KEYBOARD_NAME="Mikael HSV"

# CONFIG_EC11=y
# CONFIG_EC11_TRIGGER_GLOBAL_THREAD=y

Expand All @@ -19,3 +21,6 @@ CONFIG_ZMK_BLE_EXPERIMENTAL_CONN=y
# report peripheral battery level
CONFIG_ZMK_SPLIT_BLE_CENTRAL_BATTERY_LEVEL_FETCHING=y
CONFIG_ZMK_SPLIT_BLE_CENTRAL_BATTERY_LEVEL_PROXY=y

CONFIG_ZMK_STUDIO=y
CONFIG_ZMK_STUDIO_RPC_THREAD_STACK_SIZE=8120
3 changes: 2 additions & 1 deletion config/hillside_view.keymap
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

#include <dt-bindings/zmk/mouse.h>
#include <behaviors/mouse_keys.dtsi>
#include <behaviors/studio_unlock.dtsi>

// Left bottom row pinky 2nd column

Expand Down Expand Up @@ -275,7 +276,7 @@
display-name = "ADJUST";
bindings = <
&bootloader &rgb_ug RGB_TOG &rgb_ug RGB_HUI &rgb_ug RGB_SAI &rgb_ug RGB_BRI &rgb_ug RGB_SPI &out OUT_TOG &trans &trans &trans &trans &bootloader
&sys_reset &rgb_ug RGB_EFF &rgb_ug RGB_HUD &rgb_ug RGB_SAD &rgb_ug RGB_BRD &rgb_ug RGB_SPD &trans &trans &trans &trans &trans &sys_reset
&sys_reset &rgb_ug RGB_EFF &rgb_ug RGB_HUD &rgb_ug RGB_SAD &rgb_ug RGB_BRD &rgb_ug RGB_SPD &studio_unlock &trans &trans &trans &trans &sys_reset
&bt BT_CLR &bt BT_SEL 0 &bt BT_SEL 1 &bt BT_SEL 2 &bt BT_SEL 3 &bt BT_SEL 4 &kp C_PREV &kp C_PP &kp C_NEXT &kp C_VOL_UP &kp C_MUTE &kp C_VOL_DN
&trans &trans
&ext_power EP_TOG &to WIN &trans &trans &trans &trans &to DEF &trans
Expand Down
1 change: 0 additions & 1 deletion config/hillside_view_left.conf
Original file line number Diff line number Diff line change
@@ -1 +0,0 @@
CONFIG_ZMK_KEYBOARD_NAME="Mikael HSV/L"
1 change: 0 additions & 1 deletion config/hillside_view_right.conf
Original file line number Diff line number Diff line change
@@ -1 +0,0 @@
CONFIG_ZMK_KEYBOARD_NAME="Mikael HSV/R"
2 changes: 1 addition & 1 deletion config/west.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ manifest:
# import: app/west.yml
- name: zmk
remote: badjeff
revision: feat/pointers-move-scroll
revision: feat/pointers-move-scroll-studio
import: app/west.yml
- name: zmk-adns9800-driver
remote: badjeff
Expand Down

0 comments on commit 791f8d1

Please sign in to comment.