From 5f9602d28bdac06f5f2fbfa2c49cd98d689f4c37 Mon Sep 17 00:00:00 2001 From: "Andres O. Vela" Date: Tue, 31 Oct 2023 22:48:52 +0100 Subject: [PATCH] time: fix MockDriver::now() --- embassy-time/src/driver_mock.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/embassy-time/src/driver_mock.rs b/embassy-time/src/driver_mock.rs index becb6bfd..c255615c 100644 --- a/embassy-time/src/driver_mock.rs +++ b/embassy-time/src/driver_mock.rs @@ -51,7 +51,7 @@ impl MockDriver { impl Driver for MockDriver { fn now(&self) -> u64 { - critical_section::with(|cs| self.now.borrow(cs).get().as_micros() as u64) + critical_section::with(|cs| self.now.borrow(cs).get().as_ticks() as u64) } unsafe fn allocate_alarm(&self) -> Option {