Struct stm32f0x0_hal::timer::Timer [−][src]
pub struct Timer<TIM> { /* fields omitted */ }
Hardware timers
Methods
impl Timer<TIM3>
[src]
impl Timer<TIM3>
pub fn tim3<T>(tim: TIM3, timeout: T, clocks: Clocks, apb: &mut APB1) -> Self where
T: Into<Hertz>,
[src]
pub fn tim3<T>(tim: TIM3, timeout: T, clocks: Clocks, apb: &mut APB1) -> Self where
T: Into<Hertz>,
Configures a TIM peripheral as a periodic count down timer
pub fn listen(&mut self, event: Event)
[src]
pub fn listen(&mut self, event: Event)
Starts listening for an event
pub fn unlisten(&mut self, event: Event)
[src]
pub fn unlisten(&mut self, event: Event)
Stops listening for an event
pub fn free(self) -> TIM3
[src]
pub fn free(self) -> TIM3
Releases the TIM peripheral
impl Timer<TIM6>
[src]
impl Timer<TIM6>
pub fn tim6<T>(tim: TIM6, timeout: T, clocks: Clocks, apb: &mut APB1) -> Self where
T: Into<Hertz>,
[src]
pub fn tim6<T>(tim: TIM6, timeout: T, clocks: Clocks, apb: &mut APB1) -> Self where
T: Into<Hertz>,
Configures a TIM peripheral as a periodic count down timer
pub fn listen(&mut self, event: Event)
[src]
pub fn listen(&mut self, event: Event)
Starts listening for an event
pub fn unlisten(&mut self, event: Event)
[src]
pub fn unlisten(&mut self, event: Event)
Stops listening for an event
pub fn free(self) -> TIM6
[src]
pub fn free(self) -> TIM6
Releases the TIM peripheral
impl Timer<TIM7>
[src]
impl Timer<TIM7>
pub fn tim7<T>(tim: TIM7, timeout: T, clocks: Clocks, apb: &mut APB1) -> Self where
T: Into<Hertz>,
[src]
pub fn tim7<T>(tim: TIM7, timeout: T, clocks: Clocks, apb: &mut APB1) -> Self where
T: Into<Hertz>,
Configures a TIM peripheral as a periodic count down timer
pub fn listen(&mut self, event: Event)
[src]
pub fn listen(&mut self, event: Event)
Starts listening for an event
pub fn unlisten(&mut self, event: Event)
[src]
pub fn unlisten(&mut self, event: Event)
Stops listening for an event
pub fn free(self) -> TIM7
[src]
pub fn free(self) -> TIM7
Releases the TIM peripheral
impl Timer<TIM14>
[src]
impl Timer<TIM14>
pub fn tim14<T>(tim: TIM14, timeout: T, clocks: Clocks, apb: &mut APB1) -> Self where
T: Into<Hertz>,
[src]
pub fn tim14<T>(tim: TIM14, timeout: T, clocks: Clocks, apb: &mut APB1) -> Self where
T: Into<Hertz>,
Configures a TIM peripheral as a periodic count down timer
pub fn listen(&mut self, event: Event)
[src]
pub fn listen(&mut self, event: Event)
Starts listening for an event
pub fn unlisten(&mut self, event: Event)
[src]
pub fn unlisten(&mut self, event: Event)
Stops listening for an event
pub fn free(self) -> TIM14
[src]
pub fn free(self) -> TIM14
Releases the TIM peripheral
impl Timer<TIM15>
[src]
impl Timer<TIM15>
pub fn tim15<T>(tim: TIM15, timeout: T, clocks: Clocks, apb: &mut APB2) -> Self where
T: Into<Hertz>,
[src]
pub fn tim15<T>(tim: TIM15, timeout: T, clocks: Clocks, apb: &mut APB2) -> Self where
T: Into<Hertz>,
Configures a TIM peripheral as a periodic count down timer
pub fn listen(&mut self, event: Event)
[src]
pub fn listen(&mut self, event: Event)
Starts listening for an event
pub fn unlisten(&mut self, event: Event)
[src]
pub fn unlisten(&mut self, event: Event)
Stops listening for an event
pub fn free(self) -> TIM15
[src]
pub fn free(self) -> TIM15
Releases the TIM peripheral
impl Timer<TIM16>
[src]
impl Timer<TIM16>
pub fn tim16<T>(tim: TIM16, timeout: T, clocks: Clocks, apb: &mut APB2) -> Self where
T: Into<Hertz>,
[src]
pub fn tim16<T>(tim: TIM16, timeout: T, clocks: Clocks, apb: &mut APB2) -> Self where
T: Into<Hertz>,
Configures a TIM peripheral as a periodic count down timer
pub fn listen(&mut self, event: Event)
[src]
pub fn listen(&mut self, event: Event)
Starts listening for an event
pub fn unlisten(&mut self, event: Event)
[src]
pub fn unlisten(&mut self, event: Event)
Stops listening for an event
pub fn free(self) -> TIM16
[src]
pub fn free(self) -> TIM16
Releases the TIM peripheral
impl Timer<TIM17>
[src]
impl Timer<TIM17>
pub fn tim17<T>(tim: TIM17, timeout: T, clocks: Clocks, apb: &mut APB2) -> Self where
T: Into<Hertz>,
[src]
pub fn tim17<T>(tim: TIM17, timeout: T, clocks: Clocks, apb: &mut APB2) -> Self where
T: Into<Hertz>,
Configures a TIM peripheral as a periodic count down timer
pub fn listen(&mut self, event: Event)
[src]
pub fn listen(&mut self, event: Event)
Starts listening for an event
pub fn unlisten(&mut self, event: Event)
[src]
pub fn unlisten(&mut self, event: Event)
Stops listening for an event
pub fn free(self) -> TIM17
[src]
pub fn free(self) -> TIM17
Releases the TIM peripheral
Trait Implementations
impl Periodic for Timer<TIM3>
[src]
impl Periodic for Timer<TIM3>
impl CountDown for Timer<TIM3>
[src]
impl CountDown for Timer<TIM3>
type Time = Hertz
The unit of time used by this timer
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
[src]
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
Starts a new count down
fn wait(&mut self) -> Result<(), !>
[src]
fn wait(&mut self) -> Result<(), !>
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM6>
[src]
impl Periodic for Timer<TIM6>
impl CountDown for Timer<TIM6>
[src]
impl CountDown for Timer<TIM6>
type Time = Hertz
The unit of time used by this timer
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
[src]
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
Starts a new count down
fn wait(&mut self) -> Result<(), !>
[src]
fn wait(&mut self) -> Result<(), !>
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM7>
[src]
impl Periodic for Timer<TIM7>
impl CountDown for Timer<TIM7>
[src]
impl CountDown for Timer<TIM7>
type Time = Hertz
The unit of time used by this timer
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
[src]
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
Starts a new count down
fn wait(&mut self) -> Result<(), !>
[src]
fn wait(&mut self) -> Result<(), !>
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM14>
[src]
impl Periodic for Timer<TIM14>
impl CountDown for Timer<TIM14>
[src]
impl CountDown for Timer<TIM14>
type Time = Hertz
The unit of time used by this timer
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
[src]
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
Starts a new count down
fn wait(&mut self) -> Result<(), !>
[src]
fn wait(&mut self) -> Result<(), !>
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM15>
[src]
impl Periodic for Timer<TIM15>
impl CountDown for Timer<TIM15>
[src]
impl CountDown for Timer<TIM15>
type Time = Hertz
The unit of time used by this timer
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
[src]
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
Starts a new count down
fn wait(&mut self) -> Result<(), !>
[src]
fn wait(&mut self) -> Result<(), !>
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM16>
[src]
impl Periodic for Timer<TIM16>
impl CountDown for Timer<TIM16>
[src]
impl CountDown for Timer<TIM16>
type Time = Hertz
The unit of time used by this timer
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
[src]
fn start<T>(&mut self, timeout: T) where
T: Into<Hertz>,
Starts a new count down
fn wait(&mut self) -> Result<(), !>
[src]
fn wait(&mut self) -> Result<(), !>
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM17>
[src]
impl Periodic for Timer<TIM17>
impl CountDown for Timer<TIM17>
[src]
impl CountDown for Timer<TIM17>