cancel
Showing results for 
Search instead for 
Did you mean: 

How to use DMA with LPTIM effectively in STM32L011K4?

ugurkebir_91
Associate
Posted on June 18, 2018 at 21:47

Hello everybody,

I want to read ADC data from 2 channels using stm32L011 microcontroller. I can successfully read in 'int main ()' by calling the HAL_ADC_Start_DMA function. However, I want to read the adc data for a certain period of time in the 'HAL_LPTIM_AutoReloadMatchCallback' function and then turn off the adc.

In summary, when LPTIM performs an automatic upload, I want to read the adc data from both channels and then turn off the adc. When I read data from two channels using DMA, there is a problem with the timer and I can not turn off the ADC. The program is not working properly.

Any suggestions?

#stm32l011k4 #dma #hal-adc
0 REPLIES 0