ota update first version, with led management

This commit is contained in:
Emanuele Trabattoni
2025-08-05 11:56:13 +02:00
parent 80fda62344
commit 5bff567863
7 changed files with 212 additions and 7 deletions

View File

@@ -21,6 +21,7 @@ namespace drivers
uint8_t b;
} color_t;
const color_t COLOR_OFF = {0, 0, 0};
const color_t COLOR_RED = {255, 0, 0};
const color_t COLOR_ORANGE = {255, 127, 0};
const color_t COLOR_YELLOW = {255, 255, 0};
@@ -36,6 +37,7 @@ namespace drivers
Led();
~Led();
void setEnforce(const bool enf);
void setColor(const color_t color);
void flashColor(const uint16_t tOn, const color_t color);
void blinkColor(const uint16_t tOn, const uint16_t tOff, const color_t color);
@@ -60,6 +62,7 @@ namespace drivers
TimerHandle_t m_flashTimer;
bool m_flashing;
bool m_enforce;
std::mutex m_ledMutex;
};