Trait I2cWrite

Source
pub trait I2cWrite: Debug {
    type Error;
    type Write: Write + Unpin;

    // Required method
    fn poll_begin_write(
        self: Pin<&mut Self>,
        cx: &mut Context<'_>,
        addr: u8,
    ) -> Poll<Result<Self::Write, Self::Error>>;
}
Expand description

A peripheral that can perform I²C write operations.

Required Associated Types§

Source

type Error

The common error type for I²C write operations.

A single error type for all operations is enforced for simplicity.

Source

type Write: Write + Unpin

An object that can be used to complete the write operation.

Required Methods§

Source

fn poll_begin_write( self: Pin<&mut Self>, cx: &mut Context<'_>, addr: u8, ) -> Poll<Result<Self::Write, Self::Error>>

Polls the start of a write operation to completion.

Implementors§