diff --git a/examples/cancel-reschedule.rs b/examples/cancel-reschedule.rs index a38a9c4eae..7ab437f272 100644 --- a/examples/cancel-reschedule.rs +++ b/examples/cancel-reschedule.rs @@ -28,7 +28,7 @@ mod app { // Initialize the monotonic (SysTick rate in QEMU is 12 MHz) let mono = Systick::new(systick, 12_000_000); - hprintln!("init").ok(); + hprintln!("init"); // Schedule `foo` to run 1 second in the future foo::spawn_after(1.secs()).unwrap(); @@ -42,7 +42,7 @@ mod app { #[task] fn foo(_: foo::Context) { - hprintln!("foo").ok(); + hprintln!("foo"); // Schedule `bar` to run 2 seconds in the future (1 second after foo runs) let spawn_handle = baz::spawn_after(2.secs()).unwrap(); @@ -51,7 +51,7 @@ mod app { #[task] fn bar(_: bar::Context, baz_handle: baz::SpawnHandle, do_reschedule: bool) { - hprintln!("bar").ok(); + hprintln!("bar"); if do_reschedule { // Reschedule baz 2 seconds from now, instead of the original 1 second @@ -67,7 +67,7 @@ mod app { #[task] fn baz(_: baz::Context) { - hprintln!("baz").ok(); + hprintln!("baz"); debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator } } diff --git a/examples/common.rs b/examples/common.rs index 1fe671e61a..7dcc5421a9 100644 --- a/examples/common.rs +++ b/examples/common.rs @@ -73,7 +73,7 @@ mod app { // This task is only spawned once in `init`, hence this task will run // only once - hprintln!("foo").ok(); + hprintln!("foo"); } // Software task, also not bound to a hardware interrupt @@ -81,7 +81,7 @@ mod app { // The resources `s1` and `s2` are shared between all other tasks. #[task(shared = [s1, s2], local = [l2])] fn bar(_: bar::Context) { - hprintln!("bar").ok(); + hprintln!("bar"); // Run `bar` once per second bar::spawn_after(1.secs()).unwrap(); @@ -97,6 +97,6 @@ mod app { // Note that RTIC does NOT clear the interrupt flag, this is up to the // user - hprintln!("UART0 interrupt!").ok(); + hprintln!("UART0 interrupt!"); } } diff --git a/examples/complex.rs b/examples/complex.rs index 653198746b..742f9c7dc4 100644 --- a/examples/complex.rs +++ b/examples/complex.rs @@ -40,31 +40,31 @@ mod app { #[idle(shared = [s2, s3])] fn idle(mut cx: idle::Context) -> ! { - hprintln!("idle p0 started").ok(); + hprintln!("idle p0 started"); rtic::pend(Interrupt::GPIOC); cx.shared.s3.lock(|s| { - hprintln!("idle enter lock s3 {}", s).ok(); - hprintln!("idle pend t0").ok(); + hprintln!("idle enter lock s3 {}", s); + hprintln!("idle pend t0"); rtic::pend(Interrupt::GPIOA); // t0 p2, with shared ceiling 3 - hprintln!("idle pend t1").ok(); + hprintln!("idle pend t1"); rtic::pend(Interrupt::GPIOB); // t1 p3, with shared ceiling 3 - hprintln!("idle pend t2").ok(); + hprintln!("idle pend t2"); rtic::pend(Interrupt::GPIOC); // t2 p4, no sharing - hprintln!("idle still in lock s3 {}", s).ok(); + hprintln!("idle still in lock s3 {}", s); }); - hprintln!("\nback in idle").ok(); + hprintln!("\nback in idle"); cx.shared.s2.lock(|s| { - hprintln!("enter lock s2 {}", s).ok(); - hprintln!("idle pend t0").ok(); + hprintln!("enter lock s2 {}", s); + hprintln!("idle pend t0"); rtic::pend(Interrupt::GPIOA); // t0 p2, with shared ceiling 2 - hprintln!("idle pend t1").ok(); + hprintln!("idle pend t1"); rtic::pend(Interrupt::GPIOB); // t1 p3, no sharing - hprintln!("idle pend t2").ok(); + hprintln!("idle pend t2"); rtic::pend(Interrupt::GPIOC); // t2 p4, no sharing - hprintln!("idle still in lock s2 {}", s).ok(); + hprintln!("idle still in lock s2 {}", s); }); - hprintln!("\nidle exit").ok(); + hprintln!("\nidle exit"); debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator @@ -84,7 +84,7 @@ mod app { if *cx.local.times > 1 { "s" } else { "" } ) .ok(); - hprintln!("t0 p2 exit").ok(); + hprintln!("t0 p2 exit"); } #[task(binds = GPIOB, priority = 3, local = [times: u32 = 0], shared = [s3, s4])] @@ -100,15 +100,15 @@ mod app { .ok(); cx.shared.s4.lock(|s| { - hprintln!("t1 enter lock s4 {}", s).ok(); - hprintln!("t1 pend t0").ok(); + hprintln!("t1 enter lock s4 {}", s); + hprintln!("t1 pend t0"); rtic::pend(Interrupt::GPIOA); // t0 p2, with shared ceiling 2 - hprintln!("t1 pend t2").ok(); + hprintln!("t1 pend t2"); rtic::pend(Interrupt::GPIOC); // t2 p4, no sharing - hprintln!("t1 still in lock s4 {}", s).ok(); + hprintln!("t1 still in lock s4 {}", s); }); - hprintln!("t1 p3 exit").ok(); + hprintln!("t1 p3 exit"); } #[task(binds = GPIOC, priority = 4, local = [times: u32 = 0], shared = [s4])] @@ -124,9 +124,9 @@ mod app { .unwrap(); cx.shared.s4.lock(|s| { - hprintln!("enter lock s4 {}", s).ok(); + hprintln!("enter lock s4 {}", s); *s += 1; }); - hprintln!("t3 p4 exit").ok(); + hprintln!("t3 p4 exit"); } } diff --git a/examples/extern_binds.rs b/examples/extern_binds.rs index b6df2fb257..e445f4ecca 100644 --- a/examples/extern_binds.rs +++ b/examples/extern_binds.rs @@ -10,7 +10,7 @@ use panic_semihosting as _; // Free function implementing the interrupt bound task `foo`. fn foo(_: app::foo::Context) { - hprintln!("foo called").ok(); + hprintln!("foo called"); } #[rtic::app(device = lm3s6965)] diff --git a/examples/periodic-at.rs b/examples/periodic-at.rs index f9fd995fb0..1116210248 100644 --- a/examples/periodic-at.rs +++ b/examples/periodic-at.rs @@ -35,7 +35,7 @@ mod app { #[task(local = [cnt: u32 = 0])] fn foo(cx: foo::Context, instant: fugit::TimerInstantU64<100>) { - hprintln!("foo {:?}", instant).ok(); + hprintln!("foo {:?}", instant); *cx.local.cnt += 1; if *cx.local.cnt == 4 { diff --git a/examples/periodic-at2.rs b/examples/periodic-at2.rs index 879f709c65..35ebb52f5b 100644 --- a/examples/periodic-at2.rs +++ b/examples/periodic-at2.rs @@ -36,7 +36,7 @@ mod app { // Using the explicit type of the timer implementation #[task(local = [cnt: u32 = 0])] fn foo(cx: foo::Context, instant: fugit::TimerInstantU64<100>) { - hprintln!("foo {:?}", instant).ok(); + hprintln!("foo {:?}", instant); *cx.local.cnt += 1; if *cx.local.cnt == 4 { @@ -52,7 +52,7 @@ mod app { // This remains agnostic to the timer implementation #[task(local = [cnt: u32 = 0])] fn bar(_cx: bar::Context, instant: ::Instant) { - hprintln!("bar {:?}", instant).ok(); + hprintln!("bar {:?}", instant); // Spawn a new message with 1s offset to spawned time let next_instant = instant + 1.secs(); diff --git a/examples/periodic.rs b/examples/periodic.rs index 40c69257e7..5d66735c28 100644 --- a/examples/periodic.rs +++ b/examples/periodic.rs @@ -35,7 +35,7 @@ mod app { #[task(local = [cnt: u32 = 0])] fn foo(cx: foo::Context) { - hprintln!("foo").ok(); + hprintln!("foo"); *cx.local.cnt += 1; if *cx.local.cnt == 4 { diff --git a/examples/schedule.rs b/examples/schedule.rs index 5bad5a30ad..58e73dad18 100644 --- a/examples/schedule.rs +++ b/examples/schedule.rs @@ -28,7 +28,7 @@ mod app { // Initialize the monotonic (SysTick rate in QEMU is 12 MHz) let mono = Systick::new(systick, 12_000_000); - hprintln!("init").ok(); + hprintln!("init"); // Schedule `foo` to run 1 second in the future foo::spawn_after(1.secs()).unwrap(); @@ -42,7 +42,7 @@ mod app { #[task] fn foo(_: foo::Context) { - hprintln!("foo").ok(); + hprintln!("foo"); // Schedule `bar` to run 2 seconds in the future (1 second after foo runs) bar::spawn_after(1.secs()).unwrap(); @@ -50,7 +50,7 @@ mod app { #[task] fn bar(_: bar::Context) { - hprintln!("bar").ok(); + hprintln!("bar"); // Schedule `baz` to run 1 seconds from now, but with a specific time instant. baz::spawn_at(monotonics::now() + 1.secs()).unwrap(); @@ -58,7 +58,7 @@ mod app { #[task] fn baz(_: baz::Context) { - hprintln!("baz").ok(); + hprintln!("baz"); debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator } }