From 1a0be47d0517586f20c1171877671a9313a796b9 Mon Sep 17 00:00:00 2001 From: Sean Cross Date: Wed, 11 Nov 2020 16:06:39 +0800 Subject: [PATCH] shell: add loop number to msleep This allows us to trace the loop number through the syscall. Signed-off-by: Sean Cross --- services/shell/src/main.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/services/shell/src/main.rs b/services/shell/src/main.rs index d2c940260..80746b54a 100644 --- a/services/shell/src/main.rs +++ b/services/shell/src/main.rs @@ -42,6 +42,7 @@ fn ensure_connection(server: xous::SID) -> xous::CID { fn shell_main() -> ! { timer::init(); log_server::init_wait().unwrap(); + let mut loops = 0; // let log_server_id = xous::SID::from_bytes(b"xous-logs-output").unwrap(); let graphics_server_id = xous::SID::from_bytes(b"graphics-server ").unwrap(); @@ -150,5 +151,8 @@ fn shell_main() -> ! { info!("drawing string: {}", string_buffer); graphics_server::draw_string(graphics_conn, &string_buffer).expect("unable to draw string"); graphics_server::flush(graphics_conn).expect("unable to draw to screen"); + + ticktimer_server::sleep_ms(ticktimer_conn, 2000 + loops).expect("couldn't sleep"); + loops += 1; } }