aboutsummaryrefslogtreecommitdiff
path: root/tests/stm32/src/bin/stop.rs
diff options
context:
space:
mode:
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 b9810673a..000296d46 100644
--- a/tests/stm32/src/bin/stop.rs
+++ b/tests/stm32/src/bin/stop.rs
@@ -2,7 +2,6 @@
2 2
3#![no_std] 3#![no_std]
4#![no_main] 4#![no_main]
5#![feature(type_alias_impl_trait)]
6#[path = "../common.rs"] 5#[path = "../common.rs"]
7mod common; 6mod common;
8 7
@@ -15,7 +14,7 @@ use embassy_stm32::rcc::LsConfig;
15use embassy_stm32::rtc::{Rtc, RtcConfig}; 14use embassy_stm32::rtc::{Rtc, RtcConfig};
16use embassy_stm32::Config; 15use embassy_stm32::Config;
17use embassy_time::Timer; 16use embassy_time::Timer;
18use static_cell::make_static; 17use static_cell::StaticCell;
19 18
20#[entry] 19#[entry]
21fn main() -> ! { 20fn main() -> ! {
@@ -64,7 +63,8 @@ async fn async_main(spawner: Spawner) {
64 63
65 rtc.set_datetime(now.into()).expect("datetime not set"); 64 rtc.set_datetime(now.into()).expect("datetime not set");
66 65
67 let rtc = make_static!(rtc); 66 static RTC: StaticCell<Rtc> = StaticCell::new();
67 let rtc = RTC.init(rtc);
68 68
69 stop_with_rtc(rtc); 69 stop_with_rtc(rtc);
70 70