Let's Make Robots!

Ganzbot: A talking robot which reads Twitter

Reads the latest status from Twitter.com and then verbally speaks it with a couple different mood options.
Ganzbot.pde4.2 KB


I've added the video of Steve's reaction to the robot.  Also, here are more details about the robot, construction and software:






This robot has eyes, eyebrows and a mouth and will verbally read the latest Twitter status to you. It uses an Arduino Decima to control the head actions and receives the latest Twitter status information over USB from a host computer.

For those who don’t know, Twitter is a micro blogging tool where users announce what they’re doing with 140 characters or less. (see Twitter in Plain English)

You can also send it something to say directly from the command line with a few moods to choose from


A couple months ago a few people at the office decided to create a Twitter account called “Ganzbot”, named after Steve Ganz, as a joke. Then when Steve left to compete in the PDGA World Championships we decided to build a “real” Ganz Robot to occupy his cube when he returns.




How it works

At a high level, there is a Java program on the host computer which retrieves the latest Twitter status, passes facial and word data to the head and then speaks the Twitter status through the computer speakers using FreeTTS, an open source Java text-to-speech synthesis library. I would have liked to put a speech synthesis chip in the head instead, but didn’t have the time.

LED Lips — how to make them talk

Getting the LED lips to be synchronized with the words was a bit tricky. Unfortunately FreeTTS doesn’t implement 100% of the JSAPI, so when it’s speaking there is no way to know when one word ends and another begins. Instead, the Java program on the computer splits up the text into individual words, sets the volume to zero and speaks each one to figure out how long it takes to say. Then the program passes the word times to the head and starts speaking the entire sentence with the volume at the normal level. The lip synchronization isn’t perfect, but it’s pretty good.

Another option might be to light up the LED lips from an audio spectrum analyzer.


To keep it simple I took a standard perf board from Radio Shack and added header pins to turn it into an Arduino shield. This makes it really easy to connect it to the Arduino and ensures all the pins are in the correct sockets. The circuit below was created to show the pins and voltage source as they appear on the board. More details on the circuit after the diagram.

Circuit Diagram


Unfortunately there wasn’t enough juice coming from the Arduino chip to power the LEDs very bright, so I had to use standard NPN transistors to feed the LEDs power directly from the board.

Lips and Eyes

I only included half of the lips and eyes in the circuit diagram since the other halves are simply connected in parallel and I didn’t want to clutter it up. I’m sure you can figure it out. If you have trouble, leave a comment below.


The eyes are simple multi-color LEDs I picked up from Radio shack. They can output red, green and blue, but the Ganzbot only uses red and blue. The longest pin is positive and the color depends on which pin you put to ground. I suggest testing it on a breadboard before soldering it into place.


On the host computer a Java program retrieves the Twitter information (or command line message) and sends the word times to Arduino over the USB cable. All the robot needs to know is the mood it should be in (neutral, sad, angry) and how many milliseconds each word takes the speech synthesis program to say. If the program is started in “-twitter” mode, it’ll continue checking Twitter for updates every 2 minutes until you stop it.



Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

I love it! Especially when it goes evil and wants to destroy us all :-)

Hope to see more if it!


That's brilliant! You need some therapy! I love it.
Wow, works very well.


Sad to learn that it was not "the bot" that was doing the speaking.. but in a way that was also inspiring :D


Agreed.  I originally wanted to use a chip but didn't have time to wait for it to come in the mail.  There are good chip options that aren't very expensive: http://www.speechchips.com/shop/

If you use one of those chips, you'd need to figure out another way to syn the lips to the audio because I doubt the chip will tell you much information about how the words are being spoken.  Then again, I haven't looked at the datasheets yet.  Has anybody done any work with audo spectrum analyzers?  That seems like a pretty good way of doing it.

Sending the audio signal to an analog input should tell you the approximate voltage level being sent to the speaker, right?  I believe you'd need a filter in there somewhere to remove most of the noise.  Would you use a capacitor for that?  Any thoughts?

That said, I'd love to see others take a stab at a similar robot to see what they come up with.  There is a lot of room for improvement on this model.   There could be some fun applications for talking robots.

Yeah :D

And a note: do NOT purchase the soundgin chip!! The documentation & PC-program is not even online any more, and the forum is unsupported. Before it was crap, now it is deserted crap!

(And if you did it anyway I know it quite well - including all the beta / non working in it, I may be able to help)

Thanks for the advice.  I just was about to lay down some money and now I'm glad I didn't.  Is there another chip you'd recommend?

No, SpeakJEt is the same as Soundgin to my knowledge (Same chip 99%, and same crap). As far as I am concerned your only option is to buy a circuit dedicated.

Well you can go for something like WTS701 and waste your life trying to make it work, or you can go for something like this and waste your money ;)

There MAY be new options out, it is perhaps a year since I digged into this last time!

This robot just showed up on the Make blog:


And for those who've not seen it yet, Make magazine is a great source of ideas and know-how for robot builders.  They often feature robot projects on the main blog page.