cancel
Showing results for 
Search instead for 
Did you mean: 

STM32H745 Transferring data from peripherals (ADC-1/2/3) using DMA/BDMA/MDMA to Core-M7

Madhan
Associate II

I have transferred data from ADC-1/2/3 to M4, but i am unsure about how to transfer it to M7. There doesn't seem to be any reference anywhere. So if i want to do a DMA transfer from ADC-1/2 to M7, how should it be done ?

2 REPLIES 2
berendi
Principal

Examples for the STM32H743/H753/H750 would apply, because they are basically the same as the STM32H745 minus the M4 core (and some differences not relevant to ADC/DMA).

You can do it more or less the same way as you did it on the M4. Data is not actually transferred to the core, but to some on-chip memory which can be accessed by both cores.

Things to watch out for.

  • Do not modify the same peripheral register from both cores at once. Exception: clearing interrupts through DMA_LIFCR/DMA_HIFCR is fine.
  • Transferring data directly to DTCM does not work. Allocate the data buffer in one of the on-chip SRAM areas.
  • Manage the L1 cache properly. Either disable caching of the DMA buffer, or invalidate the buffer area in the data cache (watch out for buggy implementations in libraries and elsewhere)
RMcCa
Senior II

Can't you use the MDMA to transfer data from D2 SRAM into the M7 DTCM? It is my understanding the M4 can start the MDMA which can then interrupt the M7 when the transfer is complete​. There are also hardware semaphones that can be used signal back and forth between the processors.