Skip to content

Commit

Permalink
slicemk: boards: add ansi104 converter shield (to squash 2024-01-15)
Browse files Browse the repository at this point in the history
  • Loading branch information
xudongzheng committed Jan 15, 2024
1 parent aa2952d commit b77ac77
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
3 changes: 3 additions & 0 deletions app/boards/shields/slicemk_usbconv/Kconfig.shield
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
config SHIELD_SLICEMK_USBCONV_ANSI104
def_bool $(shields_list_contains,slicemk_usbconv_ansi104)

config SHIELD_SLICEMK_USBCONV_ERGODOX
def_bool $(shields_list_contains,slicemk_usbconv_ergodox)
30 changes: 30 additions & 0 deletions app/boards/shields/slicemk_usbconv/slicemk_usbconv_ansi104.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
#include <dt-bindings/zmk/converter_keys.h>
#include <dt-bindings/zmk/matrix_transform.h>

/ {
chosen {
zmk,kscan = &kscan0;
zmk,matrix_transform = &default_transform;
};

// Specify placeholder button for consistency with ErgoDox Wireless.
kscan0: kscan {
compatible = "zmk,kscan-gpio-direct";
input-gpios = <&gpio0 28 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
};

default_transform: keymap_transform_0 {
compatible = "zmk,matrix-transform";
columns = <1>;
rows = <256>;
map = <
RC(0,0)
CV(ESCAPE) CV(F1) CV(F2) CV(F3) CV(F4) CV(F5) CV(F6) CV(F7) CV(F8) CV(F9) CV(F10) CV(F11) CV(F12) CV(PRINTSCREEN) CV(SCROLLLOCK) CV(PAUSE_BREAK)
CV(GRAVE) CV(NUMBER_1) CV(NUMBER_2) CV(NUMBER_3) CV(NUMBER_4) CV(NUMBER_5) CV(NUMBER_6) CV(NUMBER_7) CV(NUMBER_8) CV(NUMBER_9) CV(NUMBER_0) CV(MINUS) CV(EQUAL) CV(BACKSPACE) CV(INSERT) CV(HOME) CV(PAGE_UP) CV(KP_NUMLOCK) CV(KP_DIVIDE) CV(KP_MULTIPLY) CV(KP_MINUS)
CV(TAB) CV(Q) CV(W) CV(E) CV(R) CV(T) CV(Y) CV(U) CV(I) CV(O) CV(P) CV(LEFT_BRACKET) CV(RIGHT_BRACKET) CV(BACKSLASH) CV(DELETE) CV(END) CV(PAGE_DOWN) CV(KP_NUMBER_7) CV(KP_NUMBER_8) CV(KP_NUMBER_9) CV(KP_PLUS)
CV(CAPSLOCK) CV(A) CV(S) CV(D) CV(F) CV(G) CV(H) CV(J) CV(K) CV(L) CV(SEMICOLON) CV(SINGLE_QUOTE) CV(RETURN) CV(KP_NUMBER_4) CV(KP_NUMBER_5) CV(KP_NUMBER_6)
CV(LEFT_SHIFT) CV(Z) CV(X) CV(C) CV(V) CV(B) CV(N) CV(M) CV(COMMA) CV(PERIOD) CV(SLASH) CV(RIGHT_SHIFT) CV(UP_ARROW) CV(KP_NUMBER_1) CV(KP_NUMBER_2) CV(KP_NUMBER_3) CV(KP_ENTER)
CV(LEFT_CONTROL) CV(LEFT_GUI) CV(LEFT_ALT) CV(SPACE) CV(RIGHT_ALT) CV(RIGHT_GUI) CV(K_APPLICATION) CV(RIGHT_CONTROL) CV(LEFT_ARROW) CV(DOWN_ARROW) CV(RIGHT_ARROW) CV(KP_NUMBER_0) CV(KP_DOT)
>;
};
};

0 comments on commit b77ac77

Please sign in to comment.