From d10542f736b293c8a67ae2a1eb41e7ab567de99e Mon Sep 17 00:00:00 2001 From: ldebritto Date: Wed, 15 Jan 2025 10:50:10 -0300 Subject: [PATCH] Mouse layer is back? --- config/cradio.conf | 6 +++++- config/cradio.keymap | 20 ++++++++++++++++++++ config/mouse.dtsi | 6 ++++++ 3 files changed, 31 insertions(+), 1 deletion(-) diff --git a/config/cradio.conf b/config/cradio.conf index b696700..388d7d0 100644 --- a/config/cradio.conf +++ b/config/cradio.conf @@ -9,4 +9,8 @@ CONFIG_ZMK_SLEEP=y CONFIG_BT_CTLR_TX_PWR_PLUS_8=y # BLE connection improvements -CONFIG_ZMK_BLE_EXPERIMENTAL_CONN=y \ No newline at end of file +CONFIG_ZMK_BLE_EXPERIMENTAL_CONN=y + +# Mouse config, requires PR #778 +CONFIG_ZMK_MOUSE=y +CONFIG_ZMK_MOUSE_TICK_DURATION=8 \ No newline at end of file diff --git a/config/cradio.keymap b/config/cradio.keymap index 64be0ae..e3bceef 100644 --- a/config/cradio.keymap +++ b/config/cradio.keymap @@ -2,6 +2,7 @@ #include #include #include // requires auto-layer module (https://github.com/urob/zmk-auto-layer) +#include "mouse.dtsi" #define DEF 0 #define NUM 1 @@ -11,6 +12,7 @@ #define AOE 5 // AOE 2 layers with easier access for default shortcuts on main layer #define AGS 6 #define ABS 7 +#define MOU 9 #define HYPER LG(LS(LC(LALT))) // HYPER key for another shortcut layer @@ -76,6 +78,13 @@ layers = ; }; + toggle_mouse_emulation_layer { + bindings = <&tog MOU>; + key-positions = <6 7 8>; + require-prior-idle-ms = <200>; + layers = ; + }; + toggle_caps_word { key-positions = <12 17>; bindings = <&caps_word>; @@ -276,6 +285,8 @@ >; }; + + AOE { bindings = < &kp Q &kp W &kp E &kp R &kp T &trans &trans &trans &trans &trans @@ -303,5 +314,14 @@ >; }; + MOU { + bindings = < +&kp TAB &swapper &kp LS(LC(TAB)) &kp LC(TAB) &kp LG(RBKT) &msc SCRL_UP &msc SCRL_LEFT &mmv MOVE_UP &msc SCRL_RIGHT &kp BSPC +&kp LCTRL &kp LALT &kp LSHFT &kp LGUI &kp LG(LBKT) &msc SCRL_DOWN &mmv MOVE_LEFT &mmv MOVE_DOWN &mmv MOVE_RIGHT &kp ENTER +&hrml GLOBE LG(Z) &kp LG(X) &kp LG(C) &kp LG(V) &kp F18 &kp LC(UP) &mkp MB4 &mkp MCLK &mkp MB4 &kp DEL + &tog MOU &kp RSHFT &mkp LCLK &mkp RCLK + >; + }; + }; }; \ No newline at end of file diff --git a/config/mouse.dtsi b/config/mouse.dtsi index 3925b9c..028152a 100644 --- a/config/mouse.dtsi +++ b/config/mouse.dtsi @@ -18,6 +18,12 @@ delay-ms = <0>; // 0 }; +// Add these lines to cradio.conf +// # Mouse config, requires PR #778 +// CONFIG_ZMK_MOUSE=y +// CONFIG_ZMK_MOUSE_TICK_DURATION=8 + + // Add the bellow lines do cradio.keymap // Include and layer definition