Skip to main content
MMevo.1
Associate II
Jan 5, 2022 3:40 PM UTC
Solved

Using ADC with DMA on H7 causes DMA transfer error

Hello,

I am trying to use circular DMA to transfer data from ADC1 into a buffer using CubeMX-generated code to configure the ADC and DMA. The DMA stream encounters a transfer error on transferring the first item.

The device is an STM32H743.

Using a debugger it can be seen that the program excute HAL_ADC_ConvCpltCallback()

and right after it gets to HAL_ADC_ErrorCallback()

Atatched are captures of the CubeMX configurations.

I assumes that it is related to anouther DMA isue that I am experincing with the I2C:

https://community.st.com/s/question/0D53W00001HbHIwSAN/stm32h743-i2c-dma-scl-stays-low-after-getting-slave-address-ack

Any Ideas?

This topic has been closed for replies.
MMevo.1
MMevo.1Best answer
Associate II
Jan 6, 2022 8:18 AM UTC

DMA was initialized after ADC and I2C...

After fixing the initilazation order the problem was solved.

Thanks a lot!

3 replies

TDK
Jan 5, 2022 3:54 PM UTC
"If you feel a post has answered your question, please click ""Accept as Solution""."
TDK
Jan 5, 2022 4:41 PM UTC
"If you feel a post has answered your question, please click ""Accept as Solution""."
MMevo.1
MMevo.1AuthorBest answer
Associate II
Jan 6, 2022 8:18 AM UTC

DMA was initialized after ADC and I2C...

After fixing the initilazation order the problem was solved.

Thanks a lot!