If you followed along with my first Instructable, Animatronic Talking Christmas Tree, I showed you how to take an artificial tree, add some servos and an Arduino, connect it to a Processing sketch running on your computer, and make him talk and animate.

Now I want to take you a through a few more steps so that you can turn your treebot into an interactive installation. I am not going to walk you through another motion-triggered,  pre-recorded animatronic. Nor am I going to expand on the remote controlling of the tree, I have already shown you some simple techniques for that (In the first Instructable). I am going to show you how to make your Processing sketch recognize verbal commands, and perform both some useful and useless (but entertaining) things. If you follow through successfully you will have made a your push-button-reactive robot into one that listens and responds to your voice, just as a good tree should.

Here's what the tree will do when finished.

Step 1: Things That You Will Need

As this is a continuation of the Animatronic Talking Tree Instructable, you should already be in possesion of everything that you will need. For those who are just joining in, you will require
  • One Animatronic Christmas Tree, or suitably serial controlled animatronic. (Maybe you have made a talking teddy, or  grapefruit instead)
  • A computer running Processing, which you already have if you have completed makiing the first item on the list.

hey man i think i finally have a use for my arduino lol.<br>are you still active?
Are you still troubleshooting? I keep having an issue loading the program using voce1.txt, it says &quot;No such file or directory&quot;. Any ideas of what I should do?
<p>Great instruction man , i was able to make my bot using this ... the &quot;&lt;address&gt; do &quot; structure is very clever , filters out unwanted behavior .</p><p>Thanks alot , i might develop this test into an AI project next semester :) </p>
<p>The font of the code is disgusting, TOTALLY unreadable !!!!</p>
I tried to export as application but it doesn't work.. :( help please
Ok i got it, I was using lib folder instead of libraries .
i created a new grammar file but when i change its name i get this error <br>Exception in thread &quot;Animation Thread&quot; java.lang.NullPointerException <br> at voce.SpeechRecognizer.getQueueSize(SpeechRecognizer.java:152) <br> at voce.SpeechInterface.getRecognizerQueueSize(SpeechInterface.java:149) <br> at My_voice.draw(My_voice.java:103) <br> at processing.core.PApplet.handleDraw(PApplet.java:2128) <br> at processing.core.PGraphicsJava2D.requestDraw(PGraphicsJava2D.java:190) <br> at processing.core.PApplet.run(PApplet.java:2006) <br> at java.lang.Thread.run(Thread.java:662)
You did a really good job! I was wondering, since you have so many scripts and the arduino only accepts one at a time, which one is the Final One? I am not very good at understanding too well but would like to know. <br> <br>Thanks,
Cheers!!<br> I broke the code up into chunks in an attempt to make each step clear. So I guess the final code would be once you have added all the features that you like?&nbsp;<br> The arduino is only running some code that responds to serial input coming from processing. In this 'ible I am more showing how to get speech recognition running in processing and providing a few 'seed' ideas to put it to an entertaining use. Check out part 1 (link above), it might clarify things a little bit.
Terrific instructable thank you! <br> Do you have to train the robot to recognize your speech patterns or are the commands user independent ?
Thanks so much, glad that you enjoyed it. It is speech recognition not voice recognition, so it is not trained to my voice.
I SHOULD have just made it drop the f-bomb and regurgitate some naughtiness, I have two young children so I kept it clean. So much for innovation. A spray can and a lighter make for better reading, and some pre-recorded naughtiness is more interesting. live and learn.<br>
Like the update!
Time, weather&nbsp;<em>and</em> jokes?! Awesome!<br /> (also, did the tree say &quot;kiss me&quot; at 0:50 in the first video?)
yes, he did, cheeky fellow. He quips things when he hears a thank you or a Merry Christmas. Thanks!! <br>(I have a habit of thanking even machines when they have done something for me..so I programmed accordingly...it is not always easy being Canadian.) <br>

About This Instructable




Bio: Dad, maker, dreamer, hacker, painter.
More by fjordcarver:Make A 2D Video Game with Unity Acoustic/Electric Cookie Tin Unitar Make a Keepsake Book of your Child's Artwork 
Add instructable to: