aboutsummaryrefslogtreecommitdiff
path: root/tests/stm32/src/bin/stop.rs
diff options
context:
space:
mode:
authorAdam Greig <[email protected]>2023-10-15 00:57:25 +0100
committerAdam Greig <[email protected]>2023-10-15 01:30:12 +0100
commit0621e957a0ddc7010d46b3ea3ddc8b9852bc8333 (patch)
treef6caefe939109e55a73e9141c736d2f6c20f51e8 /tests/stm32/src/bin/stop.rs
parent7559f9e5834799b041d899767ef4305dcfdf0181 (diff)
time: Update examples, tests, and other code to use new Timer::after_x convenience methods
Diffstat (limited to 'tests/stm32/src/bin/stop.rs')
-rw-r--r--tests/stm32/src/bin/stop.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/stm32/src/bin/stop.rs b/tests/stm32/src/bin/stop.rs
index 929869bc9..f38924c90 100644
--- a/tests/stm32/src/bin/stop.rs
+++ b/tests/stm32/src/bin/stop.rs
@@ -14,7 +14,7 @@ use embassy_stm32::low_power::{stop_with_rtc, Executor};
14use embassy_stm32::rcc::LsConfig; 14use embassy_stm32::rcc::LsConfig;
15use embassy_stm32::rtc::{Rtc, RtcConfig}; 15use embassy_stm32::rtc::{Rtc, RtcConfig};
16use embassy_stm32::Config; 16use embassy_stm32::Config;
17use embassy_time::{Duration, Timer}; 17use embassy_time::Timer;
18use static_cell::make_static; 18use static_cell::make_static;
19 19
20#[entry] 20#[entry]
@@ -28,7 +28,7 @@ fn main() -> ! {
28async fn task_1() { 28async fn task_1() {
29 for _ in 0..9 { 29 for _ in 0..9 {
30 info!("task 1: waiting for 500ms..."); 30 info!("task 1: waiting for 500ms...");
31 Timer::after(Duration::from_millis(500)).await; 31 Timer::after_millis(500).await;
32 } 32 }
33} 33}
34 34
@@ -36,7 +36,7 @@ async fn task_1() {
36async fn task_2() { 36async fn task_2() {
37 for _ in 0..5 { 37 for _ in 0..5 {
38 info!("task 2: waiting for 1000ms..."); 38 info!("task 2: waiting for 1000ms...");
39 Timer::after(Duration::from_millis(1000)).await; 39 Timer::after_millis(1000).await;
40 } 40 }
41 41
42 info!("Test OK"); 42 info!("Test OK");