[][src]Struct freertos_rs::TimerBuilder

pub struct TimerBuilder<D: DurationTicks> { /* fields omitted */ }

Helper builder for a new software timer.


impl<D: DurationTicks> TimerBuilder<D>[src]

pub fn set_name(&mut self, name: &str) -> &mut Self[src]

Set the name of the timer.

pub fn set_period(&mut self, period: D) -> &mut Self[src]

Set the period of the timer.

pub fn set_auto_reload(&mut self, auto_reload: bool) -> &mut Self[src]

Should the timer be automatically reloaded?

pub fn create<F>(&self, callback: F) -> Result<Timer, FreeRtosError> where
    F: Fn(Timer),
    F: Send + 'static, 

Try to create the new timer.

Note that the newly created timer must be started.

Auto Trait Implementations

impl<D> Send for TimerBuilder<D> where
    D: Send

impl<D> Sync for TimerBuilder<D> where
    D: Sync

Blanket Implementations

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T> From<T> for T[src]

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized

impl<T> BorrowMut<T> for T where
    T: ?Sized

impl<T> Any for T where
    T: 'static + ?Sized