Does anybody have a really elegant way to switch PIC inputs from12 to 24 volt sources, I'm thinking automotive, marine, or even aircraft sources, I was thinking voltage divider, but . . . is there a better way?
Does anybody have a really elegant way to switch PIC inputs from12 to 24 volt sources, I'm thinking automotive, marine, or even aircraft sources, I was thinking voltage divider, but . . . is there a better way?
I had to quote Homer Simpson on this one - Stupid question!
I guess that is what opto isolators and current limiting resistors are for , stupid me!
J. S.
One thing I have seen used, but not used myself, is to use 78L05 regulators with the input to the high voltage you want to detect, and the 5v output going to the PIC input pin.
Seems pretty good in theory, as any variations in the input will just be absorbed by the regulator. A bit better than voltage divider etc???
In 1,000 years I do not belive I would have tried that! It sounds like a terrific
Idea, cheap, easy to implement, small footprint, I don't think it would be great on a real low power application but most automotive apps. are not low power!
I'm going to try it! THANKS ! ! !
I love it when creative people get together and swap Ideas!
Joe Stokes
Hi, Joe
A simple opto-coupler ( 4 pins footprint for the TLP 620 i.e. ) ... will do it really nice.
And avoid ground interconnections too !!!
Alain
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
muddy0409
Your idea to use LM7805 integrated circuit regulators is a GEM, it works well and it takes up way less room on the circuit board than an opto coupler, opto isolator and requires no resistor for the led as in the opto device, thereby making PC board layout a snap. Very innovative, Thanks Again! JS
OK,
I use a 100k-resistor in series and it works (yes, a PIC has clamping-diodes).
Am i bad or evil ?
PBP 2.50C, MCS+ 3.0.0.5, MPLAB 8, MPASM 5.14, ASIX Presto, PoScope, mE mikroBasic V7.2, PICKIT2
Is this the "proper" way of sensing the state of a 12V source?Originally Posted by BigWumpus
I have also seen voltage dividers or transistors used. Whats the best method for a 12V sense? (just detecting on (0V) or off (12V))
I decided to use the suggestion below, I would never use just 1 resistor, 2 would make a voltage divider, I wanted 5 volts across the useful voltage range an automotive system spans, and that's what the suggestion below provides, you do not have to go the expense of 1 amp regulators either, just the little TO-92 cased ones work fine.Originally Posted by DynamoBen
JS
Originally Posted by muddy0409
Hello,
I had an application where I had a motion detector that outputted a 12vdc signal to a 16f84a and I passed the 12vdc signal through a 22k resistor to the pic input pin. I also tied a 10k resistor from the pic pin to -5 v (ground) along with a 10uf capacitor to -5 v (ground) the two resistors formed a voltage divider. That was years ago and it still works great.
Here is a great Potential Divider Calculator that's real easy to use and according to the calculator my voltage to the pic input pin would be 3.75vdc.
http://www.electronics2000.co.uk/calc/calcdiv.htm
It was on another list years ago that, that was recommended and like I said, its still working good.
Good Luck
jessey
The voltage regulator would be overkill for me. I'm just sensing the state of a 12V source. It’s an automotive application so it could be anywhere form 12-14V. So I guess the best bet is a voltage divider. I would assume any odd spikes in voltage would be taken care of by the internal clamping diodes.
The last 3000-4000 parts we have sold have a relais to switch the power after switching the ignition. Before, there are sometimes little voltage on the pin.Originally Posted by DynamoBen
In our current design, I use a zener-diode (5,1V) followed by a 4k7-resistor towards griund and a 100k-resistor to the port.
My intention was to reject all this little voltages on the ignition-power-line comind from other devices...
Last edited by BigWumpus; - 20th August 2006 at 10:06.
PBP 2.50C, MCS+ 3.0.0.5, MPLAB 8, MPASM 5.14, ASIX Presto, PoScope, mE mikroBasic V7.2, PICKIT2
Bookmarks