diff options
Diffstat (limited to 'keyboards/bandominedoni/keymaps/default/keymap.c')
-rw-r--r-- | keyboards/bandominedoni/keymaps/default/keymap.c | 84 |
1 files changed, 84 insertions, 0 deletions
diff --git a/keyboards/bandominedoni/keymaps/default/keymap.c b/keyboards/bandominedoni/keymaps/default/keymap.c new file mode 100644 index 000000000..bfa49dfe1 --- /dev/null +++ b/keyboards/bandominedoni/keymaps/default/keymap.c | |||
@@ -0,0 +1,84 @@ | |||
1 | /* Copyright 2021 3araht | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include QMK_KEYBOARD_H | ||
17 | |||
18 | // Defines names for use in layer keycodes and the keymap | ||
19 | enum layer_names { | ||
20 | #ifndef PEDAL_NORMALLY_CLOSED | ||
21 | _OPEN, | ||
22 | #endif | ||
23 | _CLOSE, | ||
24 | #ifdef PEDAL_NORMALLY_CLOSED | ||
25 | _OPEN, | ||
26 | #endif | ||
27 | _FN | ||
28 | }; | ||
29 | |||
30 | |||
31 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
32 | [_OPEN] = LAYOUT( | ||
33 | MI_Gs_1, MI_As_1, MI_Cs_2, MI_F_2, MI_Gs_3, | ||
34 | MI_E_1, MI_A_1, MI_G_2, MI_Ds_2, MI_F_3, MI_As_2, MI_F_1, | ||
35 | MI_D_2, MI_A_2, MI_C_3, MI_E_3, MI_C_2, MI_G_1, TG_SWAP, | ||
36 | MI_E_2, MI_Gs_2, MI_B_2, MI_D_3, MI_Fs_3, MI_Cs_3, MI_Fs_1, | ||
37 | MI_D_1, MI_B_1, MI_G_3, MI_A_3, MI_Ds_3, MI_Fs_2, MI_Ds_1, MI_C_1, | ||
38 | |||
39 | MO_SWAP, MI_B_5, MI_Gs_5, MI_G_5, MI_F_5, FN_MUTE, | ||
40 | MI_Cs_3, MI_A_5, MI_Fs_5, MI_E_5, MI_Ds_5, KC_VOLD, KC_VOLU, | ||
41 | MI_C_3, MI_D_3, MI_G_3, MI_As_4, MI_C_5, MI_D_5, | ||
42 | TG_SWAP, MI_B_2, MI_E_3, MI_Cs_4, MI_Fs_3, MI_A_3, MI_C_4, MI_E_4, | ||
43 | MI_A_2, MI_F_3, MI_As_3, MI_Gs_3, MI_B_3, MI_D_4, MI_Gs_4, MI_B_4, | ||
44 | MI_Gs_2, MI_As_2, MI_Ds_3, MI_F_4, MI_Ds_4, MI_Fs_4, MI_A_4, MI_Cs_5, MI_G_4 | ||
45 | ), | ||
46 | |||
47 | [_CLOSE] = LAYOUT( | ||
48 | MI_Gs_1, MI_As_1, MI_Ds_2, MI_Ds_3, MI_G_3, | ||
49 | MI_D_1, MI_D_2, MI_As_2, MI_C_3, MI_Cs_2, MI_C_2, MI_Fs_1, | ||
50 | MI_G_1, MI_G_2, MI_B_2, MI_D_3, MI_F_3, MI_Fs_2, TG_SWAP, | ||
51 | MI_A_1, MI_E_2, MI_A_2, MI_Cs_3, MI_E_3, MI_Gs_2, MI_B_1, | ||
52 | MI_E_1, MI_E_2, MI_Fs_3, MI_Gs_3, MI_B_3, MI_F_2, MI_Cs_1, MI_F_1, | ||
53 | |||
54 | MO_SWAP, MI_A_5, MI_Gs_5, MI_Fs_5, MI_F_5, FN_MUTE, | ||
55 | MI_C_3, MI_G_5, MI_As_4, MI_C_5, MI_Ds_5, KC_VOLD, KC_VOLU, | ||
56 | MI_D_3, MI_Cs_3, MI_Gs_3, MI_As_3, MI_C_4, MI_D_5, | ||
57 | TG_SWAP, MI_B_2, MI_Fs_3, MI_Fs_4, MI_G_3, MI_B_3, MI_D_4, MI_G_4, | ||
58 | MI_A_2, MI_F_3, MI_E_3, MI_A_3, MI_Cs_4, MI_E_4, MI_A_4, MI_Cs_5, | ||
59 | MI_Gs_2, MI_As_2, MI_Ds_3, MI_F_4, MI_E_4, MI_Gs_4, MI_B_4, MI_E_5, MI_Ds_4 | ||
60 | ), | ||
61 | |||
62 | [_FN] = LAYOUT( | ||
63 | DF_SWAP, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | ||
64 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | ||
65 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, | ||
66 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | ||
67 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | ||
68 | |||
69 | _______, MI_OCTD, MI_OCTU, MI_VELD, MI_VELU, _______, | ||
70 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | ||
71 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | ||
72 | _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | ||
73 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, | ||
74 | XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX | ||
75 | ) | ||
76 | }; | ||
77 | |||
78 | void keyboard_post_init_user(void) { | ||
79 | // Set octave to MI_OCT_0 | ||
80 | midi_config.octave = MI_OCT_0 - MIDI_OCTAVE_MIN; | ||
81 | |||
82 | // avoid using 127 since it is used as a special number in some sound sources. | ||
83 | midi_config.velocity = MIDI_INITIAL_VELOCITY; | ||
84 | }; | ||