cancel
Showing results for 
Search instead for 
Did you mean: 

ADC DMA TIM2 TRIGGER

Deepak Tajanpure
Associate II
Posted on March 25, 2018 at 12:29

I want to use ADC which will be triggered by Timer 2 . I also want to use DMA to access adc converted data for fast sampling. Please help me for how to proceed?

4 REPLIES 4
T J
Lead
Posted on March 25, 2018 at 15:04

do you have a board ?  the Eval kits have a more fulfilling set of samples, depending on your journey thus far

do you have/use the cube ?

which processor is it ?

Posted on March 25, 2018 at 15:34

Review the reference manual and software examples for the specific board/part you are using.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on March 25, 2018 at 19:14

I am using STM32F405 controller and cubemx is also used.

Problem is when to call HAL_ADC_START_DMA as ADC will be triggered by TIM2

Trigger.

Also timer 2 event frequency will have to changed from 1khz,2Khz,....3MHz.

So please help me

Posted on March 26, 2018 at 07:18

here is my startup code for the ADC, using timer15

    start_Timer15();

    ADC_RowCounter = 0;

    Ave_ADC_ChannelCounter = 0;

    ADC_ChannelsCounter = ADC_ChannelCount;          // 15 ADC channels

    HAL_ADC_Start_DMA(&hadc, (uint32_t *)ADC_DMABuffer, ADC_ChannelCount);0690X0000060ACHQA2.png