AnsweredAssumed Answered

SPI Communications with DMA

Question asked by Stuart on Apr 17, 2012
Latest reply on Apr 18, 2012 by Stuart
Hi,
I've a complicated application with 3 STM32F1xx microcontrollers.
Each of the microcontrollers communicate to each other via SPI. DMA is used for SPI communications.
The micros (STM32F103) have 2 SPI ports each.
One micro is SPI slave on SPI1 (to another micro) and also master on SPI2 (to another micro). Thus, it is using both SPI ports with DMA.
I have noticed that, independently, SPI communications (using DMA) on SPI1 and SPI2 works OK (no corruption). However, when SPI1 and SPI2 are in use at the same time (which happens occasionally in my application), I have noticed that some of the messages get corrupted (looks like DMA problems). It appears as if the DMA cannot cope with both SPI ports in use at the same time. Maybe the DMA arbiter is overloaded? Is it a question of DMA priorities?
Does anyone know whether there is an issue with DMA, using both channels at the same time with DMA?
Any answers would be most appreciated.
Stuart

Outcomes