Intro: Display Live Txts on Costume at Party W/ Scrolling LED Belt Buckle
The project was originally inspired by a friend wanting to make a "sexting themed" costume, with a scrolling LED display of live texts sent from people at the party. We found a $13 LED belt buckle online, which looked cool, but only had a few buttons to manually enter in messages. A couple wires and lines of arduino code later, we were able to automate entry of messages.
We then added a host shield and wrote a small Android app to send txt messages on to the arduino.
Step 1: Required Parts and Code
--Android Phone (2.3.3+)
--Scrolling LED Belt Buckle ($13 at writing!)
--USB Host Shield (SparkFun one used here)
--Microbridge Arduino Host Shield to Android Library (Adb)
--Demo arduino code for writing to the LED display and receiving SMS text messages via the USB connection, and Eclipse android project to pass SMS messages to arduino.
Step 2: Automate Message Entry on LED Display
The display has three buttons that you use to change the messages. It's a long process, since you have to scroll to each letter one click at a time, and there's no speed-scroll. We pop open the case to see if we can easily attach wires to the buttons in order to automate message setting.
The three push button switches simply short the bottom side of the switch to ground when pressed. We're going to simulate this action by switching the bottom side of the swtich between a high impedance pin (a digital input) and ground (a low digital out). This is easily done by switching the direction of the pin on an arduino, using pinMode(pin, INPUT) or pinMode(pin, OUTPUT). Just make sure the output is set Low before setting the pin to output (digitalWrite(pin,0)).
Four wires are attached, three for the switches, one for ground.
Step 3: Wire LED Display to Arduino
Use pliers to make a hole for the wires to pass out of the LED display.
Then, attach the black wire (On/Off/Enter) to Arduino Digital In 2, Red (Page Up) to Digital In 3, and Yellow (Page Down) to Digital In 4.
Test out the code by uploading to the arduino, and then opening the serial monitor at 57600bps. Be sure to turn ON 'newline' next to the baud rate setting. The code uses the '\n' character to find the end of words. After you type in a phrase and hit enter, the arduino should fast forward through the same button pushes you would do by hand.
The code itself has more details, but a simple lookup table that's very similar to the asciitable provides the right number of "presses" to get to each letter. There are settings in the code that define how long the button press duration should be, and how long it should wait in between presses. It takes the LED display longer to save a letter than to cycle through the available letters, since it's storing off data to flash.
Step 4: Add USB Host Shield to Receive Txt Messages
Once the aduino-to-LED Display part is working, we attach a USB Host to to enable sending sms text messages to the display from an Android phone.
Solder on the LED wires to the host shield as shown since the shield covers up the arduino female headers where the wires used to go.
Step 5: Load SMS Pass-Through Program on Anroid
You'll need eclipse and the android code linked at the top. Open the project by choosing File-->Import.
Make sure your android phone is configured for development. You need to go into settings-->Applications and make sure the "Unknown sources" and Development-> "USB debugging" options are checked.
Then you should simply be able to attach your phone and hit run. Txt messages should should up on the display!
Getting Eclipse up and running can be a little tricky, so
Third Prize in the
Halloween Props Challenge