Struct rust_hdl::widgets::spi_slave::SPISlave[][src]

pub struct SPISlave<const N: usize> {
Show 13 fields pub clock: Signal<In, Clock>, pub mosi: Signal<In, Bit>, pub miso: Signal<Out, Bit>, pub msel: Signal<In, Bit>, pub mclk: Signal<In, Bit>, pub disabled: Signal<In, Bit>, pub busy: Signal<Out, Bit>, pub data_inbound: Signal<Out, Bits<N>>, pub start_send: Signal<In, Bit>, pub data_outbound: Signal<In, Bits<N>>, pub bits: Signal<In, Bits<16>>, pub continued_transaction: Signal<In, Bit>, pub transfer_done: Signal<Out, Bit>, // some fields omitted
}

Fields

clock: Signal<In, Clock>mosi: Signal<In, Bit>miso: Signal<Out, Bit>msel: Signal<In, Bit>mclk: Signal<In, Bit>disabled: Signal<In, Bit>busy: Signal<Out, Bit>data_inbound: Signal<Out, Bits<N>>start_send: Signal<In, Bit>data_outbound: Signal<In, Bits<N>>bits: Signal<In, Bits<16>>continued_transaction: Signal<In, Bit>transfer_done: Signal<Out, Bit>

Implementations

Here is a table of the SPI setup: CPOL CPHA EDGE ACTION 0 0 R Sample 0 0 F Change 0 1 R Change 0 1 F Sample 1 0 R Change 1 0 F Sample 1 1 R Sample 1 1 F Change

So Sample on Rising edge if CPOL == CPHA Also, CPHA decides if we start in the sample state or in the change state

Trait Implementations

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.