I have a device that runs on 5v and pulls about .45 Amps.
I want to use the Arduino to turn it on and off and am wondering if I can safely do so by utilizing a circuit built with just the Arduino's pins ... or if I should use an external relay and power supply.
Thanks.
Hi,
Typical Engineering Answer: It Depends...
It depends on your whole project.
Is the device inductive, that could cause voltage transients when it's switched on and off?
Does the device draw a larger "inrush current" at the moment it is powered on?
Is the device attached on long wires, or connect to long wires?
See THIS PAGE for some overall suggestions.
I would not even think of it.
A pin of the microcontroller can only handle 20 mA safely.
A port of the microcontroller (e.g. pins 0..7) can safely handle 100 mA.
And the full microcontroller (all pins) can only handle 200 mA.
If your Arduino is externally powered (e.g. 9V or 12V), you will also need to take into account the power dissipation in the voltage regulator.
OK then. Sounds like the Relay is the way to go.
Thanks all!
You could use a transistor, there are cheap-ish TTL-level MOSFETs easily capable of switching amps of 5V.
I spent just under $10 on eBay to get 60 IRLZ44N's. At the time I wanted 2A to 5A to drive led strips. I won't need to buy another FET for a long time, I was expecting > 50 cents ea so I jumped on the deal for 60 but for 10 or fewer they were closer to 30 cents each.
Relays take a bunch of power to switch, that mechanical movement powered by a coil, there will be a surge and some heat. There will be enough that switching on and off too quickly for long will burn the relay.
You can switch the FET too fast to see without burning it up as long as it's always switched completely ON or OFF, very easy to do.