cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L152xD: SPI+DMA transfer with IO trigger

keebler
Associate
Posted on October 14, 2013 at 15:49

I'm new to STM32 so please help 🙂

Is that possible to trigger SPI+DMA transfer from GPIO? I have RM0038 document and on ''DMA1 request mapping'' (page 213) diagram there are no GPIO pins. I assume that SPIx_RX and SPIx_TX are received/transmitted flags used to advance transfer but how can I trigger whole transaction?

I'd like to use /DATA_READY (active low) signal from external ADC to read data packet (14 bytes) by hardware.

#stm32l-dma-spi-trigger-gpio
2 REPLIES 2
Posted on October 14, 2013 at 16:11

You might be able to subvert a TIM input, but consider using an EXTI interrupt method first.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
keebler
Associate
Posted on October 15, 2013 at 08:56

Thank you for your answer. EXTI looks like a good solution especially if I would be able to use it as event driven trigger and not as interrupt source. And after reading the EXTI description I assume it is possible to generate events that way but I'm not sure (nothing in text about that) if it can trigger DMA. EXTI is not listed on ''Figure 34. DMA1 request mapping'' in RM0038. So maybe it is possible only by interrupt and software trigger in ISR?

Second option, if I get it right, is to use timer which overflows on each falling edge and triggers DMA transaction? And again, does it have to use interrupts or can be event driven?