5

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 ?

Thank you in advance for your time !

Etienne P.
  • 53
  • 4

2 Answers2

3

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

enter image description here

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.

Majenko
  • 103,876
  • 5
  • 75
  • 133
1

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.

KIIV
  • 4,272
  • 1
  • 11
  • 21
  • +1 for finding that important spec buried inside an obscure application note. – Edgar Bonet Sep 22 '16 at 14:47
  • Well, it wasn't me: [Max current for AVR IO protection diodes](http://www.avrfreaks.net/forum/max-current-avr-io-protection-diodes) on AVRFreaks. I've seen that thread before so it wasn't so hard. – KIIV Sep 22 '16 at 14:54
  • It should be noted that the voltage divider is [Thévenin equivalent](https://en.wikipedia.org/wiki/Th%C3%A9venin%27s_theorem) 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. – Edgar Bonet Sep 22 '16 at 14:56
  • 2
    The pin might not be damaged, but he will never _read_ anything on the negative side of the signal.... – Roberto Lo Giacco Sep 22 '16 at 17:37