fix(display): correct type cast syntax in pulse calculation
This commit is contained in:
@@ -171,9 +171,8 @@ void DisplayDriverGFX::render(const ScreenState& state) {
|
||||
}
|
||||
|
||||
void DisplayDriverGFX::drawAlert(const ScreenState& state) {
|
||||
// Always redraw background for animation
|
||||
uint32_t elapsed = millis() - state.alertStartMs;
|
||||
uint8_cast<uint8_t_t pulse = static>(180.0f + 75.0f * sinf(elapsed / 300.0f));
|
||||
uint8_t pulse = static_cast<uint8_t>(180.0f + 75.0f * sinf(elapsed / 300.0f));
|
||||
uint16_t bg = _gfx->color565(pulse, 0, 0);
|
||||
|
||||
_gfx->fillScreen(bg);
|
||||
|
||||
Reference in New Issue
Block a user