SparkFun Audio Breakout

Hey all,

I’ve been wanting to add some sound to my projects for a while. There are a number of ways to accomplish this of course, but for my specific project I went with a SparkFun audio breakout board.

The breakout sports a micro-SD card slot on it - finding a micro-SD card less than 2Gb was challenging. I actually went with 1Gb just to be safe per comments on the board. Then there is a WIndows-based tool that converts audio files to the ADPCM format needed. You place your tracks on the SD card labeled with names 0000.ad4, 0001.ad4 and so on. You issue the unit commands over a 2-wire interface to play, pause, stop, next, etc.

I converted the code from an Arduino sample, and have attached it should anybody want to give this board a try.

From here I built two ways to trigger the audio. The first is an arcade button on the enclosure. When the button is pressed, it plays a specific track from the SD card. That left so much room however, I just had to put more on there. So I purchased 50 tracks from a list of VH1’s “Most Awesomely Bad Songs”. The second way to trigger the audio then is through a web page that shows the covers of the albums for those songs. You click on a cover, the Imp gets the message, and plays the requested song. The code for the web interface is not attached, but I can make the available if there is interest.

I would be interested in looking at the code for the web interface/agent. I’m curious more on what specifically you’re sending to CommandIn to relay to the audio breakout and play a specific file.