What filter for BS1 running off 12v automotive power?
I have a BS1 application that runs fine on my desk with a 12v power supply, but gets a little crazy when I hook it up to my truck.· I was looking at this example on Wikipedia (http://en.wikipedia.org/wiki/Low-pass_filter#Examples_of_low-pass_filters) and wondering what values would be good to use for the resistor and capacitor and if anything else would be recommended?
·Edit:· to bring some completion to this thread, through a process of elimination I figured that the problem had to be related to feedback from the solenoids.· a simple diode across them took care of the problem.· I expected it to be more complicated![smile.gif](http://forums.parallax.com/images/smilies/smile.gif)
Post Edited (brettm) : 8/16/2006 5:07:52 AM GMT
·Edit:· to bring some completion to this thread, through a process of elimination I figured that the problem had to be related to feedback from the solenoids.· a simple diode across them took care of the problem.· I expected it to be more complicated
![smile.gif](http://forums.parallax.com/images/smilies/smile.gif)
Post Edited (brettm) : 8/16/2006 5:07:52 AM GMT
Comments
·· There is a filtered vehicle power supply schematic over at the SEETRON website.· I hope this helps.· Take care.
http://www.seetron.com/an_vpwr1.htm
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com
http://en.wikipedia.org/wiki/Low-pass_filter#Examples_of_low-pass_filters
I think I'm going to try a 200 ohm resistor and 10uF capacitor...
I understand there is a lot going on electrically in an automobile, but one thing that confuses me is that I get the same results whether the motor is running or not. I would think that with the motor (and therefore ignition system, etc) off and simply drawing off the 12v battery it would get a clean source of power....
Post Edited (Mike Green) : 8/14/2006 12:24:43 AM GMT
I shouldn't be overloading the output, I'm running 5 transistors (2N4400) with 10k resistors to the base, so each of those 5 pins should only be putting out about 1mA. That also wouldn't explain why it works off a transformer but not my car battery.
I am completely confused, especially by it not working when the vehicle is not running.
My BS1 is·using 2 momentary inputs·to control 5 outputs, the inputs send the program up or down·through a series of different output combinations.· All the outputs run through a 10k resistor to the base of a 2N4400 transistor which are all grounded to VSS at the emitter.· On 3 of the transistors I have LEDs on the collector side fed by VIN (the LEDs have a built in resistor and are rated 15mA at 12v).· On the other 2 transistors I have 1A relays (335ohms across the coil, 36mA)·on the collector side fed by VIN, and through these·relays I'm trying to control 2 solenoids that pull about 800mA.
When I have this circuit hooked up to the transformer (says 12v 200mA, but is actually putting out 15v) everything works perfectly.· The 200mA transformer obviously doesn't supply enough power to power the solenoids, but the LEDs and relays work perfectly.
When I have this circuit hooked up to the 12v battery (direct connection, vehicle running or not, no difference) it will work for a short while (usually around 30 sec) then freeze at one stage and once frozen·every ~2 sec the LEDs quickly·switch off and back on.·
Now here is where it gets really interesting.· If I have it hooked up to the 12v battery but disconnect the solenoids from the relays, the LEDs and relays work perfectly.· Now I can't understand why removing a load from the relays would let the BS1 run properly·when the relay is simply a mechanical connection and the only impact they should have on the circuit is the power needed to drive the coil...?
Any help?
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com
You are using the relay to drive a more powerful solenoids.
The problems is a huge inductive field collapse of solenoid that is sending a spike of high voltage back to the BasicStamp.
Nasty, nasty stuff.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"If you want more fiber, eat the package.· Not enough?· Eat the manual."········