cancel
Showing results for 
Search instead for 
Did you mean: 

how to let SPI_fullDuplex_DMA_Slave runs continously using the HAL example

Ping1
Associate II

Dear all

I am trying to follow the exmaple https://github.com/STMicroelectronics/STM32CubeH5/tree/e6985112c824fce355638ef4e7113b1bc671f999/Projects/NUCLEO-H503RB/Examples/SPI/SPI_FullDuplex_ComDMA_Slave project with STM32H563 on my own target board, I copied most of the code/DMA setup form the example and got it working, however, my requirement is more complicated than the example, the example only receives and reply 1 message after a button press, but my application needs it to be able to receive/reply messages periodically, i.e. master keep sending fixed length of message and expect slave to reply with same length of message at a fixed period. For now, after I copied example, it runs receives/replies 1 message, which I see the data on bus , but then it ends up with busy state and never recovers even wait for a long time, could anyone help please? Also, the about the DMA setting, does it needs to be in circular mode? I am sort of new to STM32 and DMA. Any suggestion is appreciated.

Ping

0 REPLIES 0