Skip to main content
Associate
August 16, 2023
Question

DMA circular mode and multiple adc channels

  • August 16, 2023
  • 3 replies
  • 1308 views

i am using dma circular mode for reading adc from 2 different channel. But the main problem that i faced was the value when it is in circular mode is getting offset from the value that i expect from the adc but when i used the normal mode the value was correct. Iam attaching my code below.

 

This topic has been closed for replies.

3 replies

waclawek.jan
Super User
August 16, 2023

Which STM32?

 sConfig.SamplingTime = ADC_SAMPLETIME_2CYCLES_5;

Is the given signal's impedance low enough to support such short sampling time?

JW

as0wanthAuthor
Associate
August 16, 2023

stm32g4 series

 

TDK
August 16, 2023

> sConfig.Offset = 182;

What values are you getting, and what values are you expecting? Increase sample time.

"If you feel a post has answered your question, please click ""Accept as Solution""."