summaryrefslogtreecommitdiffstats
path: root/quantum/led_matrix/led_matrix.h
diff options
context:
space:
mode:
Diffstat (limited to 'quantum/led_matrix/led_matrix.h')
-rw-r--r--quantum/led_matrix/led_matrix.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/quantum/led_matrix/led_matrix.h b/quantum/led_matrix/led_matrix.h
index 446f293c78..936083c259 100644
--- a/quantum/led_matrix/led_matrix.h
+++ b/quantum/led_matrix/led_matrix.h
@@ -78,6 +78,8 @@
#define LED_MATRIX_TEST_LED_FLAGS() \
if (!HAS_ANY_FLAGS(g_led_config.flags[i], params->flags)) continue
+#define LED_DISABLE_TIME_INFINITE (UINT32_MAX)
+
enum led_matrix_effects {
LED_MATRIX_NONE = 0,
@@ -117,6 +119,9 @@ void process_led_matrix(uint8_t row, uint8_t col, bool pressed);
void led_matrix_task(void);
+void led_matrix_none_indicators_kb(void);
+void led_matrix_none_indicators_user(void);
+
// This runs after another backlight effect and replaces
// values already set
void led_matrix_indicators(void);
@@ -138,6 +143,7 @@ void led_matrix_enable_noeeprom(void);
void led_matrix_disable(void);
void led_matrix_disable_noeeprom(void);
uint8_t led_matrix_is_enabled(void);
+uint8_t led_matrix_is_enabled_eeprom(void);
void led_matrix_mode(uint8_t mode);
void led_matrix_mode_noeeprom(uint8_t mode);
uint8_t led_matrix_get_mode(void);
@@ -163,6 +169,19 @@ led_flags_t led_matrix_get_flags(void);
void led_matrix_set_flags(led_flags_t flags);
void led_matrix_set_flags_noeeprom(led_flags_t flags);
+#ifdef LED_DISABLE_TIMEOUT
+# if LED_DISABLE_TIMEOUT > 0
+void led_matrix_disable_timeout_set(uint32_t timeout);
+void led_matrix_disable_time_reset(void);
+# endif
+#endif
+
+#ifdef LED_MATRIX_DRIVER_SHUTDOWN_ENABLE
+void led_matrix_driver_shutdown(void);
+bool led_matrix_is_driver_shutdown(void);
+bool led_matrix_driver_allow_shutdown(void);
+#endif
+
typedef struct {
/* Perform any initialisation required for the other driver functions to work. */
void (*init)(void);
@@ -173,6 +192,12 @@ typedef struct {
void (*set_value_all)(uint8_t value);
/* Flush any buffered changes to the hardware. */
void (*flush)(void);
+#ifdef LED_MATRIX_DRIVER_SHUTDOWN_ENABLE
+ /* Shutdown the driver. */
+ void (*shutdown)(void);
+ /* Exit from shutdown state. */
+ void (*exit_shutdown)(void);
+#endif
} led_matrix_driver_t;
static inline bool led_matrix_check_finished_leds(uint8_t led_idx) {