conect
This commit is contained in:
parent
e174ecdeaf
commit
c1144d58a3
15
src/main.rs
15
src/main.rs
@ -121,15 +121,16 @@ fn main() -> ! {
|
|||||||
display.clear(TriColor::White);
|
display.clear(TriColor::White);
|
||||||
|
|
||||||
ctx.button_pressed = kbd.pressed();
|
ctx.button_pressed = kbd.pressed();
|
||||||
app.update(&ctx, &mut trng);
|
if !ctx.button_pressed.is_none() {
|
||||||
app.draw(&mut display);
|
app.update(&ctx, &mut trng);
|
||||||
|
app.draw(&mut display);
|
||||||
|
// TODO: try fast update?
|
||||||
|
driver.full_update(&display).unwrap();
|
||||||
|
}
|
||||||
|
|
||||||
// TODO: try fast update?
|
log::info!("Sleeping for 100ms...");
|
||||||
driver.full_update(&display).unwrap();
|
|
||||||
|
|
||||||
log::info!("Sleeping for 5s...");
|
|
||||||
driver.sleep().unwrap();
|
driver.sleep().unwrap();
|
||||||
delay.delay(5_000.millis());
|
delay.delay(100.millis());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user