cancel
Showing results for 
Search instead for 
Did you mean: 

STM32H725 problems with ADC IRQ handler in regular simultaneos mode

Bogdan
Senior

Hello,

i am porting a relative old project which uses std hal lib v1.06 from stm32h750.

Due to the market shortage, i am migrating this project to stm32h725igk6 ( bga version).

The project is compiled trough CubeIDE with latest hal libraries ( v1.11).

The adc uses adc1-ch3 and adc2-ch5 in regular simultaneous mode with DMA.

External bypass oscilator of 25mhz is used,

ADC clock is coming from PLL2 at 88MHZ, and divided by 4, to obtain a 2msps.

The project itself uses alot of complex math, and it was originaly created under unix.

After porting the code to cubeide, there are no compile errors.

However i noticed the. function HAL_ADC_IRQHandler its never triggerd, and i wonder why?

Both NVIC for ADC and DMA are enabled.

By the way, what is the dma stream for reading ADC1 data register? is it DMA1 stream 1?

I ask this because i have alot of hard time figuring all the data from the reference manual, and cubemx when generating the project does not autofill this

I already spent 2 days on this, trying to export the code even in EWARM, but with the same result

ADC1 - master

ADC2 - slave

void ADC_IRQHandler(void)

{

  HAL_ADC_IRQHandler(&AdcHandle_master);

  HAL_ADC_IRQHandler(&AdcHandle_slave);

}

void DMA1_Stream1_IRQHandler(void)

{

  HAL_DMA_IRQHandler(AdcHandle_master.DMA_Handle); // this gets triggered

 }

1 ACCEPTED SOLUTION

Accepted Solutions
FBL
ST Employee

Hello @Bogdan​ ,

You may refer to the RM0468 under subsection Block interconnect, you can find the DMA streams related to ADCs used.0693W00000aJ8XPQA0.png 

You can try debugging the code to see if the ADC conversion is completing. Then check the ADC and DMA configurations. You may start with a simple example of single ADC. You can get inspired with this example based on Nucleo H743.

STM32CubeH7/Projects/NUCLEO-H743ZI/Examples/ADC/ADC_DMA_Transfer at master · STMicroelectronics/STM32CubeH7 (github.com)

Then, you can add the second instance of ADC manually and test it.

Hope it works!

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

View solution in original post

2 REPLIES 2
FBL
ST Employee

Hello @Bogdan​ ,

You may refer to the RM0468 under subsection Block interconnect, you can find the DMA streams related to ADCs used.0693W00000aJ8XPQA0.png 

You can try debugging the code to see if the ADC conversion is completing. Then check the ADC and DMA configurations. You may start with a simple example of single ADC. You can get inspired with this example based on Nucleo H743.

STM32CubeH7/Projects/NUCLEO-H743ZI/Examples/ADC/ADC_DMA_Transfer at master · STMicroelectronics/STM32CubeH7 (github.com)

Then, you can add the second instance of ADC manually and test it.

Hope it works!

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Bogdan
Senior

Hello,

thanks for sharing this info.

So by judging from your picture, in my case for ADC1, this would be DMA1 Stream 9 ?