forked from kofal.net/zmk
committed by
Pete Johanson
parent
90c2c6672f
commit
feb0d5b90c
@@ -0,0 +1 @@
|
||||
s/.*hid_listener_keycode_//p
|
||||
@@ -0,0 +1,16 @@
|
||||
pressed: usage_page 0x07 keycode 0x1b mods 0x00
|
||||
released: usage_page 0x07 keycode 0x1b mods 0x00
|
||||
pressed: usage_page 0x07 keycode 0x1b mods 0x00
|
||||
released: usage_page 0x07 keycode 0x1b mods 0x00
|
||||
pressed: usage_page 0x07 keycode 0x1b mods 0x00
|
||||
released: usage_page 0x07 keycode 0x1b mods 0x00
|
||||
pressed: usage_page 0x07 keycode 0x1b mods 0x00
|
||||
released: usage_page 0x07 keycode 0x1b mods 0x00
|
||||
pressed: usage_page 0x07 keycode 0x1c mods 0x00
|
||||
released: usage_page 0x07 keycode 0x1c mods 0x00
|
||||
pressed: usage_page 0x07 keycode 0x1c mods 0x00
|
||||
released: usage_page 0x07 keycode 0x1c mods 0x00
|
||||
pressed: usage_page 0x07 keycode 0x1c mods 0x00
|
||||
released: usage_page 0x07 keycode 0x1c mods 0x00
|
||||
pressed: usage_page 0x07 keycode 0x1c mods 0x00
|
||||
released: usage_page 0x07 keycode 0x1c mods 0x00
|
||||
@@ -0,0 +1,84 @@
|
||||
#include <dt-bindings/zmk/keys.h>
|
||||
#include <behaviors.dtsi>
|
||||
#include <dt-bindings/zmk/kscan-mock.h>
|
||||
|
||||
/ {
|
||||
combos {
|
||||
compatible = "zmk,combos";
|
||||
combo_one {
|
||||
timeout-ms = <30>;
|
||||
key-positions = <0 1>;
|
||||
bindings = <&kp X>;
|
||||
};
|
||||
|
||||
combo_two {
|
||||
timeout-ms = <30>;
|
||||
key-positions = <0 2>;
|
||||
bindings = <&kp Y>;
|
||||
};
|
||||
|
||||
combo_three {
|
||||
timeout-ms = <30>;
|
||||
key-positions = <3>;
|
||||
bindings = <&kp Z>;
|
||||
};
|
||||
};
|
||||
|
||||
keymap {
|
||||
compatible = "zmk,keymap";
|
||||
label ="Default keymap";
|
||||
|
||||
default_layer {
|
||||
bindings = <
|
||||
&kp A &kp B
|
||||
&kp C &none
|
||||
>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&kscan {
|
||||
events = <
|
||||
/* all permutations of combo one press and release */
|
||||
ZMK_MOCK_PRESS(0,0,10)
|
||||
ZMK_MOCK_PRESS(0,1,10)
|
||||
ZMK_MOCK_RELEASE(0,0,10)
|
||||
ZMK_MOCK_RELEASE(0,1,10)
|
||||
|
||||
ZMK_MOCK_PRESS(0,1,10)
|
||||
ZMK_MOCK_PRESS(0,0,10)
|
||||
ZMK_MOCK_RELEASE(0,1,10)
|
||||
ZMK_MOCK_RELEASE(0,0,10)
|
||||
|
||||
ZMK_MOCK_PRESS(0,1,10)
|
||||
ZMK_MOCK_PRESS(0,0,10)
|
||||
ZMK_MOCK_RELEASE(0,0,10)
|
||||
ZMK_MOCK_RELEASE(0,1,10)
|
||||
|
||||
ZMK_MOCK_PRESS(0,0,10)
|
||||
ZMK_MOCK_PRESS(0,1,10)
|
||||
ZMK_MOCK_RELEASE(0,1,10)
|
||||
ZMK_MOCK_RELEASE(0,0,10)
|
||||
|
||||
/* all permutations of combo two press and release */
|
||||
ZMK_MOCK_PRESS(0,0,10)
|
||||
ZMK_MOCK_PRESS(0,2,10)
|
||||
ZMK_MOCK_RELEASE(0,0,10)
|
||||
ZMK_MOCK_RELEASE(0,2,10)
|
||||
|
||||
ZMK_MOCK_PRESS(0,2,10)
|
||||
ZMK_MOCK_PRESS(0,0,10)
|
||||
ZMK_MOCK_RELEASE(0,2,10)
|
||||
ZMK_MOCK_RELEASE(0,0,10)
|
||||
|
||||
ZMK_MOCK_PRESS(0,2,10)
|
||||
ZMK_MOCK_PRESS(0,0,10)
|
||||
ZMK_MOCK_RELEASE(0,0,10)
|
||||
ZMK_MOCK_RELEASE(0,2,10)
|
||||
|
||||
ZMK_MOCK_PRESS(0,0,10)
|
||||
ZMK_MOCK_PRESS(0,2,10)
|
||||
ZMK_MOCK_RELEASE(0,2,10)
|
||||
ZMK_MOCK_RELEASE(0,0,10)
|
||||
>;
|
||||
};
|
||||
Reference in New Issue
Block a user