diff options
Diffstat (limited to 'quantum/rgblight.h')
| -rw-r--r-- | quantum/rgblight.h | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/quantum/rgblight.h b/quantum/rgblight.h index 9e1562328..17f04ffcf 100644 --- a/quantum/rgblight.h +++ b/quantum/rgblight.h | |||
| @@ -1,8 +1,11 @@ | |||
| 1 | #ifndef RGBLIGHT_H | 1 | #ifndef RGBLIGHT_H |
| 2 | #define RGBLIGHT_H | 2 | #define RGBLIGHT_H |
| 3 | 3 | ||
| 4 | #ifndef RGBLIGHT_MODES | 4 | |
| 5 | #define RGBLIGHT_MODES 23 | 5 | #if !defined(AUDIO_ENABLE) && defined(RGBLIGHT_TIMER) |
| 6 | #define RGBLIGHT_MODES 23 | ||
| 7 | #else | ||
| 8 | #define RGBLIGHT_MODES 1 | ||
| 6 | #endif | 9 | #endif |
| 7 | 10 | ||
| 8 | #ifndef RGBLIGHT_EFFECT_SNAKE_LENGTH | 11 | #ifndef RGBLIGHT_EFFECT_SNAKE_LENGTH |
| @@ -37,6 +40,12 @@ | |||
| 37 | #include "eeconfig.h" | 40 | #include "eeconfig.h" |
| 38 | #include "light_ws2812.h" | 41 | #include "light_ws2812.h" |
| 39 | 42 | ||
| 43 | extern const uint8_t RGBLED_BREATHING_INTERVALS[4] PROGMEM; | ||
| 44 | extern const uint8_t RGBLED_RAINBOW_MOOD_INTERVALS[3] PROGMEM; | ||
| 45 | extern const uint8_t RGBLED_RAINBOW_SWIRL_INTERVALS[3] PROGMEM; | ||
| 46 | extern const uint8_t RGBLED_SNAKE_INTERVALS[3] PROGMEM; | ||
| 47 | extern const uint8_t RGBLED_KNIGHT_INTERVALS[3] PROGMEM; | ||
| 48 | |||
| 40 | typedef union { | 49 | typedef union { |
| 41 | uint32_t raw; | 50 | uint32_t raw; |
| 42 | struct { | 51 | struct { |
| @@ -64,10 +73,9 @@ void rgblight_decrease_val(void); | |||
| 64 | void rgblight_sethsv(uint16_t hue, uint8_t sat, uint8_t val); | 73 | void rgblight_sethsv(uint16_t hue, uint8_t sat, uint8_t val); |
| 65 | void rgblight_setrgb(uint8_t r, uint8_t g, uint8_t b); | 74 | void rgblight_setrgb(uint8_t r, uint8_t g, uint8_t b); |
| 66 | 75 | ||
| 67 | #define EECONFIG_RGBLIGHT (uint8_t *)7 | ||
| 68 | uint32_t eeconfig_read_rgblight(void); | 76 | uint32_t eeconfig_read_rgblight(void); |
| 69 | void eeconfig_write_rgblight(uint32_t val); | 77 | void eeconfig_update_rgblight(uint32_t val); |
| 70 | void eeconfig_write_rgblight_default(void); | 78 | void eeconfig_update_rgblight_default(void); |
| 71 | void eeconfig_debug_rgblight(void); | 79 | void eeconfig_debug_rgblight(void); |
| 72 | 80 | ||
| 73 | void sethsv(uint16_t hue, uint8_t sat, uint8_t val, struct cRGB *led1); | 81 | void sethsv(uint16_t hue, uint8_t sat, uint8_t val, struct cRGB *led1); |
