I want to convert 4 analog input in the same time, I chose the stm32f3 discovery because it contains 4 ADCs. The problems is that I don't know how to get them working together. I have read that only two of them can work simultaneously ADC1 and ADC2, ADC3 and ADC4.

My question is what's configuration have I to do for this stuff?

Should I use DMA mode, if yes how ?

In the RM0316 reference manual of STM32F302xx, STM32F303xx and STM32F313xx advanced ARM-based 32-bit MCUs I found in the paragraph 12.8:

Dual ADC modes

In devices with two ADCs or more, dual ADC modes can be used (see Figure 69):

  • ADC1 and ADC2 can be used together in dual mode (ADC1 is master)
  • ADC3 and ADC4 can be used together in dual mode (ADC3 is master)

In dual ADC mode, the start of conversion is triggered alternately or simultaneously by the ADCx master to the ADC slave, depending on the mode selected by the bits DUAL[4:0] in the ADCx_CCR register.

Four possible modes are implemented:

  • Injected simultaneous mode
  • Regular simultaneous mode
  • Interleaved mode
  • Alternate trigger mode
  • \$\begingroup\$ Could you share a link to the datasheet you refer to, and where exactly you read that you can use only two ADCs at the same time? \$\endgroup\$
    – user17592
    Commented Sep 16, 2013 at 9:49
  • \$\begingroup\$ In the RM0316 reference manual \$\endgroup\$ Commented Sep 16, 2013 at 11:57
  • 1
    \$\begingroup\$ -1 I don't see a question here... \$\endgroup\$
    – Joe Hass
    Commented Sep 16, 2013 at 12:17
  • \$\begingroup\$ Sorry Joe, i'm newer to this forum and i don't understand what's going on with it. I posted a question in the stm32 section but it seems to be deleted. You don't need to vote -1 before knowing reasons... \$\endgroup\$ Commented Sep 16, 2013 at 12:47
  • \$\begingroup\$ Camil asks me to give him a link to datasheet that's why you see only the last part \$\endgroup\$ Commented Sep 16, 2013 at 12:48

1 Answer 1


It is not hard to understand:

  1. If you want to convert 4 channels at the same time, you need 4 independent ADCs. This means you should configure all of them separately in single mode.
  2. If you need to convert some channel using Dual ADC's mode, you need to configure two ADCs (ADC 1&2 or ADC 3&4) in appropriate mode. Note, you've got just 3 ADCs now: 2 single mode ones, and one dual mode ADC, made of 2.
  3. When you configure 2 Dual mode ADCs made of two each, you've got just 2 ADCs now.

All that you need are:

  1. Select appropriate mode, configure ADCs, make conversion(s), stop when you got enough.
  2. Select another, if needed, mode, configure ADCs, make conversion(s), stop when you got enough.
  3. Repeat until you got total satisfaction.

Another point: what is the Dual mode for?
The reasons are: MSPS increased, data reliability increased, in cost of lower quantity of ADCs left.

Another way: you can convert many ADC input channel at the "same time" using 1(!) ADC switching fast between these channels. You can calculate your needs depending of signal frequency on these channels. As frequency bigger, as more MSPS you need.

  • \$\begingroup\$ Actually, you just need 4 independent sample and holds. \$\endgroup\$ Commented Jul 14, 2015 at 15:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.