summaryrefslogtreecommitdiff
path: root/users/stanrc85/rgblight_layers.c
diff options
context:
space:
mode:
authorstanrc85 <47038504+stanrc85@users.noreply.github.com>2020-09-06 18:04:29 -0400
committerGitHub <noreply@github.com>2020-09-06 15:04:29 -0700
commit6c3e404839bec5f04e8f0d9eef4f0ac98b16e987 (patch)
tree05d19ae0db38079c61807710c0b8b48bf8b71525 /users/stanrc85/rgblight_layers.c
parentf7ccbfcea88e127319a4665a6c8ca67883854030 (diff)
downloadqmk_firmware-6c3e404839bec5f04e8f0d9eef4f0ac98b16e987.tar.gz
qmk_firmware-6c3e404839bec5f04e8f0d9eef4f0ac98b16e987.zip
[Keymap] Add indicator light bootup fanfare (#10158)
* Add indicator light bootup fanfare * move fanfare code to new file * fanfare code in new file and remove unused boards * new startup fanfare code * add lock/unlock indicator animation * input key presses before changing lights * remove old code
Diffstat (limited to 'users/stanrc85/rgblight_layers.c')
-rw-r--r--users/stanrc85/rgblight_layers.c38
1 files changed, 0 insertions, 38 deletions
diff --git a/users/stanrc85/rgblight_layers.c b/users/stanrc85/rgblight_layers.c
index 780555e7b5..1fbd541498 100644
--- a/users/stanrc85/rgblight_layers.c
+++ b/users/stanrc85/rgblight_layers.c
@@ -3,44 +3,7 @@
static uint8_t middle = 0;
static uint8_t bottom = 0;
-const rgblight_segment_t PROGMEM my_capslock_layer[] = RGBLIGHT_LAYER_SEGMENTS(
- {3, 2, HSV_RED},
- {10, 2, HSV_RED}
-);
-
-const rgblight_segment_t PROGMEM my_layer1_layer[] = RGBLIGHT_LAYER_SEGMENTS(
- {3, 1, HSV_GREEN},
- {11, 1, HSV_GREEN}
-);
-
-const rgblight_segment_t PROGMEM my_layer2_layer[] = RGBLIGHT_LAYER_SEGMENTS(
- {3, 1, HSV_BLUE},
- {11, 1, HSV_BLUE}
-);
-
-const rgblight_segment_t PROGMEM my_layer3_layer[] = RGBLIGHT_LAYER_SEGMENTS(
- {3, 1, HSV_WHITE},
- {11, 1, HSV_WHITE}
-);
-
-// Now define the array of layers. Later layers take precedence
-const rgblight_segment_t* const PROGMEM my_rgb_layers[] = RGBLIGHT_LAYERS_LIST(
- my_capslock_layer,
- my_layer1_layer,
- my_layer2_layer,
- my_layer3_layer
-);
-
-void keyboard_post_init_user(void) {
- // Enable the LED layers
- rgblight_layers = my_rgb_layers;
-}
-
layer_state_t layer_state_set_user(layer_state_t state) {
- // Both layers will light up if both kb layers are active
- rgblight_set_layer_state(1, layer_state_cmp(state, 1));
- rgblight_set_layer_state(2, layer_state_cmp(state, 2));
- rgblight_set_layer_state(3, layer_state_cmp(state, 3));
middle = bottom = 0;
switch (get_highest_layer(state)) {
case _FN1_60:
@@ -60,7 +23,6 @@ layer_state_t layer_state_set_user(layer_state_t state) {
}
bool led_update_user(led_t led_state) {
- //rgblight_set_layer_state(0, led_state.caps_lock);
writePin(INDICATOR_PIN_0, !led_state.caps_lock);
writePin(INDICATOR_PIN_1, !middle);
writePin(INDICATOR_PIN_2, !bottom);