diff options
| author | Dario Nieuwenhuis <[email protected]> | 2025-10-06 22:56:31 +0200 |
|---|---|---|
| committer | Dario Nieuwenhuis <[email protected]> | 2025-10-06 23:19:53 +0200 |
| commit | 8730a013c395cf0bf4c2fa8eeb7f138288103039 (patch) | |
| tree | 39eca5fbc4570bd0129c9a291f134de5dab98820 /embassy-stm32/src/rtc | |
| parent | abc8e450f936567ad42cb34b5d2a7941b206aa5d (diff) | |
Rustfmt for edition 2024.
Diffstat (limited to 'embassy-stm32/src/rtc')
| -rw-r--r-- | embassy-stm32/src/rtc/low_power.rs | 2 | ||||
| -rw-r--r-- | embassy-stm32/src/rtc/mod.rs | 8 | ||||
| -rw-r--r-- | embassy-stm32/src/rtc/v3.rs | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/embassy-stm32/src/rtc/low_power.rs b/embassy-stm32/src/rtc/low_power.rs index a81ac6746..999f24714 100644 --- a/embassy-stm32/src/rtc/low_power.rs +++ b/embassy-stm32/src/rtc/low_power.rs | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | #[cfg(feature = "time")] | 1 | #[cfg(feature = "time")] |
| 2 | use embassy_time::{Duration, TICK_HZ}; | 2 | use embassy_time::{Duration, TICK_HZ}; |
| 3 | 3 | ||
| 4 | use super::{bcd2_to_byte, DateTimeError, Rtc, RtcError}; | 4 | use super::{DateTimeError, Rtc, RtcError, bcd2_to_byte}; |
| 5 | use crate::interrupt::typelevel::Interrupt; | 5 | use crate::interrupt::typelevel::Interrupt; |
| 6 | use crate::peripherals::RTC; | 6 | use crate::peripherals::RTC; |
| 7 | use crate::rtc::SealedInstance; | 7 | use crate::rtc::SealedInstance; |
diff --git a/embassy-stm32/src/rtc/mod.rs b/embassy-stm32/src/rtc/mod.rs index 92dec0960..bc6df528b 100644 --- a/embassy-stm32/src/rtc/mod.rs +++ b/embassy-stm32/src/rtc/mod.rs | |||
| @@ -8,12 +8,12 @@ mod low_power; | |||
| 8 | use core::cell::Cell; | 8 | use core::cell::Cell; |
| 9 | 9 | ||
| 10 | #[cfg(feature = "low-power")] | 10 | #[cfg(feature = "low-power")] |
| 11 | use embassy_sync::blocking_mutex::raw::CriticalSectionRawMutex; | ||
| 12 | #[cfg(feature = "low-power")] | ||
| 13 | use embassy_sync::blocking_mutex::Mutex; | 11 | use embassy_sync::blocking_mutex::Mutex; |
| 12 | #[cfg(feature = "low-power")] | ||
| 13 | use embassy_sync::blocking_mutex::raw::CriticalSectionRawMutex; | ||
| 14 | 14 | ||
| 15 | use self::datetime::{day_of_week_from_u8, day_of_week_to_u8}; | ||
| 16 | pub use self::datetime::{DateTime, DayOfWeek, Error as DateTimeError}; | 15 | pub use self::datetime::{DateTime, DayOfWeek, Error as DateTimeError}; |
| 16 | use self::datetime::{day_of_week_from_u8, day_of_week_to_u8}; | ||
| 17 | use crate::pac::rtc::regs::{Dr, Tr}; | 17 | use crate::pac::rtc::regs::{Dr, Tr}; |
| 18 | use crate::time::Hertz; | 18 | use crate::time::Hertz; |
| 19 | 19 | ||
| @@ -25,8 +25,8 @@ mod _version; | |||
| 25 | #[allow(unused_imports)] | 25 | #[allow(unused_imports)] |
| 26 | pub use _version::*; | 26 | pub use _version::*; |
| 27 | 27 | ||
| 28 | use crate::peripherals::RTC; | ||
| 29 | use crate::Peri; | 28 | use crate::Peri; |
| 29 | use crate::peripherals::RTC; | ||
| 30 | 30 | ||
| 31 | /// Errors that can occur on methods on [RtcClock] | 31 | /// Errors that can occur on methods on [RtcClock] |
| 32 | #[non_exhaustive] | 32 | #[non_exhaustive] |
diff --git a/embassy-stm32/src/rtc/v3.rs b/embassy-stm32/src/rtc/v3.rs index d0b52049e..01da5d70a 100644 --- a/embassy-stm32/src/rtc/v3.rs +++ b/embassy-stm32/src/rtc/v3.rs | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | use stm32_metapac::rtc::vals::{Calp, Calw16, Calw8, Fmt, Key, Osel, Pol, TampalrmType}; | 1 | use stm32_metapac::rtc::vals::{Calp, Calw8, Calw16, Fmt, Key, Osel, Pol, TampalrmType}; |
| 2 | 2 | ||
| 3 | use super::RtcCalibrationCyclePeriod; | 3 | use super::RtcCalibrationCyclePeriod; |
| 4 | use crate::pac::rtc::Rtc; | 4 | use crate::pac::rtc::Rtc; |
