Arduino Forum

Using Arduino => General Electronics => Topic started by: TomS on Apr 18, 2011, 11:35 am

Title: Are the input pins protected against high voltage?
Post by: TomS on Apr 18, 2011, 11:35 am
Hello Arduino'ers!

I am trying to figure out if the analog in pins of the ATmega328p (Arduino Uno) are somehow protected?
If an input voltage > 5V comes in, will it destroy the chip or are there measures in place to prevent this from happening?

I am not talking huge voltages here just wondering what happens if a spike somewhere between 5-10 V hits the analog in?

If it is not protected yet, how can I accomplish this?
I need precise ADC readings from 0-5V but anything that would be higher can be "cut off".

Thank you very much! :)
Tom
Title: Re: Are the input pins protected against high voltage?
Post by: cmiyc on Apr 18, 2011, 03:05 pm
In the datasheet, under "Electrical Characteristics" there is a table that outlines the "Absolute Maximum Ratings."   (Page 316 in my copy.)

"Voltage on any Pin except RESET with respect to Ground ................................-0.5V to VCC+0.5V"

Anything above this (Vcc+0.5v) could damage the pin.
Title: Re: Are the input pins protected against high voltage?
Post by: graynomad on Apr 18, 2011, 05:16 pm
Quote
If an input voltage > 5V comes in, will it destroy the chip

Probably.

Quote
are there measures in place to prevent this from happening?


My favourite method is to clamp the pin with schottky diodes to VCC and GND and also have a small resistor (150R) in series before the diodes.

Many people use zeners but they will affect your ADC reading.
______
Rob
Title: Re: Are the input pins protected against high voltage?
Post by: TomS on Apr 18, 2011, 06:49 pm

My favourite method is to clamp the pin with schottky diodes to VCC and GND and also have a small resistor (150R) in series before the diodes.

Just to be sure I understand you correctly, you use one schottky diode from A0 in to Vcc and another one from A0 to GND, correct?
Which way are they oriented?

Thank you very much!
Tom
Title: Re: Are the input pins protected against high voltage?
Post by: graynomad on Apr 19, 2011, 04:29 am
This is how I would do it.

You have to look at the ability of the diodes and the size (physical) of the resistor for various voltages, for example if you expect 50v then the resistor has to be able to dissipate a lot of heat.

But for general protection I think anything will do.

______
Rob
Title: Re: Are the input pins protected against high voltage?
Post by: TomS on Apr 19, 2011, 11:18 am
Thanks a lot!!
I will give this a try :)
Title: Re: Are the input pins protected against high voltage?
Post by: Grumpy_Mike on Apr 21, 2011, 09:58 pm
See if this makes things more clear:-
http://www.thebox.myzen.co.uk/Tutorial/Protection.html (http://www.thebox.myzen.co.uk/Tutorial/Protection.html)