# The best way to test cap voltage with adc?

Discussion in 'General Electronics Discussion' started by bonedoc, Jan 6, 2012.

1. ### bonedoc

122
0
Dec 21, 2011
So, I wanted to create some events in my microchip based on the measurement of a capacitor voltage. The highest charge the cap would see is 300v. So, I thought I would create a voltage divider. With the calculations, R1 and R2 of the divider came to be 59k Ohms and 100 Ohms. This scales down fine for my ADC measurement....but it obviously drains the heck out of the cap I am charging.

Are there better options for this?

The only think I could think to do is put huge resistors in the divider to limit current flow.

2. ### BobK

7,682
1,688
Jan 5, 2010
What is wrong with putting huge resistors in the divider?

Microchip ADCs typically need an output impedance of 2500R or less, so you can use anything up to that in the lower resistor, giving you 25 times less current drawn. Or you can use and opamp and even larger resistors.

Bob

3. ### Resqueline

2,848
2
Jul 31, 2009
Yes, why not use 590k & 1k? That'll drain it ten times slower. In fact, I'd start out using a R1 with as high resistance value (MΩ's) I could get, and then calculate R2.

4. ### duke37

5,364
769
Jan 9, 2011
Thats right.
!M and 18k would give a division about the same as you have with 1/17 the drain.

5. ### bonedoc

122
0
Dec 21, 2011
LOL....I dont know why I put the low value on R2. However, I recall some issues with the ADC and high resistor values.

I will probably use 1 MegaOhm for R1, and instead of using 16K-ish on R2, use a 10k Ohm and a 10k variable resistor in series so I can tune the max value to the pic input voltage.

6. ### duke37

5,364
769
Jan 9, 2011
I was wrong!

It should be 1M and 1.8k.?

7. ### (*steve*)¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥdModerator

25,480
2,828
Jan 21, 2010
It's possible that if you're driving an ADC directly that you need a relatively low impedance source.

If so, you could use a voltage follower to buffer the voltage from the divider.