34.2.4.9 spi_m_dma_transfer

Perform the SPI data transfer (TX and RX) with the DMA.

int32_t spi_m_dma_transfer(
    struct spi_m_dma_descriptor * spi,
    uint8_t const * txbuf,
    uint8_t *const rxbuf,
    const uint16_t length
)

Parameters

spi

Type: struct spi_m_dma_descriptor Struct *

Pointer to the HAL SPI instance.

txbuf

Type: uint8_t const *

Pointer to the transfer information.

rxbuf

Type: uint8_t *const

Pointer to the receiver information.

length

Type: const uint16_t

SPI transfer data length.

Returns

Type: int32_t

Operation status.

ERR_NONE

Success.

ERR_BUSY

Busy.