AnsweredAssumed Answered

ADC dual slow interleaved mode

Question asked by Holfert.Jan on Oct 31, 2014
Dear all,

for my application on an STM32F205x the ADC dual slow interleaved mode is the most suitable mode for sampling an analogue signal.

In AN3116 both the fast and slow interleaved modes are described. Additionally, my used setup for ADC1, ADC2 and DMA is very close to the configuration shown in the Dual Interleaved mode example shipped with the STM32 Cube F2 and F4 libraries.

My application and the example differ as follows:
       
  1. The start of the sampling (ADC1) is triggered by TIM2.
  2.    
  3. DMA is configured to transfer 100 conversions and then stop the sampling.
  4.    
  5. 3 clocks ADC sampling, 12 clocks conversion, 14 clocks delay between ADC1 and ADC2

Unfortunately, I face the following issues:
       
  1. Every second value transfered by the DMA is zero.
  2.    
  3. It seems that both the sampling performed by ADC1 and ADC2 almost happen at the same time. But they should be separated by 14 ADC clocks as configured. (I know this is contradict to the observation described in 1.)
In order to solve these issues, I appreciate if someone can help in clarifying the following:
       
  1. AN3116, paragraph 2.3.1, p. 11, states that the CONT bit of CR2 is to be cleared. However, the example shipped with STM32 Cube enables the continuous mode. I believe this is essential to switch between fast and slow interleaved mode. Even not explicitly named, the example seems to be for dual slow interleaved mode (see simulation.xls shipped with the example).
  2.    
  3. The start of the conversion sequence is triggered on ADC1 by a TIM2 event. Does ADC2 also has to be configured on the TIM2 event trigger?
  4.    
  5. RM0033, paragraph 10.9.3 states in a note that the multi-ADC sequencer must be reset if the DMA interrupts the conversion sequence. The question is, is it sufficient to set the MULTI-bits of CCR register to zero and then back to interleaved mode while the ADCs remain disabled. (By the way: What are the DUAL-bits?)
  6.    
  7. Do I have to enable Discontinuous mode because Continuous mode should be disabled?
  8.    
  9. Can I leave Scan mode disabled because I sample only one channel?

I appreciate any comments and suggestions. Thank you.

sphere

Outcomes