SPI with circular mode DMA

I’d like to use circular mode dma to control data transfers over an SPI interface.
If I want to send twice “RSL10 SPI TEST” over an SPI interface using circular mode dma, what should I do using ‘spi_cmsis_driver’ ?

I changed dma mode configuration from single to repeat in RTE_Device.h and SPI_Control() of SPI_RSLxx.c.
And I added counter function in SPI_TX_DMAHandler and SPI_RX_DMAHandler to stop dma after sending data two cycles.
After reset, only first time worked correctly. After that it sent data which was added 0x00 before ‘R’ only one cycle.
Please give me advice.

Best Regards.

I’m sorry. I noticed my mistake.
RSL10 worked well by correcting it.

Best regards.

1 Like

@Zach Happy that your application is working. Thank you for using our community forum.

Hi Zach, how you managed to solve the issue? ON a logic analyser I see there is an extra byte 0x00 send before actual content, and HAL_SPI goes to an infinite loop checking for busy flag.

I am using SPI_RSLxx CMSIS driver, DMA enabled on channel 6,7