Status overlay on every screen: Wi-Fi chip top-right, blinking alert banner; Driveline values red on crossed thresholds, ring red on gear mismatch
Firmware / build (push) Successful in 7m12s
Firmware / build (push) Successful in 7m12s
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
* Status Overlay - what every screen shows, on lv_layer_top():
|
||||
*
|
||||
* top-right Wi-Fi chip: off / not connected / joining / <network>
|
||||
* top-centre ALERT BANNER: red and blinking (2 Hz) while any red alert from
|
||||
* Tunables' thresholds is on (coolant hot, gearbox oil hot,
|
||||
* gear mismatch, battery low), steady amber while the gearbox
|
||||
* asks for cooling. Hidden with CAN off or ignition off.
|
||||
*
|
||||
* Both are labels, so they never take touches from the screen below. tick()
|
||||
* runs from loop() and only touches an object when its text/colour changes.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <Arduino.h>
|
||||
|
||||
namespace StatusOverlay {
|
||||
|
||||
/** Build the two labels. Call after DisplayInit::init(), before the screens tick. */
|
||||
void init();
|
||||
|
||||
/** Refresh from WiFiManager / the shared automotive data. Call from loop(). */
|
||||
void tick();
|
||||
|
||||
} // namespace StatusOverlay
|
||||
Reference in New Issue
Block a user