Thursday, June 11, 2015

100+V Arduino/AVR Microcontroller Input/Output (I/O) Pin Over-Voltage Protection Using a *Single* Resistor!

ADVERTISEMENT:

Subscribe by Email! (via FeedBurner)
By Gabriel Staples
Written: 11 June 2015
Last Updated: 2 Sept. 2015
Update History (newest on top):
-Added "Upfront Caveat", 2 Sept. 2015
-Added lots of extra info, & the Figures, 21 July 2015

Related Articles:

Here I present a pin protection method for very high and low input voltages that I learned from Atmel themselves, in their Application Note "AVR182: Zero Cross Detector."

If you've read my article titled "Arduino Power, Current, and Voltage Limitations" you know that the pin input voltage limits are as follows:
Maximum Input Voltage: Vcc + 0.5V, or +5.5V for a 5V Arduino
Minimum Input Voltage: -0.5V

However, if you simply add a single resistor in series with any input pin, you can protect it against higher or lower input voltages, with some caveats!

Ex: simply by placing a 10k resistor in series on an input pin, you get input voltage protection up to +15.5VDC and down to -10.5VDC. With a 100k resistor you get input voltage protection up to +105.5VDC, and down to -100.5VDC. Keep reading to learn more.

WARNING: 
-FOR YOUR PERSONAL SAFETY, WHEN USING THIS TECHNIQUE, I RECOMMEND THAT YOU DO NOT WORK WITH INPUT VOLTAGES GREATER THAN APPROXIMATELY 100VDC OR 20VAC UNLESS YOU KNOW WHAT YOU ARE DOING AND HAVE READ ALL OF MY WARNINGS HEREIN, INCLUDING THE ADDENDUM AT THE END OF THIS ARTICLE. 
-REGARDLESS OF WHAT INPUT VOLTAGES YOU ARE USING, YOU AND ONLY YOU ARE RESPONSIBLE FOR YOUR PERSONAL EXPERIMENTS, PRODUCTS, DESIGN DECISIONS, AND THE SAFETY OF YOU AND YOUR CUSTOMERS.

Upfront Caveat:
Though this technique may work, and be good for home-projects or quick prototyping, better techniques are recommended, especially if you are producing a commercial product. Redundancy is your friend. Using external, rated clipping diodes is certainly a better option than relying on the internal, integrated and unrated ones. For better protection techniques, including using *external* clipping diodes for redundancy, and adding transient voltage suppression, read more here: Science Prog: Using current limiting resistors on AVR I/O pins. Also see the AVR182 Application Note for references to additional sources to read in order to add extra pin protection.

Background & Concept:

***Subscribe by Email! (via FeedBurner)***