AnsweredAssumed Answered

ADC reading 15% low on one channel

Question asked by strauss.robert on Mar 3, 2015
Latest reply on Mar 4, 2015 by strauss.robert
I am using the STM32F429IIH6 for a project.

I have 3 ADC channels.  Two are working properly, but one is consistently reading 15% low (compared to a DMM).  PC2 is the pin not working properly.

e.g., when I read the ADC I might get 555. So 555counts*3.3v/1024counts = 1.7886, but my DMM reads 2.1042.  If I do a similar test on either of the other two working channels, I calculate the value I see on the DMM.

The ADC init code is standard stuff:

 /* Configure PC2, ADC3 Channel12 pin as analog input  
  GPIO_InitStructure.GPIO_Pin = GPIO_Pin_2;
  GPIO_InitStructure.GPIO_Mode = GPIO_Mode_AN;
  GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_NOPULL ;
  GPIO_Init(GPIOC, &GPIO_InitStructure);

and looks exactly like the other channels.  PC2 is reading across a 5k resistor, one channel is reading across a 1M resistor, and the other is reading across a 180 ohm resistor, so the impedance of the channel that isn't working is between the impedances of the two working channels.

Does anyone have any ideas why this channel would be off?  Maybe an initialization conflict that's buried somewhere?

Outcomes