2018-05-18 07:55 AM
Hi to all,
I want to write some code (using HAL) to make ADC conversions of multiple channels using DMA on a STM32L073 MCU; Here some settings that the MCU will have:
Here some questions that I want to pose:
EOCSelection
ofADC_InitTypeDef
structure equal toADC_EOC_SEQ_CONV
?DiscontinuousConvMode
ofADC_InitTypeDef
structure to
DISABLE
.In
this way, when theHAL_ADC_ConvCpltCallback()
will be invoked by DMA IRQ Handler, will the EOS flag the only one set?
I.e, will HAL_ADC_ConvCpltCallback()be called only when all the ADC conversions will be made? Or will it called at the end of every ADC channel conversion?Only one sampling time will be common to all the ADC channel?
When the
HAL_ADC_ConvCpltCallback()
will be invokedwith EOS flag set, I have to stop the DMA (via a call to
HAL_ADC_Stop_DMA()
and then to restart it again (by means of a call to HAL_ADC_Start_DMA()) to ensure a DMA proper operation?Thanks in advance to everyone who will give some answers.
Scrat75.