Controlling a solenoid (TIP120 Arduino)



Because an Arduino can only output 3.3 or 5v, a transistor must be used when controlling a 12V or 24V solenoid. The TIP120 Darlington Transistor (available at many places including Radio Shack) will allow the Arduino to control the device quite easily.

The transistor acts as a switch, and when the Base (B) on the transistor is held low, the Collector is disconnected from the Emitter. When the Base goes high, EG, when the arduino sends a 5v signal to the Base, the transistor will connect the Collector and Emitter together, closing the circuit and, powering the solenoid.

Do not connect positive ends of the 12/24V supply to the arduino, as this could easily destroy the arduino.