Browse Source

Fix keymap.

xmkb
CrossR 4 years ago
parent
commit
aa187a54d4
  1. 12
      app/boards/shields/sofle/sofle.dtsi
  2. 40
      app/boards/shields/sofle/sofle.keymap

12
app/boards/shields/sofle/sofle.dtsi

@ -19,14 +19,14 @@ @@ -19,14 +19,14 @@
// | SW6 | SW5 | SW4 | SW3 | SW2 | SW1 | | SW1 | SW2 | SW3 | SW4 | SW5 | SW6 |
// | SW12 | SW11 | SW10 | SW9 | SW8 | SW7 | | SW7 | SW8 | SW9 | SW10 | SW11 | SW12 |
// | SW18 | SW17 | SW16 | SW15 | SW14 | SW13 | | SW13 | SW14 | SW15 | SW16 | SW17 | SW18 |
// | SW24 | SW23 | SW22 | SW21 | SW20 | SW19 | | SW19 | SW20 | SW21 | SW22 | SW23 | SW24 |
// | SW29 | SW28 | SW27 | SW26 | SW25 | | SW25 | SW26 | SW27 | SW28 | SW29 |
// | SW24 | SW23 | SW22 | SW21 | SW20 | SW19 | SW25 | | SW25 | SW19 | SW20 | SW21 | SW22 | SW23 | SW24 |
// | SW30 | SW29 | SW28 | SW27 | SW26 | | SW26 | SW27 | SW28 | SW29 | SW30 |
map = <
RC(0,0) RC(0,1) RC(0,2) RC(0,3) RC(0,4) RC(0,5) RC(0,6) RC(0,7) RC(0,8) RC(0,9) RC(0,10) RC(0,11)
RC(1,0) RC(1,1) RC(1,2) RC(1,3) RC(1,4) RC(1,5) RC(1,6) RC(1,7) RC(1,8) RC(1,9) RC(1,10) RC(1,11)
RC(2,0) RC(2,1) RC(2,2) RC(2,3) RC(2,4) RC(2,5) RC(2,6) RC(2,7) RC(2,8) RC(2,9) RC(2,10) RC(2,11)
RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7) RC(3,8) RC(3,9) RC(3,10) RC(3,11)
RC(4,1) RC(4,2) RC(4,3) RC(4,4) RC(4,5) RC(4,9) RC(4,10) RC(4,11) RC(4,12) RC(4,13)
RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(4,5) RC(4,6) RC(3,6) RC(3,7) RC(3,8) RC(3,9) RC(3,10) RC(3,11)
RC(4,0) RC(4,1) RC(4,2) RC(4,3) RC(4,4) RC(4,7) RC(4,8) RC(4,9) RC(4,10) RC(4,11)
>;
};
@ -49,7 +49,7 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7) @@ -49,7 +49,7 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7)
left_encoder: encoder_left {
compatible = "alps,ec11";
label = "LEFT_ENCODER";
a-gpios = <&pro_micro_a 1 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
a-gpios = <&pro_micro_a 2 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
b-gpios = <&pro_micro_a 3 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
resolution = <2>;
status = "disabled";
@ -59,7 +59,7 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7) @@ -59,7 +59,7 @@ RC(3,0) RC(3,1) RC(3,2) RC(3,3) RC(3,4) RC(3,5) RC(3,6) RC(3,7)
compatible = "alps,ec11";
label = "RIGHT_ENCODER";
a-gpios = <&pro_micro_a 3 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
b-gpios = <&pro_micro_a 1 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
b-gpios = <&pro_micro_a 2 (GPIO_ACTIVE_HIGH | GPIO_PULL_UP)>;
resolution = <2>;
status = "disabled";
};

40
app/boards/shields/sofle/sofle.keymap

