diff options
| author | XScorpion2 <rcalt2vt@gmail.com> | 2019-04-30 22:55:01 -0500 |
|---|---|---|
| committer | Drashna Jaelre <drashna@live.com> | 2019-04-30 20:55:01 -0700 |
| commit | e95283b54512eda893b9d43a9f1b72bf8c03970b (patch) | |
| tree | 862e37015c95847c3a361735c87834bcdbf36c5a | |
| parent | 8725197ad679647d2eb7876aee3f9df32edb5766 (diff) | |
| download | qmk_firmware-e95283b54512eda893b9d43a9f1b72bf8c03970b.tar.gz qmk_firmware-e95283b54512eda893b9d43a9f1b72bf8c03970b.zip | |
[Keymap] Xulkal keymap tweeks (#5746)
* Minor keymap tweeks and more oled data
* Update keymap.c
| -rw-r--r-- | keyboards/sol/keymaps/xulkal/keymap.c | 20 | ||||
| -rw-r--r-- | users/xulkal/config.h | 14 | ||||
| -rw-r--r-- | users/xulkal/process_records.c | 12 |
3 files changed, 41 insertions, 5 deletions
diff --git a/keyboards/sol/keymaps/xulkal/keymap.c b/keyboards/sol/keymaps/xulkal/keymap.c index be64d9e7c..4591034d2 100644 --- a/keyboards/sol/keymaps/xulkal/keymap.c +++ b/keyboards/sol/keymaps/xulkal/keymap.c | |||
| @@ -92,15 +92,29 @@ static void render_logo(void) { | |||
| 92 | oled_write_P(sol_logo, false); | 92 | oled_write_P(sol_logo, false); |
| 93 | } | 93 | } |
| 94 | 94 | ||
| 95 | extern rgb_config_t rgb_matrix_config; | ||
| 96 | |||
| 95 | static void render_status(void) { | 97 | static void render_status(void) { |
| 96 | // Render to mode icon | 98 | // Render to mode icon |
| 97 | static const char PROGMEM mode_logo[2][4] = { | 99 | static const char PROGMEM mode_logo[2][3] = { |
| 98 | {0x97,0x98,0x0a,0}, | 100 | {0x97,0x98,0}, |
| 99 | {0xb7,0xb8,0x0a,0} }; | 101 | {0xb7,0xb8,0} }; |
| 100 | 102 | ||
| 101 | oled_write_P(mode_logo[0], false); | 103 | oled_write_P(mode_logo[0], false); |
| 104 | |||
| 105 | #if defined(RGB_MATRIX_ENABLE) | ||
| 106 | static char buffer[20] = {0}; | ||
| 107 | snprintf(buffer, sizeof(buffer), " h%3d s%3d v%3d\n", rgb_matrix_config.hue, rgb_matrix_config.sat, rgb_matrix_config.val); | ||
| 108 | oled_write(buffer, false); | ||
| 109 | #endif | ||
| 110 | |||
| 102 | oled_write_P(mode_logo[1], false); | 111 | oled_write_P(mode_logo[1], false); |
| 103 | 112 | ||
| 113 | #if defined(RGB_MATRIX_ENABLE) | ||
| 114 | snprintf(buffer, sizeof(buffer), " s%3d m%3d\n", rgb_matrix_config.speed, rgb_matrix_config.mode); | ||
| 115 | oled_write(buffer, false); | ||
| 116 | #endif | ||
| 117 | |||
| 104 | // Define layers here, Have not worked out how to have text displayed for each layer. Copy down the number you see and add a case for it below | 118 | // Define layers here, Have not worked out how to have text displayed for each layer. Copy down the number you see and add a case for it below |
| 105 | oled_write_P(PSTR("Layer: "), false); | 119 | oled_write_P(PSTR("Layer: "), false); |
| 106 | switch (biton32(layer_state)) { | 120 | switch (biton32(layer_state)) { |
diff --git a/users/xulkal/config.h b/users/xulkal/config.h index 5f56f7a14..6ff4ca49d 100644 --- a/users/xulkal/config.h +++ b/users/xulkal/config.h | |||
| @@ -11,3 +11,17 @@ | |||
| 11 | #define RSPC_KEYS KC_RSFT, KC_TRNS, KC_RBRC | 11 | #define RSPC_KEYS KC_RSFT, KC_TRNS, KC_RBRC |
| 12 | #define LCPO_KEYS KC_LCTL, KC_TRNS, KC_MINS | 12 | #define LCPO_KEYS KC_LCTL, KC_TRNS, KC_MINS |
| 13 | #define RCPO_KEYS KC_RCTL, KC_TRNS, KC_EQL | 13 | #define RCPO_KEYS KC_RCTL, KC_TRNS, KC_EQL |
| 14 | |||
| 15 | // No need for the single versions when multi performance isn't a problem =D | ||
| 16 | #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE | ||
| 17 | #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS | ||
| 18 | #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS | ||
| 19 | #define DISABLE_RGB_MATRIX_SPLASH | ||
| 20 | #define DISABLE_RGB_MATRIX_SOLID_SPLASH | ||
| 21 | |||
| 22 | // Don't like or feel to identical to other effects | ||
| 23 | #define DISABLE_RGB_MATRIX_RAINBOW_BEACON | ||
| 24 | #define DISABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS | ||
| 25 | #define DISABLE_RGB_MATRIX_DIGITAL_RAIN | ||
| 26 | #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE | ||
| 27 | #define DISABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS | ||
diff --git a/users/xulkal/process_records.c b/users/xulkal/process_records.c index af849a072..531f99eb0 100644 --- a/users/xulkal/process_records.c +++ b/users/xulkal/process_records.c | |||
| @@ -11,6 +11,10 @@ qk_tap_dance_action_t tap_dance_actions[] = { | |||
| 11 | }; | 11 | }; |
| 12 | #endif | 12 | #endif |
| 13 | 13 | ||
| 14 | #if defined(RGB_MATRIX_ENABLE) | ||
| 15 | extern void eeconfig_update_rgb_matrix_default(void); | ||
| 16 | #endif | ||
| 17 | |||
| 14 | bool process_record_user(uint16_t keycode, keyrecord_t *record) { | 18 | bool process_record_user(uint16_t keycode, keyrecord_t *record) { |
| 15 | switch (keycode) { | 19 | switch (keycode) { |
| 16 | case QWERTY: | 20 | case QWERTY: |
| @@ -56,12 +60,16 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { | |||
| 56 | return false; | 60 | return false; |
| 57 | break; | 61 | break; |
| 58 | case RGBRST: | 62 | case RGBRST: |
| 59 | #ifdef RGBLIGHT_ENABLE | 63 | #if defined(RGBLIGHT_ENABLE) |
| 60 | if (record->event.pressed) { | 64 | if (record->event.pressed) { |
| 61 | eeconfig_update_rgblight_default(); | 65 | eeconfig_update_rgblight_default(); |
| 62 | rgblight_enable(); | 66 | rgblight_enable(); |
| 63 | } | 67 | } |
| 64 | #endif | 68 | #elif defined(RGB_MATRIX_ENABLE) |
| 69 | if (record->event.pressed) { | ||
| 70 | eeconfig_update_rgb_matrix_default(); | ||
| 71 | } | ||
| 72 | #endif | ||
| 65 | return false; | 73 | return false; |
| 66 | break; | 74 | break; |
| 67 | } | 75 | } |
