cancel
Showing results for 
Search instead for 
Did you mean: 

ADC configuration of STM32F051 controller

Amal Babu
Associate III

Can i configure three different ADC channels using ADC interrupt.If so yes, how can i read my values corresponding to each channel from ADC ISR?I have configured ADC interrupt in such a way that the interrupt triggers after all channel sequence.(Having EOSEQIE interrupt enabled)

2 REPLIES 2
AvaTar
Lead

That would not work.

The ADC has just one result register, thus you only get the result of the last channel, losing the rest.

You can use the EOC interrupt (end of conversion) to pick up individual results, but DMA would be recommended.

Configure a DMA TC interrupt, and you get a set of converted values.

Amal Babu
Associate III

Actually i am usin DMA for reading multiple adc channels.I think the way i took the result is incorrect.How should go about acquiring the result.Is it from the DMA ISR?

Suppose i have declared an ADC array to store result.Will it be possible for me to acquire all the adc results or will simply get the last channel result while entering ISR?