Transaction

Type Alias Transaction 

Source
pub type Transaction<'a> = Operation<'a, u8>;
Expand description

Transaction enum defines possible SPI transactions Re-exported from embedded-hal

Aliased Type§

pub enum Transaction<'a> {
    Read(&'a mut [u8]),
    Write(&'a [u8]),
    Transfer(&'a mut [u8], &'a [u8]),
    TransferInPlace(&'a mut [u8]),
    DelayNs(u32),
}

Variants§

§

Read(&'a mut [u8])

Read data into the provided buffer.

Equivalent to [SpiBus::read].

§

Write(&'a [u8])

Write data from the provided buffer, discarding read data.

Equivalent to [SpiBus::write].

§

Transfer(&'a mut [u8], &'a [u8])

Read data into the first buffer, while writing data from the second buffer.

Equivalent to [SpiBus::transfer].

§

TransferInPlace(&'a mut [u8])

Write data out while reading data into the provided buffer.

Equivalent to [SpiBus::transfer_in_place].

§

DelayNs(u32)

Delay for at least the specified number of nanoseconds.