![]() | ![]() | ![]() |
| | |||||||
| General Electronics Chat This forum is for general chat about electronics, eg: Dont know what a part does? Dont know how to read a circuit? Want to get an opinion? |
| | LinkBack | Thread Tools | Display Modes |
| | (permalink) |
| Hi, I want to limit the input voltage to a project, the input will be connected directly to a pin on a PIC, I would like to have as wide a voltage range as resonably possible, is there a simple way to do this like a zener or IC or something? Thanks | |
| |
| | (permalink) |
| try a voltage divider or use a regulator like a LM317 or LM340
__________________ Reality is an illusion. | |
| |
| | (permalink) |
| What do you mean, do you have a high voltage signal wich you need to input into a digital input on a pic? Just put a resistor in series with it (10K or 100K). The pic's internal clamp diodes will limit the voltage. | |
| |
| | (permalink) |
| I want this pin to be a general purpose input so the user can attach say 12v or 24v etc. to it and I would see this as a digital '1' in my code without damaging the PIC. Thanks | |
| |
| | (permalink) | |
| Quote:
A 100K would work fine, and allow much higher voltages than the 24V you are using. If you check the MicroChip datasheets they use the same method (with a higher value resistor) to feed mains into a PIC pin - to detect zero crossing. | ||
| |