strip unused esp32 deps, fix render loop power waste
This commit is contained in:
@@ -15,14 +15,6 @@ esp-idf-sys = "0.37"
|
||||
|
||||
mipidsi = "0.10"
|
||||
embedded-graphics = "0.8"
|
||||
embedded-text = "0.7"
|
||||
embedded-hal-bus = "0.3"
|
||||
|
||||
serde = { version = "1.0", default-features = false, features = [
|
||||
"derive",
|
||||
"alloc",
|
||||
] }
|
||||
postcard = { version = "1.1", default-features = false, features = ["alloc"] }
|
||||
|
||||
log = "0.4"
|
||||
|
||||
|
||||
@@ -41,12 +41,6 @@ fn fill_triangles<D: DrawTarget<Color = Rgb565>>(
|
||||
}
|
||||
}
|
||||
|
||||
// Outer hexagon vertices (150x150 viewBox)
|
||||
const OUTER_HEX: [(f32, f32); 6] = [
|
||||
(75.0, 0.0), (150.0, 37.5), (150.0, 112.5),
|
||||
(75.0, 150.0), (0.0, 112.5), (0.0, 37.5),
|
||||
];
|
||||
|
||||
// Converted from SVG: (150,75)(112.5,150)(37.5,150)(0,75)(37.5,0)(112.5,0)
|
||||
// Reordered to start from top for cleaner fan
|
||||
const OUTER_HEX_SVG: [(f32, f32); 6] = [
|
||||
|
||||
@@ -47,7 +47,8 @@ pub fn run(
|
||||
display.flush().unwrap();
|
||||
|
||||
loop {
|
||||
let timeout = RENDER_POLL_INTERVAL.min(SCROLL_TICK);
|
||||
let has_scrollers = widgets.values().any(|c| c.scroll.is_active());
|
||||
let timeout = if has_scrollers { SCROLL_TICK } else { RENDER_POLL_INTERVAL };
|
||||
match rx.recv_timeout(timeout) {
|
||||
Ok(RenderEvent::ConnectionStatus(status)) => {
|
||||
if status != connected {
|
||||
|
||||
Reference in New Issue
Block a user