# Electronic – What’s a good sensor for measuring high voltages

dataloggerhigh voltage

I want to do datalogging on solar strings in the 600V range +-100V. Would prefer accuracy close to 1%.

#### Best Answer

This answer was written when the question only mentioned 600 V. Since then the 600 V \$\pm\$ 100 V requirement was added.

All you need is a microcontroller with an ADC (Analog-to-Digital Converter) and a resistive voltage divider. Let's presume you'll use a 5 V microcontroller.

VIN is your solar strings' 600 V, VOUT is the 5 V to the microcontroller's ADC. The 600 V will cause a current of I = 600 V / (R1 + R2), and that same current causes a voltage I × R2 across R2, so that

\$V_{OUT} = \dfrac{R2}{R1+R2} V_{IN}\$

Let's look at the required current first, and then get our resistor values from that. Nick is right when he mentions the 1 µA leakage of the microcontroller's I/O pin, but I don't agree with his measures. Having 10 times the leakage cuurent through your voltage divider gives you a 10% error at 600 V, when you easily can go for 1% by choosing a 100 µA current.

The blue graph shows the maximum error in % due to the 1 µA leakage current, as a function of input voltage, at 100 µA through the divider. You can see that it stays below 2% for voltages higher than 300V. The purple curve shows the error if you use 10 times high resistor values, like Nick does. So 100 µA is OK, 10 µA is too little.

600 V × 100 µA = 60 mW, so we probably won't have problems there. 600 V/100 µA = 6 MΩ, so a 5.95 MΩ + 50 kΩ divider will give you 5 V out at 600 V in. For the 5.95 MΩ you can use 1% Yageo HHV-25 resistors, a 4.75 MΩ and a 1.2 MΩ in series give you the required 5.95 MΩ. The HHV-25 series has a working voltage of 1600 V and a 1/4 W power rating. For the 50 kΩ any 1% metal film resistor will do.