I made a video to demonstrate the build process and features of this project – it is the fastest way to get an overview of what this is all about
All content on this page is protected under copyright, except for the images, which I will allow anyone to use as long as you follow Creative Commons 3.0 Attribution License (basically, just link to this webpage).
Inspiration:
This project came about thanks from a suggestion from my mother, who is an elementary school teacher. I was looking for a fun new electronics project to work on, and she mentioned that she would like a way to visually let students know how much time they have left on an assignment, or to adjust their voices to match the desired volume of the room. She said she had tried existing products (such as the Time Tracker), but they were too small and complicated. She had heard of the Yacker Tracker, but had not heard great things about it, and it was rather expensive. I came up with the idea to combine the two requirements (noise and time tracking) into one device, which I could build using a microcontroller (Arduino platform) and simple electronics (transistors, buzzers, capacitors, etc).Creation
Rather than completely fabricate the body of a traffic light from scratch, I decided to start with a premade body. I looked around online, and my best option seemed to be a randomly blinking traffic light, which are sold as novelty items for dorm rooms / bachelor pads / etc. I found one on eBay that fit my size and price requirements, and bought it (see below). I took the traffic light apart, and found that the bulbs were powered directly from AC, but were too dim to be visible from across the room. I ended up completely removing all the internals in the enclosure and fabricating my own bulbs from SMD LEDs (See below picture of a custom LED bulb I created). They are very bright, safe to use, and consume very little power. As shown in the image below, all three SMD LED panels operating at the same time only consumes a total of slightly over 200mA, low enough that a standard laptop can power the device. A lot went into this project, but here are a few major components.- A small circuit (based on this design) to take the output from a standard microphone and amplify it so the Arduino can measure the sound level in the room.
- A small circuit (based on this design) to take the output from a matrix keypad and send it to a single analog input pin on the Arduino.
- The actual code for the microcontroller to control everything and process user input – around 1,200 lines of C in total.
- Most of my time was spent trying to make the device as user-friendly as possible. This meant creating prompts that show up on the LCD screen to instruct the user how to input choices, logic implemented in code that prevents users from making choices that don’t make sense, and controls that are easy to use and clearly indicated.
Finished Product
Here are some pictures of the final result of all my hard work! I also created an instruction sheet for my mom to have as a quick reference guide to using the traffic light:Things I Could Have Done Differently:
- Used pre-made SMD bulbs (such as those sold for auto use) instead of taking the time to solder my own on perfboard.
- Purchased a pre-made traffic light that uses LED bulbs, instead of the one that I bought (that I had to strip and ended up being built with cheap materials).