summaryrefslogtreecommitdiff
path: root/quantum/rgb_matrix/rgb_matrix.h
diff options
context:
space:
mode:
Diffstat (limited to 'quantum/rgb_matrix/rgb_matrix.h')
-rw-r--r--quantum/rgb_matrix/rgb_matrix.h24
1 files changed, 12 insertions, 12 deletions
diff --git a/quantum/rgb_matrix/rgb_matrix.h b/quantum/rgb_matrix/rgb_matrix.h
index fc9fc3e020..1cd054abc4 100644
--- a/quantum/rgb_matrix/rgb_matrix.h
+++ b/quantum/rgb_matrix/rgb_matrix.h
@@ -47,15 +47,15 @@
#endif
#ifndef RGB_MATRIX_LED_PROCESS_LIMIT
-# define RGB_MATRIX_LED_PROCESS_LIMIT (DRIVER_LED_TOTAL + 4) / 5
+# define RGB_MATRIX_LED_PROCESS_LIMIT (RGB_MATRIX_LED_COUNT + 4) / 5
#endif
-#if defined(RGB_MATRIX_LED_PROCESS_LIMIT) && RGB_MATRIX_LED_PROCESS_LIMIT > 0 && RGB_MATRIX_LED_PROCESS_LIMIT < DRIVER_LED_TOTAL
+#if defined(RGB_MATRIX_LED_PROCESS_LIMIT) && RGB_MATRIX_LED_PROCESS_LIMIT > 0 && RGB_MATRIX_LED_PROCESS_LIMIT < RGB_MATRIX_LED_COUNT
# if defined(RGB_MATRIX_SPLIT)
# define RGB_MATRIX_USE_LIMITS(min, max) \
uint8_t min = RGB_MATRIX_LED_PROCESS_LIMIT * params->iter; \
uint8_t max = min + RGB_MATRIX_LED_PROCESS_LIMIT; \
- if (max > DRIVER_LED_TOTAL) max = DRIVER_LED_TOTAL; \
+ if (max > RGB_MATRIX_LED_COUNT) max = RGB_MATRIX_LED_COUNT; \
uint8_t k_rgb_matrix_split[2] = RGB_MATRIX_SPLIT; \
if (is_keyboard_left() && (max > k_rgb_matrix_split[0])) max = k_rgb_matrix_split[0]; \
if (!(is_keyboard_left()) && (min < k_rgb_matrix_split[0])) min = k_rgb_matrix_split[0];
@@ -63,20 +63,20 @@
# define RGB_MATRIX_USE_LIMITS(min, max) \
uint8_t min = RGB_MATRIX_LED_PROCESS_LIMIT * params->iter; \
uint8_t max = min + RGB_MATRIX_LED_PROCESS_LIMIT; \
- if (max > DRIVER_LED_TOTAL) max = DRIVER_LED_TOTAL;
+ if (max > RGB_MATRIX_LED_COUNT) max = RGB_MATRIX_LED_COUNT;
# endif
#else
# if defined(RGB_MATRIX_SPLIT)
# define RGB_MATRIX_USE_LIMITS(min, max) \
uint8_t min = 0; \
- uint8_t max = DRIVER_LED_TOTAL; \
+ uint8_t max = RGB_MATRIX_LED_COUNT; \
const uint8_t k_rgb_matrix_split[2] = RGB_MATRIX_SPLIT; \
if (is_keyboard_left() && (max > k_rgb_matrix_split[0])) max = k_rgb_matrix_split[0]; \
if (!(is_keyboard_left()) && (min < k_rgb_matrix_split[0])) min = k_rgb_matrix_split[0];
# else
# define RGB_MATRIX_USE_LIMITS(min, max) \
uint8_t min = 0; \
- uint8_t max = DRIVER_LED_TOTAL;
+ uint8_t max = RGB_MATRIX_LED_COUNT;
# endif
#endif
@@ -129,12 +129,12 @@ void rgb_matrix_task(void);
// This runs after another backlight effect and replaces
// colors already set
void rgb_matrix_indicators(void);
-void rgb_matrix_indicators_kb(void);
-void rgb_matrix_indicators_user(void);
+bool rgb_matrix_indicators_kb(void);
+bool rgb_matrix_indicators_user(void);
void rgb_matrix_indicators_advanced(effect_params_t *params);
-void rgb_matrix_indicators_advanced_kb(uint8_t led_min, uint8_t led_max);
-void rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max);
+bool rgb_matrix_indicators_advanced_kb(uint8_t led_min, uint8_t led_max);
+bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max);
void rgb_matrix_init(void);
@@ -246,9 +246,9 @@ static inline bool rgb_matrix_check_finished_leds(uint8_t led_idx) {
uint8_t k_rgb_matrix_split[2] = RGB_MATRIX_SPLIT;
return led_idx < k_rgb_matrix_split[0];
} else
- return led_idx < DRIVER_LED_TOTAL;
+ return led_idx < RGB_MATRIX_LED_COUNT;
#else
- return led_idx < DRIVER_LED_TOTAL;
+ return led_idx < RGB_MATRIX_LED_COUNT;
#endif
}