@ -1,24 +1,22 @@ @@ -1,24 +1,22 @@
#include <behaviors.dtsi>
#include <dt-bindings/zmk/keys.h>
//TODO: Is the encoder stuff needed on every single layer?
/ {
keymap {
compatible = "zmk,keymap";
default_layer {
// ------------------------------------------------------------------------------------------------------------
// | ` | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | ` |
// | ESC | Q | W | E | R | T | | Y | U | I | O | P | Bkspc |
// | CTRL | A | S | D | F | G | | H | J | K | L | ; | ' |
// | SHIFT | Z | X | C | V | B | | N | M | , | . | / | SHIFT |
// | ` | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | |
// | ESC | Q | W | E | R | T | | Y | U | I | O | P | BKSPC |
// | TAB | A | S | D | F | G | | H | J | K | L | ; | ' |
// | SHIFT | Z | X | C | V | B | MUTE | | | N | M | , | . | / | SHIFT |
// | GUI | ALT | CTRL | LOWER| ENTER | | SPACE | RAISE| CTRL | ALT | GUI |
bindings = <
&kp GRAV &kp NUM_1 &kp NUM_2 &kp NUM_3 &kp NUM_4 &kp NUM_5 &kp NUM_6 &kp NUM_7 &kp NUM_8 &kp NUM_9 &kp NUM_0 &kp GRAV
&kp GRAV &kp NUM_1 &kp NUM_2 &kp NUM_3 &kp NUM_4 &kp NUM_5 &kp NUM_6 &kp NUM_7 &kp NUM_8 &kp NUM_9 &kp NUM_0 &none
&kp ESC &kp Q &kp W &kp E &kp R &kp T &kp Y &kp U &kp I &kp O &kp P &kp BKSP
&kp LCTL &kp A &kp S &kp D &kp F &kp G &kp H &kp J &kp K &kp L &kp SCLN &kp QUOT
&kp LSFT &kp Z &kp X &kp C &kp V &kp B &kp N &kp M &kp CMMA &kp DOT &kp FSLH &kp RSFT
&kp TAB &kp A &kp S &kp D &kp F &kp G &kp H &kp J &kp K &kp L &kp SCLN &kp QUOT
&kp LSFT &kp Z &kp X &kp C &kp V &kp B &kp M_MUTE &none &kp N &kp M &kp CMMA &kp DOT &kp FSLH &kp RSFT
&kp LGUI &kp LALT &kp LCTL &mo 1 &kp RET &kp SPC &mo 2 &kp RCTL &kp RALT &kp RGUI
>;
@ -28,15 +26,15 @@ @@ -28,15 +26,15 @@
lower_layer {
// ------------------------------------------------------------------------------------------------------------
// | | F1 | F2 | F3 | F4 | F5 | | F6 | F7 | F8 | F9 | F10 | F11 |
// | | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | F12 |
// | TAB | ! | @ | # | $ | % | | ^ | & | * | ( | ) | | |
// | | = | - | + | { | } | | [ | ] | ; | : | \ | |
// | ` | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | F12 |
// | | ! | @ | # | $ | % | | ^ | & | * | ( | ) | | |
// | | = | - | + | { | } | | | | [ | ] | ; | : | \ | |
// | | | | | | | | | | | |
bindings = <
&trans &kp F1 &kp F2 &kp F3 &kp F4 &kp F5 &kp F6 &kp F7 &kp F8 &kp F9 &kp F10 &kp F11
&trans &kp 1 &kp 2 &kp 3 &kp 4 &kp 5 &kp 6 &kp 7 &kp 8 &kp 9 &kp 0 &kp F12
&kp TAB &kp BANG &kp ATSN &kp HASH &kp CURU &kp PRCT &kp CRRT &kp AMPS &kp KMLT &kp LPRN &kp RPRN &kp PIPE
&trans &kp EQL &kp MINUS &kp KPLS &kp LCUR &kp RCUR &kp LBKT &kp RKBT &kp SCLN &kp COLN &kp BSLH &trans
&kp GRAV &kp 1 &kp 2 &kp 3 &kp 4 &kp 5 &kp 6 &kp 7 &kp 8 &kp 9 &kp 0 &kp F12
&trans &kp BANG &kp ATSN &kp HASH &kp CURU &kp PRCT &kp CRRT &kp AMPS &kp KMLT &kp LPRN &kp RPRN &kp PIPE
&trans &kp EQL &kp MINUS &kp KPLS &kp LCUR &kp RCUR &trans &trans &kp LBKT &kp RKBT &kp SCLN &kp COLN &kp BSLH &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
>;
@ -46,15 +44,15 @@ @@ -46,15 +44,15 @@
raise_layer {
// ------------------------------------------------------------------------------------------------------------
// | | | | | | | | | | | | | |
// | ` | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | |
// | F1 | F2 | F3 | F4 | F5 | F6 | | | <- | ^ | v | -> | |
// | F7 | F8 | F9 | F10 | F11 | F12 | | + | - | = | [ | ] | \ |
// | | INS | PSCR | GUI | | | | PGUP | | ^ | | | |
// | | ALT | CTRL | SHIFT | | CAPS | | PGDN | <- | v | -> | DEL | BKSPC |
// | | UNDO | CUT | COPY | PASTE | | | | | | | | | | |
// | | | | | | | | | | | |
bindings = <
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&kp GRAV &kp NUM_1 &kp NUM_2 &kp NUM_3 &kp NUM_4 &kp NUM_5 &kp NUM_6 &kp NUM_7 &kp NUM_8 &kp NUM_9 &kp NUM_0 &trans
&kp F1 &kp F2 &kp F3 &kp F4 &kp F5 &kp F6 &trans &kp LARW &kp UARW &kp DARW & RARW &trans
&kp F7 &kp F8 &kp F9 &kp F10 &kp F11 &kp F12 &kp KPLS &kp MINUS &kp EQL &kp LBKT &kp RBKT &kp BSLH
&trans &kp INS &kp PRSC &kp GUI &trans &trans &kp PGUP &trans &kp UARW &trans &kp NUM_0 &trans
&trans &kp LALT &kp LCTL &kp LSFT &trans &kp CLCK &kp PGDN &kp LARW &kp DARW &kp RARW &kp DEL &kp BKSP
&trans &kp 0x7A &kp 0x7B &kp 0x7C &kp 0x7D &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
>;
};

Loading…
Cancel
Save