Basic Question About Switches
![gr8_big_geek](https://forums.parallax.com/uploads/userpics/4RY0FH566UPN/nZ52AR7N71F4M.jpeg)
Hello All,
Yes, literally "switches" not as in programming switches with case1, case2, etc but physical light switches.
I have a motor, it runs off of 12AMPS and it has it's own power supply and so on. Here is where I am curious. It has a switch and I'm wondering how to break the circuit with a microcontroller. I know this is a noob question but I'm just trying to figure how to break a simple circuit using the pins in/out. I know that is their basic function which is to complete a circuit to make the light turn on and then break the circuit to turn it off but what about a large switch which controls something like a 12AMP motor? The switch is fixed I just need to hop in there and break the circuit.
Any thoughts?
Thanks guys,
Yes, literally "switches" not as in programming switches with case1, case2, etc but physical light switches.
I have a motor, it runs off of 12AMPS and it has it's own power supply and so on. Here is where I am curious. It has a switch and I'm wondering how to break the circuit with a microcontroller. I know this is a noob question but I'm just trying to figure how to break a simple circuit using the pins in/out. I know that is their basic function which is to complete a circuit to make the light turn on and then break the circuit to turn it off but what about a large switch which controls something like a 12AMP motor? The switch is fixed I just need to hop in there and break the circuit.
Any thoughts?
Thanks guys,
Comments
Get a switching transistor and a relay.
Look in Resources at the Parallax site, sift through the Nuts & Volts articles there and keep an eye out for one titled, "Stamps on Steroids". Poking around the forum will likely turn up examples as well.
Shameless plug: please answer my questions! Thanks guys!
http://forums.parallax.com/showthread.php?139472-owner-s-manual-for-bs2p40-and-professional-development-board&p=1091253#post1091253
http://forums.parallax.com/showthread.php?139471-DS1307-Real-Time-Clock-%28X14%29-and-BS2P40-on-Professional-Development-Board&p=1091249#post1091249
P.S. just be aware that a solenoid has a service life. A high quality one should last through 10,000 uses, after which, it needs to be replaced or it will fail. Transistors have no moving parts unlike a physical "switch" moved by an electromagnet (solenoid), so transisters have a theoretically infinite service life.
An example of using a relay with a Basic Stamp is given on the last page of the article.
A relay uses a solenoid to close (or open) a switch. The solenoid and switch are housed together to make it easier to use. You'll also need to use a transistor, diode and resistor as shown in the article.
http://www.ebay.com/itm/Battery-Disconnect-Kill-Cut-Off-Switch-Solid-Brass-300AMPS-Car-Truck-Terminal-/270953664260?pt=Motors_Car_Truck_Parts_Accessories&hash=item3f1618cf04&vxp=mtr
Either this rotary type or a knife switch has self-wiping contacts that a relay doesn't have, so it can handle massive currents.
Don't forget about servos glitching on startup. They may move a bit, but that just wipes your contacts down for less resistance. If you can't fix it, feature it!
IIRC, this is the first time I have ever made a recommendation AGAINST using a relay.
http://www.grainger.com/Grainger/DAYTON-Power-Relay-5Z546
Look under the "Additional Information" tab ---> "...self-wiping contacts..."
This will be documented by the forum archivist and set aside as a red letter day!