An interesting thing about this project is that the two displays collectively have 16 pins which are used, but the Arduino is able to control both using only 9 pins thanks to a technique called mulitplexing. This technique allows only one light to be on at any given time by connecting them together and then letting the Arduino control which display gets connected to ground. Even though only one light can be controlled at a time, thanks to the phenomenon of persistence of vision, if both lights are flickered on and off in series fast enough, we perceive them to both be on all the time. While this may seem complicated, this is actually a commonplace technique for controlling LED displays.
Get experimenting and see for yourself by building your own!
Step 1: Materials
(x1) Arduino Uno (Radioshack #276-128)
(x2) 7-segment display (Radioshack #276-075)
(x1) SPST momentary pushbutton switch (Radioshack #275-646)
(x1) M-type coaxial power plug (Radioshack #274-1569)
(x2) 220 ohm 1/4 watt resistor (Radioshack #271-1313)
(x1) 10K ohm 1/4 watt resistor (Radioshack #271-1335)
(x1) Grid-Style PC Board (Radioshack #276-149)
(x1) Piezo element (Radioshack #273-073)
(x1) 9v snap connector (Radioshack #270-324)
(x1) 9V Battery (Radioshack #23-853)
(x1) 5" x 2.5" x 2" project enclosure (Radioshack #270-1803)
(x1) 22awg solid core wire (Radioshack #278-1221)
Step 2: Attach the Display
Step 3: Resistors
Step 4: Solder Together
For instance, pin 1 from the lefthand display should be connected to pin 1 from the righthand display. This process should be repeat for pins 2, 6, 7, 8, 13, and 14.
Step 5: Attach Wires
Solder a red wire to each individual pair of connected anode pins. There should be seven red wires in total.
Step 9: Cut
Step 10: Clean
Step 11: Battery Plug
Solder the red wire to the center terminal of the M-type plug and the black wire to the outer barrel terminals .
Twist the casing back onto the plug.
Step 12: Drill
Widen the pilot hole using a 1/2" spade bit.
Step 13: Wire
Next, solder a 6" green wire to the same terminal on the pushbutton switch as the resistor.
Finally, solder a 6" red wire to the opposite terminal of the pushbutton switch.
Step 14: Insert
Step 16: Wire it Up
|anode pin 13||<--->||D2|
|anode pin 14||<--->||D3|
|anode pin 8||<--->||D4|
|anode pin 1||<--->||D5|
|anode pin 2||<--->||D6|
|anode pin 7||<--->||D7|
|anode pin 6||<--->||D8|
cathode pin 12
cathode pin 4
Step 17: Wire the Switch
Insert the black wire into the ground socket on the Arduino
Connect the green wire to digital pin 12 on the Arduino.
Step 18: Wire the Alarm (optional)
Connect the piezo's black wire to one of the ground sockets on the Arduino..