# Voltmeter with Arduino

Good morning

I have to read a negative voltage with respect to the ground in a dual power supply and send it to a LCD screen. I know about the resistor divider to reduce voltage to 5V. max but what happen if I connect the negative voltage to the A/D converter and the ground of the power supply to the ground of Arduino? It reads a negative voltage?

Hoping the question is clear I am waiting for a kind reply.

Thank you

what happen if I connect the negative voltage to the A/D converter and the ground of the power supply to the ground of Arduino?

You fry the arduino.

Is the power supply floating with respect to the arduino supply?
If so then connect the arduino ground to the negative of the supply, and the potential divider trick to measure the ground (which will be the negative voltage) and the positive rail which will be the positive rail voltage plus the negative rail voltage.

If they have all the same GND (there is, not floating), there's another possible trick: "resistor divider" from the positive supply to the negative supply. Since you know the positive supply and resistor divider, you can calculate the negative supply. The resistors must be calculated such that the "divided voltage" is above GND in your target voltage interval. The expression for this special resistor divider is

Vout = Vpos - (Vpos - Vneg) / (Rtop + Rbottom) * Rtop

Example
Rtop = Rbottom = 10K, Vpos = 10V, Vneg = -10V => Vout = 10V - (10V - (-10V)) / 20K x 10K = 0 V
Now let's say Rtop = 1K: Vout = 10V - (10V - (-10V)) / 11K x 1K ~ 1.818V which the Arduino can perfectly read.

You'll have to solve the equation in order to Vneg to get your value.

Add protection resistor-zener and capacitor to the analog input. You must do your math to make sure you can achieve whatever measuring requirements you have.