pub struct SPI { /* private fields */ }Expand description
SPI peripheral control
Implementations§
Methods from Deref<Target = RegisterBlock>§
Sourcepub fn dr0(&self) -> &Reg<DR0_SPEC>
pub fn dr0(&self) -> &Reg<DR0_SPEC>
0x00 - The SPI Master data register is a 16-bit read/write buffer for the transmit/receive FIFOs. When the register is read, data in the receive FIFO buffer is accessed. When it is written to, data are moved into the transmit FIFO buffer; a write can occur only when SSI_EN = 1. FIFOs are reset when SSI_EN = 0. Please refer to SSIENR register (0x008) to enable and disable the SPI Master. The DR register in the SPI Master occupies 131(for TX)/8(for RX) 32-bit address locations of the memory map to facilitate AHB burst transfers. Writing to any of these address locations has the same effect as pushing the data from the pwdata bus into the transmit FIFO. Reading from any of these locations has the same effect as popping data from the receive FIFO onto the prdata bus. The FIFO buffers on the SPI Master are not addressable.
Sourcepub fn ctrlr0(&self) -> &Reg<CTRLR0_SPEC>
pub fn ctrlr0(&self) -> &Reg<CTRLR0_SPEC>
0x00 - Control Register 0: This register controls the serial data transfer. It is impossible to write to this register when the SPI Master is enabled. The SPI Master is enabled and disabled by writing to the SSIENR register (0x008).