Skip to content

Commit

Permalink
Add ut22
Browse files Browse the repository at this point in the history
  • Loading branch information
jcmkk3 authored Mar 5, 2024
1 parent ead4cad commit 32538ae
Show file tree
Hide file tree
Showing 6 changed files with 423 additions and 0 deletions.
8 changes: 8 additions & 0 deletions config/boards/shields/ut22/Kconfig.defconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# SPDX-License-Identifier: MIT

if SHIELD_UT22

config ZMK_KEYBOARD_NAME
default "ut22"

endif
2 changes: 2 additions & 0 deletions config/boards/shields/ut22/Kconfig.shield
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
config SHIELD_UT22
def_bool $(shields_list_contains,ut22)
5 changes: 5 additions & 0 deletions config/boards/shields/ut22/ut22.keymap
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/*
* SPDX-License-Identifier: MIT
*/

#include "../../../ut22.keymap"
42 changes: 42 additions & 0 deletions config/boards/shields/ut22/ut22.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
#include <dt-bindings/zmk/matrix_transform.h>

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

default_kscan: kscan {
compatible = "zmk,kscan-gpio-matrix";
label = "default_kscan";
diode-direction = "col2row";
col-gpios
= <&pro_micro 15 GPIO_ACTIVE_HIGH> // COL0
, <&pro_micro 14 GPIO_ACTIVE_HIGH> // COL1
, <&pro_micro 16 GPIO_ACTIVE_HIGH> // COL2
, <&pro_micro 10 GPIO_ACTIVE_HIGH> // COL3
;
row-gpios
= <&pro_micro 4 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> // ROW0
, <&pro_micro 5 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> // ROW1
, <&pro_micro 6 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> // ROW2
, <&pro_micro 7 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> // ROW3
, <&pro_micro 8 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> // ROW4
, <&pro_micro 9 (GPIO_ACTIVE_HIGH | GPIO_PULL_DOWN)> // ROW5
;

};

default_transform: matrix_transform {
compatible = "zmk,matrix-transform";
columns = <4>;
rows = <6>;

map = <
RC(0,0) RC(0,1) RC(0,2) RC(0,3) RC(3,3) RC(3,2) RC(3,1) RC(3,0)
RC(1,0) RC(1,1) RC(1,2) RC(1,3) RC(4,3) RC(4,2) RC(4,1) RC(4,0)
RC(2,0) RC(2,2) RC(2,3) RC(5,3) RC(5,2) RC(5,0)

>;
};
};
12 changes: 12 additions & 0 deletions config/ut22.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# --- TAIPO SETTINGS ---

# the number of combos that can be active at the same time. Default 4.
CONFIG_ZMK_COMBO_MAX_PRESSED_COMBOS=8

# the maximum number of combos that can be active on a key position. Defaults to 5.
# (So you can have 5 separate combos that use position 3 for example)
CONFIG_ZMK_COMBO_MAX_COMBOS_PER_KEY=16

# the maximum number of keys that need to be pressed to activate a combo. Default 4.
# If you want a combo that triggers when pressing 5 keys, you'd set this to 5 for example.
CONFIG_ZMK_COMBO_MAX_KEYS_PER_COMBO=8
Loading

0 comments on commit 32538ae

Please sign in to comment.