# Analog read negative voltage inbuilt protection

I'm trying to read a -10 to +10V analog signal on my Arduino Mega (2560). I've been using a voltage divider to obtain a -5V to +5V signal (with two 10kOhm resistors), which used to work just fine. I'm wondering if this -5V signal can damage the Analog Input pins of the Mega ?

• I'm sorry, but what type of reading would you like to obtain from that signal?Because you'll not be able to read anything negative... Sep 22, 2016 at 17:36

All the IO pins contain a pair of clamping diodes to protect against over-voltage and negative-voltage situations:

As long as the current flowing through one of those diodes doesn't exceed its maximum forward current all will be well and the Arduino won't be damaged. If too much current flows then you will damage the pin.

Since you have 10KΩ resistors, at -5V the maximum current that could flow (assuming a 0.7V drop on the diode) would be (-5 + 0.7) / (10,000 / 2) = -860µA (negative because it's flowing backwards out of the pin from ground to your negative voltage source, not into the pin to ground).

Unfortunately the datasheet doesn't provide a current limit specification for those diodes, but I would expect such a small amount of current to be safe enough.

• It’s 860 µA. See my comments to KIIV’s answer. Sep 22, 2016 at 14:59

Current through the clamping diodes shouldn't be more than 1mA according to Atmel's Zero Cross Detection Application Note (AVR182).

EDIT: As Edgar Bonet pointed out you have current about `(-5+0.5)/(10000/2) = 0.9mA` (tested) in the worst case, there is not much space for mistakes.

• +1 for finding that important spec buried inside an obscure application note. Sep 22, 2016 at 14:47
• Well, it wasn't me: Max current for AVR IO protection diodes on AVRFreaks. I've seen that thread before so it wasn't so hard.
– KIIV
Sep 22, 2016 at 14:54
• It should be noted that the voltage divider is Thévenin equivalent to a ±5 V source with 5 kΩ output resistance. Thus the max current is (5 V − 0.7 V) ÷ 5 kΩ = 0.86 mA. This is assuming a 0.7 V drop in the diode. Sep 22, 2016 at 14:56
• The pin might not be damaged, but he will never read anything on the negative side of the signal.... Sep 22, 2016 at 17:37