Skip to main content
rsharifi9
Associate III
August 25, 2019
Question

is it possible to configure three ADCs of the STM32F4, ADC1 and ADC2 in dual interleaved and ADC3 independent?

  • August 25, 2019
  • 3 replies
  • 1197 views

Dear All,

Please consider STM32F407. I tried to configured its three ADCs: ADC1 and ADC2 in dual intereleved and ADC3 in independent mode using CubeMX. BUT it is impossibe the job using that. Is it possible to moddify the CubeMX's generated code to work correctly? How can I do the project?

Regards, Rasool

This topic has been closed for replies.

3 replies

Tesla DeLorean
Guru
August 25, 2019

I suspect it is possible, perhaps look at the HAL examples and adapt. Start with a Dual example, then fire up ADC3

For F4 I would have used the SPL

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
RShar.17
Associate II
August 26, 2019

I initilize the ADC in dual mode and independent mode separately but i don't have success in my application.

I think, there is no basically difference between my code and the one generated with CubeMX though both of them are based on HAL library.

What is the true initialization for these ADCs?

Ozone
Principal
August 26, 2019

To be blunt, Cube often fails miserably for non-standard use cases. Don't put your trust in such auto-generated code.

You can either check check the Cube output and look for errors, or use your own code based on the reference manuals.

I don't know any reason why your setup should not work.

I always used the ADC independantly, though.

rsharifi9
rsharifi9Author
Associate III
August 26, 2019