Limit input voltage to microcontroller pins

Thread Starter

ecka333

Joined Oct 1, 2009
76
I am trying to measure voltage with PIC18F1320 microcontroller. Power supply to MCU is 5V. Measured voltage will be applied to analog microcontroller input (ADC) and in normal case will not exceed 5V. But in sometimes it can rise to 10V. I think it can be dangerous to my MCU. So i want to limit input voltage to, say 5V maximum. So i want to do voltage limiter with zener diode. What zener should i choose, and how choose series resistance? Zener must do no influence to my measurement results, while input voltage will not reach 4 or 4,5V.
 

t06afre

Joined May 11, 2009
5,934
I have some ideas on this. But I do not have the time right now. If any have not pitched in(feel free) I will look at this as soon as I can
 

ErnieM

Joined Apr 24, 2011
8,046
How stiff is the source? What kind of input protection diodes can you guarantee on that input pin?

The simplest way is to just add 1-5K in series with the point. When the input jumps to 10V you only get 1-5mA into the protection diode.

If you don't like using that ESD diode (or can't guarantee is is actually there) you always have the option of using a schottky diode from pin to power, but I didn't bother even when my input was literally the hot AC line input (kids don't try this at home).

I had 500K in series and got a line crossing synch signal.

The zener can influence the reading at the high end (starts getting leaky), or can miss the start of the overage, meaning say 5.5V still gets to the pin.
 
Top