diff options
author | Akshay <[email protected]> | 2022-04-10 12:13:40 +0100 |
---|---|---|
committer | Akshay <[email protected]> | 2022-04-10 12:13:40 +0100 |
commit | dc90387ce7d8ba7b607d9c48540bf6d8b560f14d (patch) | |
tree | 4ccb8fa5886b66fa9d480edef74236c27f035e16 /keyboards/capsunlocked/cu7/keymaps/default/keymap.c |
Diffstat (limited to 'keyboards/capsunlocked/cu7/keymaps/default/keymap.c')
-rw-r--r-- | keyboards/capsunlocked/cu7/keymaps/default/keymap.c | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/keyboards/capsunlocked/cu7/keymaps/default/keymap.c b/keyboards/capsunlocked/cu7/keymaps/default/keymap.c new file mode 100644 index 000000000..66ee4f7a9 --- /dev/null +++ b/keyboards/capsunlocked/cu7/keymaps/default/keymap.c | |||
@@ -0,0 +1,42 @@ | |||
1 | /* | ||
2 | Copyright 2021 CapsUnlocked | ||
3 | |||
4 | This program is free software: you can redistribute it and/or modify | ||
5 | it under the terms of the GNU General Public License as published by | ||
6 | the Free Software Foundation, either version 2 of the License, or | ||
7 | (at your option) any later version. | ||
8 | |||
9 | This program is distributed in the hope that it will be useful, | ||
10 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | GNU General Public License for more details. | ||
13 | |||
14 | You should have received a copy of the GNU General Public License | ||
15 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
16 | */ | ||
17 | #include QMK_KEYBOARD_H | ||
18 | |||
19 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
20 | [0] = LAYOUT( | ||
21 | MO(1), | ||
22 | KC_1, KC_2, KC_3, | ||
23 | KC_4, KC_5, KC_6 | ||
24 | ), | ||
25 | [1] = LAYOUT( | ||
26 | _______, | ||
27 | RGB_MOD, KC_UP, RESET, | ||
28 | KC_LEFT, KC_DOWN, KC_RGHT | ||
29 | ), | ||
30 | }; | ||
31 | |||
32 | // Volume up/down on the encoder | ||
33 | bool encoder_update_user(uint8_t index, bool clockwise) { | ||
34 | if (clockwise) { | ||
35 | tap_code_delay(KC_VOLU, 10); | ||
36 | } | ||
37 | else { | ||
38 | tap_code_delay(KC_VOLD, 10); | ||
39 | } | ||
40 | |||
41 | return true; | ||
42 | } | ||