Skip to main content
Visitor II
January 12, 2024
Question

Single ADC Reading with Multiple DMA Channels

  • January 12, 2024
  • 2 replies
  • 1250 views

Hi,

Is it possible to have a single ADC result transferred to two different memory locations using DMA without CPU intervention?

Specifically I want DMA to take a single reading from an ADC, transfer it to one location on the STM32H747 CM4 and another location on the STM32H747 CM7. 

Thanks!

    This topic has been closed for replies.

    2 replies

    Super User
    January 12, 2024

    Not really, at least not directly. You can't select the same trigger for multiple DMAMUX channels.

    But you could run something at the same time and use that as a trigger proxy. Like running ADC2 in lock-step with ADC1 and using the ADC2 trigger to move ADC1 data.

    slc2015Author
    Visitor II
    January 13, 2024

    Really all I want to do is be able to buffer data from a single ADC input in memory and do some math on each sample in real time. Ideally I'd have the CM7 receive the buffered data through DMA and the CM4 does the math on each sample in real time -- off of the EOC flag.

    Is it possible to have 2 ADCs convert the same pins at the same time without ill-effect? For example CM7 samples from ADC3 and CM4 samples with ADC1 off of the same timer output? If so, my problem is solved. 

    Super User
    January 13, 2024

    I doubt it. But again, you can achieve the same effect by having ADC2 convert a dummy channel as outlined in my last post. That gets you the functionality you need. Store it in a buffer location that both cores can access, which is most memory.