generated from moergo-sc/glove80-zmk-config
-
Notifications
You must be signed in to change notification settings - Fork 6
/
glove80.keymap
413 lines (385 loc) · 18.2 KB
/
glove80.keymap
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
/*
* Copyright (c) 2020 The ZMK Contributors
* Copyright (c) 2023 Innaworks Development Limited, trading as MoErgo
*
* SPDX-License-Identifier: MIT
*/
/* THIS FILE WAS GENERATED BY GLOVE80 LAYOUT EDITOR
*
* This file was generated automatically. You may or may not want to
* edit it directly.
*/
#include <behaviors.dtsi>
/* Include all behavior includes needed */
#include <dt-bindings/zmk/outputs.h>
#include <dt-bindings/zmk/keys.h>
#include <dt-bindings/zmk/bt.h>
#include <dt-bindings/zmk/rgb.h>
/* Automatically generated layer name #define */
#define LAYER_Base 0
#define LAYER_Azerty 1
#define LAYER_Gaming 2
#define LAYER_Lower 3
#define LAYER_Raise 4
#define LAYER_Magic 5
/* To deal with the situation where there is no Lower layer, to keep &lower happy */
#ifndef LAYER_Lower
#define LAYER_Lower 0
#endif
/* Custom Device-tree */
/* Empty underglow layer definition (for copy-paste)
mylayer {
bindings = <
______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______
>;
layer-id = <LAYER_Name>;
};
*/
#include <dt-bindings/zmk/rgb_colors.h>
/ {
underglow-layer {
compatible = "zmk,underglow-layer";
lower {
bindings = <
______ ______ ______ ______ ______ ______ ______ ______ ______ ______
PURPLE PINK PINK PINK PINK PINK ______ GOLD ORANGE ORANGE ORANGE RED
PURPLE ______ ______ ORANGE ______ ______ ______ YELLOW YELLOW YELLOW ORANGE ______
PURPLE ______ ORANGE RED ORANGE ______ ______ YELLOW YELLOW YELLOW ORANGE ______
BLUE ______ RED RED RED ______ ______ ______ ______ ______ ______ ______ ______ YELLOW YELLOW YELLOW RED BLUE
______ ______ ORANGE ORANGE ORANGE ______ GREEN ______ ______ ______ ______ YELLOW YELLOW ORANGE RED ______
>;
layer-id = <LAYER_Lower>;
};
raise {
bindings = <
______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ ______ ______ ______ ______ ______ PINK PINK PINK PINK PINK ______
______ BLUE ______ BLUE BLUE BLUE ______ ______ ______ ______ ______ BLUE
______ BLUE ______ ______ ______ BLUE ______ ______ ______ ______ ______ ______
BLUE ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ BLUE
______ ______ ______ ______ ______ ______ ______ ______ ______ GREEN ______ ______ ______ ______ ______ ______
>;
layer-id = <LAYER_Raise>;
};
gaming {
bindings = <
______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ TEAL ______ RED ______ ______ ______ ______ ______ ______ ______ ______
______ BLUE RED RED RED ______ ORANGE BLUE ______ ______ ______ ______ ______ ______ ______ ______ ______ ______
______ BLUE ______ ______ ______ RED ______ ______ ______ GREEN ______ ______ ______ ______ ______ ______
>;
layer-id = <LAYER_Gaming>;
};
};
};
/* Glove80 system behavior & macros */
/ {
behaviors {
// For the "layer" key, it'd nice to be able to use it as either a shift or a toggle.
// Configure it as a tap dance, so the first tap (or hold) is a &mo and the second tap is a &to
lower: lower {
compatible = "zmk,behavior-tap-dance";
label = "LAYER_TAP_DANCE";
#binding-cells = <0>;
tapping-term-ms = <200>;
bindings = <&mo LAYER_Lower>, <&to LAYER_Lower>;
};
};
};
/ {
macros {
rgb_ug_status_macro: rgb_ug_status_macro {
label = "RGB_UG_STATUS";
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings
= <&rgb_ug RGB_STATUS>;
};
};
};
/ {
#ifdef BT_DISC_CMD
behaviors {
bt_0: bt_0 {
compatible = "zmk,behavior-tap-dance";
label = "BT_0";
#binding-cells = <0>;
tapping-term-ms = <200>;
bindings = <&bt_select_0>, <&bt BT_DISC 0>;
};
bt_1: bt_1 {
compatible = "zmk,behavior-tap-dance";
label = "BT_1";
#binding-cells = <0>;
tapping-term-ms = <200>;
bindings = <&bt_select_1>, <&bt BT_DISC 1>;
};
bt_2: bt_2 {
compatible = "zmk,behavior-tap-dance";
label = "BT_2";
#binding-cells = <0>;
tapping-term-ms = <200>;
bindings = <&bt_select_2>, <&bt BT_DISC 2>;
};
bt_3: bt_3 {
compatible = "zmk,behavior-tap-dance";
label = "BT_3";
#binding-cells = <0>;
tapping-term-ms = <200>;
bindings = <&bt_select_3>, <&bt BT_DISC 3>;
};
};
macros {
bt_select_0: bt_select_0 {
label = "BT_SELECT_0";
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings
= <&out OUT_BLE>,
<&bt BT_SEL 0>;
};
bt_select_1: bt_select_1 {
label = "BT_SELECT_1";
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings
= <&out OUT_BLE>,
<&bt BT_SEL 1>;
};
bt_select_2: bt_select_2 {
label = "BT_SELECT_2";
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings
= <&out OUT_BLE>,
<&bt BT_SEL 2>;
};
bt_select_3: bt_select_3 {
label = "BT_SELECT_3";
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings
= <&out OUT_BLE>,
<&bt BT_SEL 3>;
};
};
#else
macros {
bt_0: bt_0 {
label = "BT_0";
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings
= <&out OUT_BLE>,
<&bt BT_SEL 0>;
};
bt_1: bt_1 {
label = "BT_1";
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings
= <&out OUT_BLE>,
<&bt BT_SEL 1>;
};
bt_2: bt_2 {
label = "BT_2";
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings
= <&out OUT_BLE>,
<&bt BT_SEL 2>;
};
bt_3: bt_3 {
label = "BT_3";
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings
= <&out OUT_BLE>,
<&bt BT_SEL 3>;
};
};
#endif
};
/ {
behaviors {
magic: magic {
compatible = "zmk,behavior-hold-tap";
label = "MAGIC_HOLD_TAP";
#binding-cells = <2>;
flavor = "tap-preferred";
tapping-term-ms = <200>;
bindings = <&mo>, <&rgb_ug_status_macro>;
};
};
};
/* #define for key positions */
#define POS_LH_T1 52
#define POS_LH_T2 53
#define POS_LH_T3 54
#define POS_LH_T4 69
#define POS_LH_T5 70
#define POS_LH_T6 71
#define POS_LH_C1R2 15
#define POS_LH_C1R3 27
#define POS_LH_C1R4 39
#define POS_LH_C1R5 51
#define POS_LH_C2R1 4
#define POS_LH_C2R2 14
#define POS_LH_C2R3 26
#define POS_LH_C2R4 38
#define POS_LH_C2R5 50
#define POS_LH_C2R6 68
#define POS_LH_C3R1 3
#define POS_LH_C3R2 13
#define POS_LH_C3R3 25
#define POS_LH_C3R4 37
#define POS_LH_C3R5 49
#define POS_LH_C3R6 67
#define POS_LH_C4R1 2
#define POS_LH_C4R2 12
#define POS_LH_C4R3 24
#define POS_LH_C4R4 36
#define POS_LH_C4R5 48
#define POS_LH_C4R6 66
#define POS_LH_C5R1 1
#define POS_LH_C5R2 11
#define POS_LH_C5R3 23
#define POS_LH_C5R4 35
#define POS_LH_C5R5 47
#define POS_LH_C5R6 65
#define POS_LH_C6R1 0
#define POS_LH_C6R2 10
#define POS_LH_C6R3 22
#define POS_LH_C6R4 34
#define POS_LH_C6R5 46
#define POS_LH_C6R6 64
#define POS_RH_T1 57
#define POS_RH_T2 56
#define POS_RH_T3 55
#define POS_RH_T4 74
#define POS_RH_T5 73
#define POS_RH_T6 72
#define POS_RH_C1R2 16
#define POS_RH_C1R3 28
#define POS_RH_C1R4 40
#define POS_RH_C1R5 58
#define POS_RH_C2R1 5
#define POS_RH_C2R2 17
#define POS_RH_C2R3 29
#define POS_RH_C2R4 41
#define POS_RH_C2R5 59
#define POS_RH_C2R6 75
#define POS_RH_C3R1 6
#define POS_RH_C3R2 18
#define POS_RH_C3R3 30
#define POS_RH_C3R4 42
#define POS_RH_C3R5 60
#define POS_RH_C3R6 76
#define POS_RH_C4R1 7
#define POS_RH_C4R2 19
#define POS_RH_C4R3 31
#define POS_RH_C4R4 43
#define POS_RH_C4R5 61
#define POS_RH_C4R6 77
#define POS_RH_C5R1 8
#define POS_RH_C5R2 20
#define POS_RH_C5R3 32
#define POS_RH_C5R4 44
#define POS_RH_C5R5 62
#define POS_RH_C5R6 78
#define POS_RH_C6R1 9
#define POS_RH_C6R2 21
#define POS_RH_C6R3 33
#define POS_RH_C6R4 45
#define POS_RH_C6R5 63
#define POS_RH_C6R6 79
/* Custom Defined Behaviors */
/ {
behaviors {
raise: tt_raise {
compatible = "zmk,behavior-tap-dance";
tapping-term-ms = <200>;
#binding-cells = <0>;
bindings = <&mo LAYER_Raise>
, <&to LAYER_Raise>;
};
};
};
/* Automatically generated macro definitions */
/ {
macros {
};
};
/* Automatically generated keymap */
/ {
keymap {
compatible = "zmk,keymap";
layer_Base {
bindings = <
&kp LGUI &none &none &none &none &none &none &none &none &none
&kp ESC &kp N1 &kp N2 &kp N3 &kp N4 &kp N5 &kp N6 &kp N7 &kp N8 &kp N9 &kp N0 &kp BSPC
&kp TAB &kp A &kp Z &kp F &kp P &kp G &kp H &kp J &kp K &kp L &kp DOT &kp RA(N8)
&kp EQUAL &kp Q &kp R &kp S &kp T &kp D &kp U &kp N &kp E &kp I &kp O &kp KP_SLASH
&kp RA(N5) &kp W &kp X &kp C &kp V &kp B &mt LSHFT N5 &kp LCTRL &kp LS(LC(LALT)) &kp RALT &kp RCTRL &mt RSHFT MINUS &kp Y &kp SEMI &kp M &kp LS(COMMA) &kp FSLH &kp RA(MINUS)
&magic LAYER_Magic 0 &none &none &none &none &kp SPACE &lower &kp LALT &none &raise &kp RET &none &none &kp SQT &kp RBKT &kp BSLH
>;
};
layer_Azerty {
bindings = <
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&kp TAB &kp Q &kp W &kp E &kp R &kp T &kp Y &kp U &kp I &kp O &kp P &trans
&kp LSHFT &kp A &kp S &kp D &kp F &kp G &kp H &kp J &kp K &kp L &kp SEMI &trans
&kp LCTRL &kp Z &kp X &kp C &kp V &kp B &trans &trans &trans &trans &trans &trans &kp N &kp M &kp COMMA &kp DOT &kp FSLH &trans
&magic LAYER_Magic 0 &trans &trans &trans &trans &trans &trans &trans &trans &to 0 &trans &trans &trans &trans &trans &trans
>;
};
layer_Gaming {
bindings = <
&trans &trans &trans &trans &trans &none &none &none &none &none
&trans &trans &trans &trans &trans &trans &none &none &none &none &none &none
&kp T &kp GRAVE &kp B &kp N &kp SEMI &none &none &none &none &none &none &none
&kp G &kp TAB &kp A &kp Z &kp E &kp R &none &none &none &none &none &none
&kp V &kp LSHFT &kp Q &kp S &kp D &kp F &kp RET &kp LALT &none &none &none &none &none &none &none &none &none &none
&magic LAYER_Magic 0 &kp LCTRL &kp W &kp X &kp C &kp SPACE &none &none &none &to 0 &none &none &none &none &none &none
>;
};
layer_Lower {
bindings = <
&none &none &none &none &none &none &none &none &none &none
&kp K_MUTE &kp F1 &kp F2 &kp F3 &kp F4 &kp F5 &none &kp KP_NUM &kp KP_SLASH &kp KP_MULTIPLY &kp KP_MINUS &kp DEL
&kp C_VOL_UP &none &none &kp PG_UP &none &none &none &kp KP_N7 &kp KP_N8 &kp KP_N9 &kp KP_PLUS &none
&kp C_VOL_DN &none &kp HOME &kp UP &kp END &kp LA(UP) &none &kp KP_N4 &kp KP_N5 &kp KP_N6 &kp KP_PLUS &none
&kp NON_US_BSLH &kp K_APP &kp LEFT &kp DOWN &kp RIGHT &kp LA(DOWN) &trans &trans &trans &trans &trans &trans &none &kp KP_N1 &kp KP_N2 &kp KP_N3 &kp KP_ENTER &kp LS(NON_US_BSLH)
&magic LAYER_Magic 0 &none &kp LC(LEFT) &kp PG_DN &kp LC(RIGHT) &kp RET &to 0 &trans &trans &trans &trans &kp KP_N0 &kp KP_N0 &kp KP_DOT &kp KP_ENTER &trans
>;
};
layer_Raise {
bindings = <
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &kp F6 &kp F7 &kp F8 &kp F9 &kp F10 &trans
&trans &kp FSLH &none &kp LS(M) &kp RBKT &kp LS(SQT) &trans &trans &trans &trans &trans &kp COMMA
&trans &kp RA(N0) &none &none &none &kp LBKT &trans &trans &trans &trans &trans &trans
&kp RA(N4) &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &kp RA(EQUAL)
&trans &trans &trans &trans &trans &trans &trans &trans &trans &to 0 &trans &trans &trans &trans &trans &trans
>;
};
layer_Magic {
bindings = <
&bt BT_CLR &none &none &none &none &none &none &none &none &bt BT_CLR_ALL
&to 0 &to 1 &to 2 &none &none &none &none &none &none &none &none &none
&none &rgb_ug RGB_SPI &rgb_ug RGB_SAI &rgb_ug RGB_HUI &rgb_ug RGB_BRI &rgb_ug RGB_TOG &none &none &none &none &none &none
&bootloader &rgb_ug RGB_SPD &rgb_ug RGB_SAD &rgb_ug RGB_HUD &rgb_ug RGB_BRD &rgb_ug RGB_EFF &none &none &none &none &none &bootloader
&sys_reset &none &none &none &none &none &bt_2 &bt_3 &none &none &none &none &none &none &none &none &none &sys_reset
&none &none &none &none &none &bt_0 &bt_1 &out OUT_USB &none &none &none &none &none &none &none &none
>;
};
};
};