So, building on the previous tutorial on identifying peaks in a sound file, I have integrated into my TJBot robot. Essentially the robot plays a song and waves its arm (driven by a servo motor) in tandem with the peaks in the song.
Detailed instructions can be found on instructables. Full code can be found on Github.
Interested in TJBot?
IBM TJBot is a DIY kit that allows you to build your own programmable cardboard robot powered by IBM Watson Services. It consists of a cardboard cutout (which can be 3D printed or laser cut), Raspberry Pi and a variety of add-ons – including a RGB LED light, a microphone, a servo motor, and a camera. Learn more at http://ibm.biz/mytjbot.