summaryrefslogtreecommitdiffstats
path: root/keyboards/1upkeyboards/super16v2/keymaps/default/keymap.c
diff options
context:
space:
mode:
authorziptyze <mwcordier@gmail.com>2022-04-13 02:04:38 -0400
committerGitHub <noreply@github.com>2022-04-12 23:04:38 -0700
commit2d05c7fc2500582fd0605569fe929e04bb8cc8ae (patch)
treed5d126ff92dc2b0fe317011b5f8f577e769fa205 /keyboards/1upkeyboards/super16v2/keymaps/default/keymap.c
parent3f66e25b41cdb9192f1a9efb2771fed36559afb0 (diff)
[Keyboard] super16 update (#16494)
Diffstat (limited to 'keyboards/1upkeyboards/super16v2/keymaps/default/keymap.c')
-rw-r--r--keyboards/1upkeyboards/super16v2/keymaps/default/keymap.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/keyboards/1upkeyboards/super16v2/keymaps/default/keymap.c b/keyboards/1upkeyboards/super16v2/keymaps/default/keymap.c
index dc58023a37..b80db58bae 100644
--- a/keyboards/1upkeyboards/super16v2/keymaps/default/keymap.c
+++ b/keyboards/1upkeyboards/super16v2/keymaps/default/keymap.c
@@ -27,8 +27,24 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[1] = LAYOUT_ortho_4x4( /* Fn Layer */
RGB_TOG, RGB_HUI, RGB_SAI, RGB_VAI,
RGB_MOD, RGB_HUD, RGB_SAD, RGB_VAD,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ RGB_SPD, RGB_SPI, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, RESET
),
};
+bool encoder_update_user(uint8_t index, bool clockwise) {
+ if (index == 0) { /* First encoder */
+ if (clockwise) {
+ tap_code_delay(KC_VOLU, 10);
+ } else {
+ tap_code_delay(KC_VOLD, 10);
+ }
+ } else if (index == 1) { /* Second encoder */
+ if (clockwise) {
+ rgb_matrix_increase_hue();
+ } else {
+ rgb_matrix_decrease_hue();
+ }
+ }
+ return false;
+} \ No newline at end of file