Sunday, June 9, 2013

Selecting Music to Play on a Squeezebox Using Android Speech Recognition

This is a short clip showing two examples of using Android speech recognition to select music to play on a Squeezebox (actually SliMP3). It shows how the server side maintains context of the current operation. I ask it to play 30 Seconds to Mars, and the server queries the Logitech Music Server database for their albums. It returns them and my phone asks which album I want to listen to. I reply "This is War" and then am asked where I want the music played ("What zone?"), to which I answer guestroom. The server then queues up the album and launches it in the guestroom, turning on the SliMP3 and the powered speakers. In the second example, I tell it a particular album (Ride the Lightning) and location in one sentence. The requested album is launched in the guestroom.

On a related note, here's sample SL4A code that passes recognized speech to an IM address and speaks the responses received. It's the basis of what runs on my phone.

No comments:

Post a Comment