From 16eb8bdf1f712209ac5267d8ef541c9a6ef6d42c Mon Sep 17 00:00:00 2001 From: Tim Nguyen Date: Tue, 12 Mar 2024 23:14:49 -0400 Subject: [PATCH] macos keybind change #1 --- boards/arm/zaphod/zaphod.dts | 4 ---- boards/arm/zaphod/zaphod.keymap | 37 ++++++++++++++++++++++++--------- 2 files changed, 27 insertions(+), 14 deletions(-) diff --git a/boards/arm/zaphod/zaphod.dts b/boards/arm/zaphod/zaphod.dts index f074b8ab..ae1bfa68 100644 --- a/boards/arm/zaphod/zaphod.dts +++ b/boards/arm/zaphod/zaphod.dts @@ -76,13 +76,9 @@ kscan: kscan { compatible = "zmk,kscan-gpio-matrix"; label = "KSCAN"; -<<<<<<< HEAD debounce-press-ms = <1>; debounce-release-ms = <5>; -======= - debounce-period = <15>; ->>>>>>> 5bcb5cb (nhongooi keymap test) diode-direction = "col2row"; col-gpios diff --git a/boards/arm/zaphod/zaphod.keymap b/boards/arm/zaphod/zaphod.keymap index 2f020cad..706ba7b5 100644 --- a/boards/arm/zaphod/zaphod.keymap +++ b/boards/arm/zaphod/zaphod.keymap @@ -9,12 +9,6 @@ #include #include -#define NAV_L 1 -#define OTH_L 2 -#define NUM_L 3 -#define SYM_L 4 -#define MED_L 5 -#define FUN_L 6 // Using layer taps on thumbs, having quick tap as well helps w/ repeating space/backspace < { quick_tap_ms = <160>; }; @@ -47,7 +41,30 @@ flavor = "tap-preferred"; bindings = <&kp>, <&kp>; }; + gresc: grave_escape { + compatible = "zmk,behavior-mod-morph"; + label = "GRAVE_ESCAPE"; + #binding-cells = <0>; + bindings = <&kp ESC>, <&kp GRAVE>; + mods = <(MOD_LGUI|MOD_LSFT|MOD_RGUI|MOD_RSFT)>; + }; + dbspc: del_backspace { + compatible = "zmk,behavior-mod-morph"; + label = "DEL_BACKSPACE"; + #binding-cells = <0>; + bindings = <&kp BSPC>, <&kp DEL>; + mods = <(MOD_LSFT|MOD_RSFT)>; + }; + }; + + conditional_layers { + compatible = "zmk,conditional-layers"; + tri_layer { + if-layers = <2 3>; + then-layer = <4>; + }; }; + keymap { compatible = "zmk,keymap"; default_layer { @@ -55,7 +72,7 @@ &kp Q &kp W &kp E &kp R &kp T &kp Y &kp U &kp I &kp O &kp P &hm LGUI A &hm LSHFT S &hm LCTRL D &hm LALT F &kp G &kp H &hm RALT J &hm RCTRL K &hm RSHFT L &hm RGUI SEMI &kp Z &kp X &kp C &kp V &kp B &kp N &kp M &kp COMMA &kp DOT &kp FSLH - < 3 TAB < 1 SPC < 2 RET &kp BSPC + < 3 TAB < 1 SPC < 2 RET &dbspc >; }; lower_layer { @@ -71,13 +88,13 @@ &kp ESC &kp F1 &kp F2 &kp F3 &kp F4 &kp PG_UP &kp HOME &trans &kp ESC &kp GRAVE &trans &kp F5 &kp F6 &kp F7 &kp F8 &kp LEFT &kp DOWN &kp UP &kp RIGHT &kp COLON &trans &kp F9 &kp F10 &kp F11 &kp F12 &kp PG_DN &kp END &kp DEL &trans &kp QMARK - &mo 4 &trans &trans &trans + &trans &trans &trans &trans >; }; con_layer { bindings = < - &kp LC(LS(T)) &kp LC(LS(TAB)) &kp LC(W) &kp LC(TAB) &kp LC(LA(R)) &kp LBRC &kp AMPS &kp ASTRK &kp LPAR &kp RBRC - &kp LC(Z) &kp LC(X) &kp LC(C) &kp LC(V) &kp LC(Y) &kp DQT &kp DLLR &kp PRCNT &kp CARET &kp PLUS + &kp LC(LS(T)) &kp LG(LS(TAB)) &kp LG(W) &kp LC(TAB) &kp LG(LA(R)) &kp LBRC &kp AMPS &kp ASTRK &kp LPAR &kp RBRC + &kp LG(Z) &kp LG(X) &kp LG(C) &kp LG(V) &kp LG(Y) &kp DQT &kp DLLR &kp PRCNT &kp CARET &kp PLUS &trans &kp LA(B) &kp LA(D) &kp LA(F) &kp LC(N1) &kp UNDER &kp EXCL &kp AT &kp HASH &kp PIPE &trans &trans &trans &kp RPAR >;