summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--quantum/quantum.c6
-rw-r--r--tmk_core/common/keyboard.c10
-rw-r--r--tmk_core/protocol/chibios/main.c3
-rw-r--r--tmk_core/protocol/lufa/lufa.c4
-rw-r--r--tmk_core/protocol/vusb/main.c4
5 files changed, 11 insertions, 16 deletions
diff --git a/quantum/quantum.c b/quantum/quantum.c
index 9870d8fca5..de33935edf 100644
--- a/quantum/quantum.c
+++ b/quantum/quantum.c
@@ -635,12 +635,8 @@ void matrix_scan_quantum() {
matrix_scan_combo();
#endif
-#if defined(BACKLIGHT_ENABLE)
-# if defined(LED_MATRIX_ENABLE)
+#ifdef LED_MATRIX_ENABLE
led_matrix_task();
-# elif defined(BACKLIGHT_PIN) || defined(BACKLIGHT_PINS)
- backlight_task();
-# endif
#endif
#ifdef RGB_MATRIX_ENABLE
diff --git a/tmk_core/common/keyboard.c b/tmk_core/common/keyboard.c
index 2a61985f98..95238d1c4c 100644
--- a/tmk_core/common/keyboard.c
+++ b/tmk_core/common/keyboard.c
@@ -330,6 +330,16 @@ MATRIX_LOOP_END:
matrix_scan_perf_task();
#endif
+#if defined(RGBLIGHT_ANIMATIONS) && defined(RGBLIGHT_ENABLE)
+ rgblight_task();
+#endif
+
+#if defined(BACKLIGHT_ENABLE)
+# if defined(BACKLIGHT_PIN) || defined(BACKLIGHT_PINS)
+ backlight_task();
+# endif
+#endif
+
#ifdef QWIIC_ENABLE
qwiic_task();
#endif
diff --git a/tmk_core/protocol/chibios/main.c b/tmk_core/protocol/chibios/main.c
index 6d9608dddb..76e6e23776 100644
--- a/tmk_core/protocol/chibios/main.c
+++ b/tmk_core/protocol/chibios/main.c
@@ -234,8 +234,5 @@ int main(void) {
webusb_task();
#endif
-#if defined(RGBLIGHT_ANIMATIONS) && defined(RGBLIGHT_ENABLE)
- rgblight_task();
-#endif
}
}
diff --git a/tmk_core/protocol/lufa/lufa.c b/tmk_core/protocol/lufa/lufa.c
index 8748ea63bf..5538f0e245 100644
--- a/tmk_core/protocol/lufa/lufa.c
+++ b/tmk_core/protocol/lufa/lufa.c
@@ -1110,10 +1110,6 @@ int main(void) {
MIDI_Device_USBTask(&USB_MIDI_Interface);
#endif
-#if defined(RGBLIGHT_ANIMATIONS) && defined(RGBLIGHT_ENABLE)
- rgblight_task();
-#endif
-
#ifdef MODULE_ADAFRUIT_BLE
adafruit_ble_task();
#endif
diff --git a/tmk_core/protocol/vusb/main.c b/tmk_core/protocol/vusb/main.c
index e6291900e6..06dc8ae67f 100644
--- a/tmk_core/protocol/vusb/main.c
+++ b/tmk_core/protocol/vusb/main.c
@@ -99,10 +99,6 @@ int main(void) {
// To prevent failing to configure NOT scan keyboard during configuration
if (usbConfiguration && usbInterruptIsReady()) {
keyboard_task();
-
-#if defined(RGBLIGHT_ANIMATIONS) && defined(RGBLIGHT_ENABLE)
- rgblight_task();
-#endif
}
vusb_transfer_keyboard();
}