Voice2LED Project
November 7th, 2009 at 0:15I’ve had some people ask about the particulars of the Voice Controlled LED sign from a couple days ago:
If you’re a non-geek, this probably won’t interest you. So Mom, you can skip this post. By the way, it got featured on the front page of the nerdkits website!
I made the LED sign following instructions from this tutorial on Nerdkits.com. The hardware is some LED’s, a nerdkit, a piece of cardboard and a bit of wire that I got from some Cat 5 cable laying around. I cut out the cardboard and printed a grid to help me lay out the LED’s. I think mine were 1 cm apart. The soldering took forever and it was the first real time I did any soldering so it looks kinda crappy. Oh well. It works. The sign itself is powered by a 9 volt battery and receives data from my laptop through the serial port via a USB adapter. All that stuff was included in the Nerdkit when I bought it. The microcontroller is running code from the tutorial I mentioned earlier. One of these days I’m going to make an enclosure for this thing.
On the software side of things, there are two python scripts that make everything happen. The one called voice2led.py is a script that reads a text file and prints whatever is in it to the sign (twice, but that is easily adjustable). I did this so that I could easily change the message by just editing the text file. The script will print to the sign at whatever interval you choose. Mine is set to every 60 seconds. I have a file named led_message.txt that contains the actual message.
The other python script, named checkvoicemail.py is where all the cool stuff happens. Using the PyGoogleVoice module of python, this script checks my Google Voice account for voicemails. I have it set to only read the most recent message. It parses the voicemail and checks it to see if “Message” is the first word. If it isn’t, it sits back and waits for one that does. This way, if I get a real voicemail, it won’t be broadcast on the sign. As an aside, I tried a few different phrases to trigger a sign change before just settling on “Message.” Google Voice would occasionally mess up the transcription on things like “Change Sign” and “New Message”and the message would get kicked out. Once it finds a voicemail that begins with the trigger word, it chops off the word “Message” and then writes the rest to the led_message.txt file. For the sign to run the way it does in the video, you need to run both python scripts at the same time. One to check voicemails and the other to write them to the sign. It’s that easy!
This script can be easily adapted to write your latest SMS messages to the sign as well. PyGoogleVoice has some great examples included in it that really helped me out. I hope you enjoy playing with this stuff and if you have any suggestions for improvement, please let me know!


