File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 3
3
use crate :: peripheral:: { syst:: SystClkSource , SYST } ;
4
4
use embedded_hal:: blocking:: delay:: { DelayMs , DelayUs } ;
5
5
6
- /// System timer (SysTick) as a delay provider
6
+ /// System timer (SysTick) as a delay provider.
7
7
pub struct Delay {
8
8
syst : SYST ,
9
9
ahb_frequency : u32 ,
10
10
}
11
11
12
12
impl Delay {
13
- /// Configures the system timer (SysTick) as a delay provider
13
+ /// Configures the system timer (SysTick) as a delay provider.
14
14
///
15
- /// `ahb_frequency` is a frequency of the AHB bus in Hz
15
+ /// `ahb_frequency` is a frequency of the AHB bus in Hz.
16
16
#[ inline]
17
17
pub fn new ( mut syst : SYST , ahb_frequency : u32 ) -> Self {
18
18
syst. set_clock_source ( SystClkSource :: Core ) ;
19
19
20
20
Delay { syst, ahb_frequency }
21
21
}
22
22
23
- /// Releases the system timer (SysTick) resource
23
+ /// Releases the system timer (SysTick) resource.
24
24
#[ inline]
25
25
pub fn free ( self ) -> SYST {
26
26
self . syst
You can’t perform that action at this time.
0 commit comments