aboutsummaryrefslogtreecommitdiff
path: root/keyboards/nullbitsco/scramble/keymaps/via/keymap.c
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/nullbitsco/scramble/keymaps/via/keymap.c')
-rw-r--r--keyboards/nullbitsco/scramble/keymaps/via/keymap.c61
1 files changed, 61 insertions, 0 deletions
diff --git a/keyboards/nullbitsco/scramble/keymaps/via/keymap.c b/keyboards/nullbitsco/scramble/keymaps/via/keymap.c
new file mode 100644
index 000000000..91a448cc1
--- /dev/null
+++ b/keyboards/nullbitsco/scramble/keymaps/via/keymap.c
@@ -0,0 +1,61 @@
1/*
2Copyright 2020 Jay Greco
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 2 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17
18#include QMK_KEYBOARD_H
19
20enum layer_names {
21 _BASE,
22 _VIA1,
23 _VIA2,
24 _VIA3
25};
26
27const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
28
29[_BASE] = LAYOUT(
30 KC_F1, KC_F2, KC_F3,
31 KC_F4, KC_F5, KC_F6
32),
33
34[_VIA1] = LAYOUT(
35 _______, _______, _______,
36 _______, _______, _______
37),
38
39[_VIA2] = LAYOUT(
40 _______, _______, _______,
41 _______, _______, _______
42),
43
44[_VIA3] = LAYOUT(
45 _______, _______, _______,
46 _______, _______, _______
47)
48
49};
50
51void matrix_init_user(void) {
52 set_scramble_LED(LED_OFF);
53}
54
55void encoder_update_user(uint8_t index, bool clockwise) {
56 if (clockwise) {
57 tap_code(KC_VOLU);
58 } else {
59 tap_code(KC_VOLD);
60 }
61} \ No newline at end of file