Struct stm32l4x6_hal::timer::Timer
[−]
[src]
pub struct Timer<TIM> { /* fields omitted */ }
HW Timer
Methods
impl Timer<SYST>
[src]
pub fn syst<T: Into<Hertz>>(syst: SYST, timeout: T, clocks: Clocks) -> Self
[src]
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
impl Timer<TIM1>
[src]
pub fn tim1<T: Into<Hertz>>(
tim: TIM1,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM1>
[src]
tim: TIM1,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM1>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM1
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM8>
[src]
pub fn tim8<T: Into<Hertz>>(
tim: TIM8,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM8>
[src]
tim: TIM8,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM8>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM8
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM2>
[src]
pub fn tim2<T: Into<Hertz>>(
tim: TIM2,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM2>
[src]
tim: TIM2,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM2>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM2
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM3>
[src]
pub fn tim3<T: Into<Hertz>>(
tim: TIM3,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM3>
[src]
tim: TIM3,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM3>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM3
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM4>
[src]
pub fn tim4<T: Into<Hertz>>(
tim: TIM4,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM4>
[src]
tim: TIM4,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM4>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM4
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM5>
[src]
pub fn tim5<T: Into<Hertz>>(
tim: TIM5,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM5>
[src]
tim: TIM5,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM5>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM5
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM15>
[src]
pub fn tim15<T: Into<Hertz>>(
tim: TIM15,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM15>
[src]
tim: TIM15,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM15>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM15
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM16>
[src]
pub fn tim16<T: Into<Hertz>>(
tim: TIM16,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM16>
[src]
tim: TIM16,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM16>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM16
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM17>
[src]
pub fn tim17<T: Into<Hertz>>(
tim: TIM17,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM17>
[src]
tim: TIM17,
timeout: T,
clocks: Clocks,
apb: &mut APB2
) -> Timer<TIM17>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM17
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM6>
[src]
pub fn tim6<T: Into<Hertz>>(
tim: TIM6,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM6>
[src]
tim: TIM6,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM6>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM6
[src]
Paused timer and releases the TIM peripheral
impl Timer<TIM7>
[src]
pub fn tim7<T: Into<Hertz>>(
tim: TIM7,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM7>
[src]
tim: TIM7,
timeout: T,
clocks: Clocks,
apb: &mut APB1
) -> Timer<TIM7>
Creates new instance of timer.
pub fn subscribe(&mut self, event: Event)
[src]
Starts listening for an event
pub fn unsubscribe(&mut self, event: Event)
[src]
Stops listening for an event
pub fn reset_overflow(&mut self)
[src]
Resets SR's UIF register to clear status of overflow.
Unless reset is done, Interrupt handler is going to be continiously called.
pub fn free(self) -> TIM7
[src]
Paused timer and releases the TIM peripheral
Trait Implementations
impl CountDown for Timer<SYST>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Hertz>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM1>
[src]
impl CountDown for Timer<TIM1>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM8>
[src]
impl CountDown for Timer<TIM8>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM2>
[src]
impl CountDown for Timer<TIM2>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM3>
[src]
impl CountDown for Timer<TIM3>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM4>
[src]
impl CountDown for Timer<TIM4>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM5>
[src]
impl CountDown for Timer<TIM5>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM15>
[src]
impl CountDown for Timer<TIM15>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM16>
[src]
impl CountDown for Timer<TIM16>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM17>
[src]
impl CountDown for Timer<TIM17>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more
impl Periodic for Timer<TIM6>
[src]
impl CountDown for Timer<TIM6>
[src]
type Time = Hertz
The unit of time used by this timer
fn start<T: Into<Self::Time>>(&mut self, timeout: T)
[src]
Starts a new count down
fn wait(&mut self) -> Result<(), Void>
[src]
Non-blockingly "waits" until the count down finishes Read more