added LightState Switch
This commit is contained in:
@@ -35,6 +35,14 @@ static volatile struct LightSettings_s {
|
||||
volatile uint8_t theme;
|
||||
} lightSettings;
|
||||
|
||||
void LightTask_setBrightness(uint8_t brightness) {
|
||||
lightSettings.brightness = brightness;
|
||||
}
|
||||
|
||||
void LightTask_setTheme(uint8_t theme) {
|
||||
lightSettings.theme = theme;
|
||||
}
|
||||
|
||||
// these are used to save these settings some tome after they change
|
||||
static const uint32_t settingSaveTimeout = 10*1000;
|
||||
static volatile uint32_t settingChangeTime = 0;
|
||||
|
||||
Reference in New Issue
Block a user