AnsweredAssumed Answered

DMA triggered DMA

Question asked by herzog.richard on Mar 5, 2014
Latest reply on Mar 5, 2014 by herzog.richard
Hey everybody,

Is it somehow possible to start/enable/trigger a DMA transfer with the help of another DMA transfer? I'm thinking of the following scenario:

- DMA transfer 1 is timer triggered (every 1us) and transfers memory data to a GPIO data register, therefore creating a 1MHz bit pattern on the output pins (20 consecutive transfers)
- DMA transfer 2 is also timer triggered (every 1ms) and should retrigger DMA transfer 1, in order to repeat that bit pattern with a frequency of 1kHz.

What I know from the reference manual is that you should not configure a DMA stream while it is enabled. But I'm thinking of using DMA transfer 2 to write the SxNDTR (number of data) register of DMA transfer 1. Would this lead to any complications?
(btw: I know I could replace DMA transfer 2 by an interrupt.)

Thanks in advance for any replies,
Richard

Outcomes