[][src]Struct atmega32u4_hal::delay::Delay

pub struct Delay<SPEED> { /* fields omitted */ }

A busy-loop delay implementation

Example

let mut delay = delay::Delay::<clock::MHz16>::new();

// Wait 1 second
delay.delay_ms(1000);

Warning

The delay is not accurate for values above 4095µs because of a loop whose overhead is not accounted for. This will be fixed in a future version.

Implementations

impl<SPEED> Delay<SPEED>[src]

pub fn new() -> Delay<SPEED>[src]

Trait Implementations

impl<SPEED> Clone for Delay<SPEED> where
    SPEED: Clone
[src]

impl<SPEED> Copy for Delay<SPEED> where
    SPEED: Copy
[src]

impl<SPEED> Debug for Delay<SPEED> where
    SPEED: Debug
[src]

impl<SPEED> DelayMs<u16> for Delay<SPEED> where
    Delay<SPEED>: DelayUs<u32>, 
[src]

impl<SPEED> DelayMs<u8> for Delay<SPEED> where
    Delay<SPEED>: DelayMs<u16>, 
[src]

impl DelayUs<u16> for Delay<MHz12>[src]

impl DelayUs<u16> for Delay<MHz20>[src]

impl DelayUs<u16> for Delay<MHz1>[src]

impl DelayUs<u16> for Delay<MHz24>[src]

impl DelayUs<u16> for Delay<MHz8>[src]

impl DelayUs<u16> for Delay<MHz16>[src]

impl<SPEED> DelayUs<u32> for Delay<SPEED> where
    Delay<SPEED>: DelayUs<u16>, 
[src]

impl<SPEED> DelayUs<u8> for Delay<SPEED> where
    Delay<SPEED>: DelayUs<u16>, 
[src]

Auto Trait Implementations

impl<SPEED> Send for Delay<SPEED> where
    SPEED: Send

impl<SPEED> Sync for Delay<SPEED> where
    SPEED: Sync

impl<SPEED> Unpin for Delay<SPEED> where
    SPEED: Unpin

Blanket Implementations

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

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

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

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.