Making Things Interactive

March 9, 2008

Midterm: Visual LED Sound Meter

Filed under: 7: Mid-Term Project,Jesse Chorng — Jesse @ 10:37 pm

As you recall from my midterm proposal, the goal of my project was to add functionality to an existing SURG grant. I wanted to focus on three things that would make Boomboxes (see here to refresh your memory) more conducive to social interaction. By utilizing the Arduino, I wanted to add visual, audio, and communication to the mp3 space so that it could be more than just a set of speakers and really encourage social activities. The most successful part of my midterm was the completion of a visual representation of the music. Looking back, it was much easier than I had made it out to be. But in order to do this, it required that I learn a lot about integrated circuits, particularly the LM3915 dot/bar display driver and the LM741 op amp chips. I had planed to use the LM741 op amp to boost the line in audio signal but found out later that it wasn’t really necessary (after hours of trying to wire it all out)  There are various schematics available online about how to use the LM3915 to drive 10 LEDs to act as a 30 db volume meter.

I ended up using one different from the schematic I originally drew for the proposal seen below.

For the audio input, I was trying to get PodGizmo’s iPod breakout board to function using other people’s work on getting functionality through the iPod dock connector. The pinout is exceptionally useful and allowed me to see what each of the 30 connectors in the iPod dock does. However, there is limited work still underway to try and figure out how exactly the iPod dock connector functions and a lot of it still remains a mystery.  I was unable to grab audio from the iPod dock connector for an unknown reason and had to use a 1/8″ stereo headphone cable instead. I suspect that pin 21 in the iPod dock has something to do with setting the iPod in the proper mode. When not in proper state, the iPod continued to output music only thru the headphone jack and not the dock connector. I will continue to work with it and update this post as soon as I get a better understanding of the iPod Accessory Protocol. 

Here is a short video of my meter in action: 

The Arduino code I used was very very basic because working with ICs became my main focus. On the Arduino side all I wanted it to do was detect when music was being played and at what level. Since the music outputs a 0 – 1.5V signal, all I did was read that and print it out on the display.

/* iPod Analog Read*/

int ipodPin = 2;       // sets analog input pin from iPod audio out
int val = 0;            // variable to store the value coming from audio out

void setup(){
     Serial.begin (9600);
}

void loop(){
     val = analogRead(ipodPin); 
     Serial.print(' The iPod input is: ');
     Serial.print(val);
     Serial.println( V);
} 
Advertisements

Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: