Introduction: Arduino Traffic Light

This project was made with 5mm LEDs and Led Mounting Hardware T1-3/4 Clear Standard to better visualization, and so using 3 LEDs for showing separately its colors Red, Yellow & Green respectively.

Step 1: Bill of Materials

Picture of Bill of Materials

What you will need:

1 5mm Red LED

1 5mm Yelow LED

1 5mm Green LED

3 Led Mounting Hardware T1-3/4 Clear Standard

1 Arduino Nano

1 Plastic enclosure of 3.2" X 1.6" x 0.8"

1 USB-A to USB-mini Cable

Soldering iron

Solder roll

Rotary drill

Drill bits of 1/4" & 1/2"

Step 2: Schematic

Picture of Schematic

Look at the schematic so that you can do a good job. Check that you will have to connect Red LED to pin 2, Yellow LED to pin 7 and Green LED to pin 12 from Arduino nano respectively while connecting each other the cathodes of the LEDs and the common connection of those to GND.

Step 3: Beginning the Project

Picture of Beginning the Project

Use the drill bit of 1/4" so that you can form the front panel of your project by making three holes. You will also have to use the drill bit of 1/2" to make the hole where passing through the USB-A to USB-mini cable.

Step 4: Installing the LED Mounting Hardwares

Picture of Installing the LED Mounting Hardwares

Mount the LED Mounting Hardwares by inserting them in the 1/4" holes made previously.

Step 5: Installing the LEDs

Picture of Installing the LEDs

Insert the LEDs into the LED Mounting Hardwares, and solder the cathodes each other of the LEDs.

Step 6: Placing the Arduino Nano

Picture of Placing the Arduino Nano

Place the Arduino nano inside your enclosure and plug in the USB-min connector. Next, insert in it the remaining terminals of the LEDs. Now, it's a good moment so that you can upload the code from www.pastebin.com webpage. Then go to: https://pastebin.com/ZvAKpReP

Step 7: Join LEDs With Arduino Nano

Picture of Join LEDs With Arduino Nano

Solder the the wires previously inserted in the Arduino nano and cut the excess.

Step 8: Enjoy Your Project

Picture of Enjoy Your Project

Close your plastic box by using the screws included in the own box and proceed to plug in it to the computer.

Comments

DIY Hacks and How Tos (author)2017-10-14

Something like this would be really good for a model train set or a toy car play set.

Something like this would also be good for timing conferences because you can program in time what you want.

About This Instructable

201views

2favorites

License:

Bio: I'm engineering and like to design electronic and programming things with Arduino hardware.
More by braulio777:Arduino Nano Capacitance Meter10 Bits Binary CounterArduino Traffic Light
Add instructable to: