From cc158c16e166e89bae748585e2948a7954293f36 Mon Sep 17 00:00:00 2001 From: Eli Lipsitz <552502+elipsitz@users.noreply.github.com> Date: Sat, 25 Mar 2023 17:12:30 -0700 Subject: [PATCH] Fix rgblight layers when animations aren't enabled (#20097) --- quantum/rgblight/rgblight.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/quantum/rgblight/rgblight.h b/quantum/rgblight/rgblight.h index 769388846241..4880d78fe398 100644 --- a/quantum/rgblight/rgblight.h +++ b/quantum/rgblight/rgblight.h @@ -174,6 +174,10 @@ typedef struct { uint8_t val; } rgblight_segment_t; +// rgblight_set_layer_state doesn't take effect until the next time +// rgblight_task runs, so timers must be enabled for layers to work. +# define RGBLIGHT_USE_TIMER + # define RGBLIGHT_END_SEGMENT_INDEX (255) # define RGBLIGHT_END_SEGMENTS \ { RGBLIGHT_END_SEGMENT_INDEX, 0, 0, 0 }