My voltage divider quit working - this is weird?

Thread Starter

zirconx

Joined Mar 10, 2010
97
I think the 8.192V reading has a much simpler explanation than much of this conversation implies. There's a very slight mismatch between the ground reference at the ADC chip and the ground reference being used to tie pin 0 to ground. That small mismatch causes the ADC to read 0V sometimes, and -0.001V (-1mV) at other times.

As others have pointed out, if the negative numbers being sent out from the ADC over I2C are interpreted in code as unsigned integers (instead of signed integers,) then the smallest negative number suddenly becomes the largest positive number on the same scale.

It's important to note that the code output we've seen here several times is not the raw ADC value, but the calculated voltage derived from that number. Since the chip uses an on board reference of 4.096V, and has differential input capability, the total range of output values is +/-4.096V (+/-32,768 raw ADC value divided by 8 to get millivolts, or divided by 8000 to get volts.) So, it's not a mysterious 3 zeroes and 13 ones - it's 16 ones, plus some math to convert raw ADC values into voltages.

All of which is just a really long winded way of saying, nothing is broken on the inputs that read 8.192V when grounded. You're simply seeing 1 LSB of drift in the negative direction. Every system has there potential for at least 1 LSB of error. That's normal.

If anything's "broken," it's the code that isn't interpreting negative numbers as such. If that output had been occasionally drifting between 0mV and -1mV, no one would've batted an eye.

As for the earlier errors with the 2.5V drifting up to 3.3V, I agree with the others who say the protection diode got fried. You mentioned earlier running test measurements with the 5V supply (and 2.5V voltage divider output) active while the ADC was unpowered. Since the protection diode is placed to clamp voltage to the ADC's positive power supply voltage, when the ADC is unpowered, that diode is reverse biased and could easily be overloaded. I think it got fried, and then once it was fried, it was conducting freely in both directions.

Don't allow voltage to reach the ADC input pins when the ADC isn't powered! Or, as others have suggested, put a large enough series resistor inline with the input to guarantee that no damage is done if and when those situations come up.
This was very helpful, thank you.

I am pretty sure some other posters tried to point this out earlier, but you have explained it in a very clear way.
 

ebeowulf17

Joined Aug 12, 2014
3,169
This was very helpful, thank you.

I am pretty sure some other posters tried to point this out earlier, but you have explained it in a very clear way.
Thanks! I'm glad I could help.

And yes, I agree completely - all the answers were already provided in other posts. I didn't mean to claim credit for any original thoughts there! The only reason I chimed in was because there had been a lot more discussion beyond those posts that seemed like it could confuse the issue or cast doubt on the answers that I believe were right, so I wanted to lend my support to them.
 

Thread Starter

zirconx

Joined Mar 10, 2010
97
I added an RC filter on the 3.3v rail. I used a calculator on the internet to come up with a 150 ohm resistor and a 10 uf cap (electrolytic, I don't have any ceramic caps near that large) . Photo attached (please no comments about my terrible soldering job).

This reduced the ripple from 25mv to less than 1mv, according to my scope. However it didn't affect the readings from the ADC board (still 8191).

As an experiment I put a small ceramic cap (10pf maybe?) across VDD and ground directly on the ADS1115. That caused the reading to change from 8191 to .05v or something like that. Then it drifted around there and never went back to 8191. But after a reboot it is 8191.

At this point I'm moving on with the project, I'm not to worried about 8191 on this channel.
 

Attachments

Top