Instructables

LEGO T-Intersection LED Traffic Light

Featured
Picture of LEGO T-Intersection LED Traffic Light


Video not playing? See it on YouTube: http://www.youtube.com/watch?v=q0tiiWwC6Zo


Background
Every Christmas we set up a large LEGO train layout in a section of the living room. This year, I ended up winning an eBay auction for a number of older-model LEGO road plates, one of which included a T-intersection. At about the same time, I saw a web magazine article on how to get started programming an Arduino embedded microcontroller. I'm a computer programmer by trade.

Inspiration
It seemed obvious to me at this point that a perfect project would be to create an LED traffic light out of LEGO bricks, some LEDs and resistors and an Arduino Nano controller. The T-Intersection became the center-piece of the layout. This Instructable will lead you through building the traffic light, as well as illustrate how the Arduino program works.

Take Two
This is my second attempt at building the traffic light. On the first attempt, my 9-year old son helped me. Being slightly impatient, as 9-year-olds are apt to be, I was left with no time to take detailed photographs. The LEDs I used, found in my parts bin, were also extremely dim: bright at night, but invisible in the day.

With this second attempt, I obtained much brighter LEDs from a string of LED Christmas Tree lights that only half lit up. I also took very detailed close-up photographs with a brand new Sony DSC-TX5 digital camera that can close focus down to 1cm. I've annotated many of the photos.

Alternates
You can choose to build this Instructable as presented or just use it for inspiration for your own creation. I realize that LEGO T-intersection road plates have long since been discontinued and are hard to come by now. Cross-intersections are all that are available in LEGO stores now. You might choose to build a fourth light. I've supplied an alternate program that should drive a cross-intersection with four advance green-lights. It should work, but since I was testing the program only on my T-intersection, it might not work perfectly. You'll need more LEGO bricks and LEDs to build such a light.


 
Remove these adsRemove these ads by Signing Up
Scott_Evoy1 year ago
We are REALLY enjoying this instructable!! We are having one issue. We can't get the yellow LEDs to run on the program. We have checked everything back to the Adruino board and everything works (all lights will light up when we check from the board to the LEDs). Would it be possible for you to check the code again to see if there is anything in there that might be keeping the yellow LEDs from working? It is all we can think of. Thanks!
Maloffstrano (author) 3 years ago
Thank you all for the compliments.

I've just uploaded the cross-intersection code in step 25, for anyone considering building that type of intersection.
Hello, thanks for this awesome instructable. My son and I are trying to build the cross intersection. We are trying to understand the wiring to the micro-controller. I am trying to understand your wiring diagram. I don't have all the headers and would like to know what wires I could solder together prior to the micro controller. I have 2 2x16 female headers, 2 1x4 male headers and 2 1x5 male headers. thanks!
nolan56833 years ago
the dumpster was a great idea
pperegrina3 years ago
Hi..

It's possible do this, with an arduino Duemilanove?

Can i put the led's togeher with a wire?

Thanks,
Pedro Peregrina
crackHacker3 years ago
in my micro-controller class we had to make a 4 way intersection with the main traffic lights, turn lane lights and a push button for walking. if you felt froggy you could toss in the other 2 parts. ours was based off how Phoenix Az had their system back in the day it has since changed alot due to more roads and all that.
zack2473 years ago
nice job!
one thing you could do to hide those wires on the back is take a 1x4 smooth piece like you have on the top and glue it on the back
Maloffstrano (author)  zack2473 years ago
Great minds think alike! I was planning to do exactly that. I'm just currently out of yellow and grey tiles. It would be the only part of the build that is not authentic LEGO construction, but it would definitely finish it off.
ChrysN3 years ago
Nice, the video is cute!
TSC3 years ago
Cool!!
catsnw3 years ago
Just another 10 months until Christmas! This will go under the tree with my trains!
Kaiven3 years ago
That is so awesome!
LeumasYrrep3 years ago
If this was only about ten years ago I would be bouncing off the walls right now. Great ideal and Instructable.
ynze3 years ago
Now THAT is a great first Instructable!!!

Be welcome!
Pro

Get More Out of Instructables

Already have an Account?

close

PDF Downloads
As a Pro member, you will gain access to download any Instructable in the PDF format. You also have the ability to customize your PDF download.

Upgrade to Pro today!