Struct InterfaceAsync

Source
pub struct InterfaceAsync<I2C, Delay> { /* private fields */ }

Implementations§

Source§

impl<I2C, Delay> InterfaceAsync<I2C, Delay>
where I2C: I2c, Delay: DelayNs,

Source

pub fn new(i2cdev: I2C, delay: Delay) -> Self

Create async interface for wii-extension controller

Source

pub fn destroy(self) -> (I2C, Delay)

Destroy i2c interface, allowing recovery of i2c and delay

Trait Implementations§

Source§

impl<I2C: Debug, Delay: Debug> Debug for InterfaceAsync<I2C, Delay>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<I2C: Default, Delay: Default> Default for InterfaceAsync<I2C, Delay>

Source§

fn default() -> InterfaceAsync<I2C, Delay>

Returns the “default value” for a type. Read more
Source§

impl<I2C, Delay> Format for InterfaceAsync<I2C, Delay>
where I2C: Format, Delay: Format,

Source§

fn format(&self, f: Formatter<'_>)

Writes the defmt representation of self to fmt.

Auto Trait Implementations§

§

impl<I2C, Delay> Freeze for InterfaceAsync<I2C, Delay>
where I2C: Freeze, Delay: Freeze,

§

impl<I2C, Delay> RefUnwindSafe for InterfaceAsync<I2C, Delay>
where I2C: RefUnwindSafe, Delay: RefUnwindSafe,

§

impl<I2C, Delay> Send for InterfaceAsync<I2C, Delay>
where I2C: Send, Delay: Send,

§

impl<I2C, Delay> Sync for InterfaceAsync<I2C, Delay>
where I2C: Sync, Delay: Sync,

§

impl<I2C, Delay> Unpin for InterfaceAsync<I2C, Delay>
where I2C: Unpin, Delay: Unpin,

§

impl<I2C, Delay> UnwindSafe for InterfaceAsync<I2C, Delay>
where I2C: UnwindSafe, Delay: UnwindSafe,

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

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

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

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

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

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

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

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

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.