From ca1e48659ca6541588b3b63329c28bc299da8f5d Mon Sep 17 00:00:00 2001 From: Ashcon Mohseninia Date: Mon, 6 Jan 2025 09:26:52 +0000 Subject: [PATCH] Cargo fmt --- hal/src/delay.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/hal/src/delay.rs b/hal/src/delay.rs index 35591260280..e3bb65d6e32 100644 --- a/hal/src/delay.rs +++ b/hal/src/delay.rs @@ -13,9 +13,7 @@ use crate::time::Hertz; use crate::typelevel::Increment; #[hal_cfg("rtc-d5x")] -use crate::clock::v2::{ - Source, gclk::Gclk0Id -}; +use crate::clock::v2::{gclk::Gclk0Id, Source}; /// System timer (SysTick) as a delay provider pub struct Delay { @@ -38,14 +36,16 @@ impl Delay { /// Configures the system timer (SysTick) as a delay provide, compatible /// with the V2 clocking API pub fn new_with_source(mut syst: SYST, gclk0: S) -> (Self, S::Inc) - where S: Source + Increment { + where + S: Source + Increment, + { syst.set_clock_source(SystClkSource::Core); ( Delay { syst, sysclock: gclk0.freq(), }, - gclk0.inc() + gclk0.inc(), ) }