Skip to main content
Graduate
October 31, 2024
Solved

STM32F401Re issue with ADC

  • October 31, 2024
  • 1 reply
  • 913 views

Hey folks.

What I do is this: I get 14 ADC measurements on different channels, than use DMA to store them into an array. When this is ready an interrupt flag is raised, I make a copy of that array and send it via UART. There is a timer to control the ADC. At some point I do transfer back an UART message that I use to update my ARR register of the timer. This set up works from time to time, but most of the time, especially on higher values, DMA that I use with ADC stops rising the interrupt flag, and no new ADC values are produced. Does anyone have similar experience?

THanks!

 

I did try to disable the UART, ADC, and TImer before updating ARR, but to the same result.

    This topic has been closed for replies.
    Best answer by Sarra.S

    Hello @Valkan Pavlov

    check for overrun in OVR bit in the ADC_SR, read section 11.8.1 in RM0368

    1 reply

    Sarra.SAnswer
    ST Employee
    October 31, 2024

    Hello @Valkan Pavlov

    check for overrun in OVR bit in the ADC_SR, read section 11.8.1 in RM0368

    Graduate
    October 31, 2024

    Thank you Sarra!