November 9th, 2009 at 3:24 pm
[...] writes in to point us at this handy use of the Google Voice transcription feature. In his Voice2LED Project, Josh converted a simple LED sign into a voice-activated one by connecting it up to his phone [...]
November 9th, 2009 at 4:09 pm
[...] handy use of the Google Voice transcription feature. In his VoicϴLED Project, Josh converted a simple LED sign into a voice-activated one by [...]
November 9th, 2009 at 7:02 pm
That thing would be great for telling off bad drivers!!!!
November 9th, 2009 at 9:04 pm
Great job dude! I can see tons of applications for this! Keep us updated with other cool projects while I go online and get hold of some stuff to build my own
November 9th, 2009 at 9:16 pm
You made the frontpage of slashdot too!!! Its cool!
November 9th, 2009 at 9:20 pm
Can this be done using google voice SMS feature? We want to do that for our wedding to add a geeky touch?
November 9th, 2009 at 9:44 pm
Yes, in fact, when I started working on this, I had it using SMS. I don’t text very much so I wanted to switch it over to voicemail, plus I just wanted to see if I could do it. Dig into the pyGoogleVoice module of Python and you’ll find all the stuff you need in there.
November 9th, 2009 at 10:34 pm
nice stuff bro
Watch you get slashdotted haha.
November 9th, 2009 at 10:49 pm
Cool project. You could add tons of cool command keywords that activate outputs for lighting control etc.
November 10th, 2009 at 12:53 am
[...] This post was mentioned on Twitter by patrickfink and Adrian Cruz, Andrea M.. Andrea M. said: The Davis Blog » Blog Archive » Voice2LED Project http://bit.ly/1k2G5h [...]
November 10th, 2009 at 5:13 am
[...] option for the sign to display voice messages left with the help of a Google voice to text service. Josh has documented the project here and has made the code [...]
November 10th, 2009 at 7:33 am
[...] Check this out for more info: http://thedavisblog.com/blog/?p=691 [...]
November 10th, 2009 at 8:01 am
[...] 2 minutes, bake for an hour at 400 degrees Fahrenheit. Your soufflé is done, whoops, we mean your voice controlled LED sign is done. Leave a voicemail on Davis’ Google Voice account that starts with [...]
November 10th, 2009 at 8:39 am
[...] option for the sign to display voice messages left with the help of a Google voice to text service. Josh has documented the project here and has made the code [...]
November 10th, 2009 at 8:47 am
[...] a great video, a good explanation of how he does it, and source code. Voice2LED Project – [Link] Tags: Led, NerdKits, voice Filed in Led | 3 views No Comments [...]
November 10th, 2009 at 1:25 pm
You need to integrate it with Cruise Control and send a message the “Build is Broken”!
November 10th, 2009 at 2:07 pm
[...] a great video, a good explanation of how he does it, and source code. Voice2LED Project – [Link] Share and [...]
November 10th, 2009 at 3:30 pm
[...] option for the sign to display voice messages left with the help of a Google voice to text service. Josh has documented the project here and has made the code [...]
November 10th, 2009 at 4:25 pm
Cool! I showed my classes your video today.
November 10th, 2009 at 7:25 pm
I think this can be used to push Twitter/facebook updates without typing a letter. Just leave a google voice msg and instead of writing it to a signboard, call Twitter/Facebook API for status updates…cool.
November 10th, 2009 at 7:42 pm
[...] Davis 制作了一个程序能够通过Google Voice 来控制一个LED灯墙。它的效果是,可以让你通过Google Voice [...]
November 10th, 2009 at 7:43 pm
That’s a great idea. It should be pretty easy to modify the code to do that.
November 10th, 2009 at 9:30 pm
[...] option for the sign to display voice messages left with the help of a Google voice to text service. Josh has documented the project here and has made the code [...]
November 11th, 2009 at 10:39 am
[...] option for the sign to display voice messages left with the help of a Google voice to text service. Josh has documented the project here and has made the code [...]
November 11th, 2009 at 11:28 am
[...] left with the help of a Google voice to text service. Josh has documented the project here and has made the code [...]
November 11th, 2009 at 4:04 pm
[...] The Davis Blog » Blog Archive » Voice2LED Project The other python script, named checkvoicemail.py is where all the cool stuff happens. Using the PyGoogleVoice module of python, this script checks my Google Voice account for voicemails. I have it set to only read the most recent message. It parses the voicemail and checks it to see if “Message” is the first word. If it isn’t, it sits back and waits for one that does. Published in: [...]
November 11th, 2009 at 6:54 pm
I really liked this one – using google voice message to connect with leds – cool stuff!
November 17th, 2009 at 7:32 am
[...] LED screen displaying messages left on a voicemail [...]
December 7th, 2009 at 3:12 pm
very, VERY impresive.
December 14th, 2009 at 1:09 am
I like it. Am trying to emulate portions of the script to fetch the body of the transcribed messages and getting error message of “AttributeError: ‘Voice’ object has no attribute ‘voicemail_html’”. Any ideas? I’m hoping to be able to use the hash / sha1 / message in order to cross-reference the transcription with the downloaded voice message. Thanks.
December 14th, 2009 at 6:38 pm
Sorry Brig, I did some messing around, but I can’t seem to reproduce that error. Maybe you could email me some of the code? I’m a bigtime Python n00b, so I don’t know how much help I’d be, but if you want, you can send it to joshosu [at] gmail com and I’ll take a look at it.
December 16th, 2009 at 4:19 pm
Hey Josh, I just ran checkvoicemail.py right “out of the box” only adding userid and passwd and I got the same error as @Brig (“AttributeError: ‘Voice’ object has no attribute ‘voicemail_html’)?
BeautifulSoup and googlevoice packages seem to install just fine, any ideas?
December 16th, 2009 at 8:50 pm
Turns out the problem is related to the new version of pygooglevoice. I was/am using pygooglevoice 0.4 and there have been some changes in pygooglevoice 0.5 that breaks the code. I’m working on an update right now.
February 24th, 2010 at 10:55 am
What creates the leading periods in your python code. Brand new to python and while I have it working on mine I would like to replace them with some other static text. I have mine following a non profit organization on Twitter.
Thanks
Guy