More consistent error handling in loops

This commit is contained in:
2024-08-24 10:56:05 -04:00
parent 70947d5fa7
commit ee334db157
7 changed files with 23 additions and 40 deletions

View File

@ -217,7 +217,7 @@ pub async fn start_cli(dispatch: Sender<Commands>) -> anyhow::Result<()> {
let mut buf = [0_u8; 1];
let mut async_timer = timer_service.timer_async()?;
loop {
async_timer.after(Duration::from_millis(SLEEP_TIME_MS)).await?;
async_timer.after(Duration::from_millis(SLEEP_TIME_MS)).await?; // no need to panic on test console driver timer failure
match reader.read_exact(&mut buf) {
Ok(_) => {
//cli.process_byte::<Menu, _>(buf[0], &mut Menu::processor(process_menu))?;