Since the solenoid requires higher current than the arduino can provide we will be using an alternative power source for the solenoid (a couple batteries) and will be "driving" it with a TIP120 transistor.
The circuit we're using can be found online here. This instructable draws from the excellent documentation in Tod Kurt's bionic arduino workshops.
Build time was exactly one-beer. Excluding the arduino and computer you use to program it, we are using less than $10 in parts. Ok!
Step 1: Parts
• USB cable for programming and powering the Arduino
• Some jumper cables
• A 1K resistor
• TIP120 transistor (TIP102 will also work fine)
• 1N4004 diode (1N4001 also works)
• Some batteries and connectors for solenoid power
• A solenoid with leads to connect to the breadboard
Step 2: Building the circuit - power connections
Step 3: Building the circuit - transistor time
We will connect the output pin of the arduino to the Base leg of the transistor through a 1K resistor. The Collector leg of the transistor will be connected to the ground leg of the device we are driving (our solenoid). The Emitter leg is connected to the ground channel of our circuit.