Archive

Posts Tagged ‘graphic equalizer’

LED based 3-channel graphic equalizer for xmms

October 30th, 2008

Some time back, I had made a prototype for an LED based graphic equalizer for xmms. But that was just a prototype and was able to only handle the data from one channel.

This time around, I made a real (not a prototype)3 channel graphic equalizer. This is also a gift to one of my friends.

The Idea was the same : create an xmms plugin that sends the equalizer data via the PC serial port and program the AT89S52 to read the data from the PC serial port and dump it out through the 8-bit ports of the microcontroller to light up the LEDs to the music. The only difference was that in the prototype I had only a single column of LEDs but in this case I have 3 corresponding to each channel. That’s where the 3 IO ports of the AT89S52 came in handy. Oh, and yes, unlike the prototype, here I had to actually interface the MAX232 level shifters with my microcontroller. On the prototype, the MAX232 was already built into my AT89S52 development board.

Here is a picture I took of it:

The LED based 3-channel graphic equalizer for xmms.

The LED based 3-channel graphic equalizer for xmms.

Notice below, within the plastic connector case, is the RS232 connector connecting the board with my PC serial port. On top, the small and long white connector is the USB connector. As usual, this board is powered by the computer USB port, which is very convenient.

A video would be better in order to demonstrate this equalizer, I guess. So, here it is, a video which I uploaded into YouTube.

Comments/suggestions are invited.

admin Embedded Hobbyist, My Creations, Tech , , , , ,

LED based graphic equalizer for xmms

September 18th, 2008

I was recently looking at a how-to to create visualization plugins for xmms.(http://www.xmms.org/docs/vis-plugin.html) And suddenly I had this idea of interfacing 8 LEDs to re-create a ‘Hardware’ graphic equalizer of sorts.

Well, I had my 8051 development system at my disposal and I started hacking onto my code immediately.

First, I tried to get my development environment ready for writing my plugin. Unfortunately, when I followed the steps in the above tutorial, I was getting a compilation error and I was not able to build my plugin code. So I aborted that line of attack.

Then I had this idea of downloading and then compiling xmms and along with that, hopefully my environment would also get set up. And sure enough! I just compiled xmms after downloading and there it was, all the default plugins were compiled. Now all I needed to do was cannibalize one of the available plugins and write my code over it.

I picked up sanalyzer(or simple spectrum analyser) and after a few hacking sessions, I was able to come up with the code for my plugin.

Next, I had to write the assembly code for my AT89S52 micro. This was a very simple program where I have simply read the data from the serial port and then dumped the same data over the PORT1 of the micro.

And with the breadboard, It just took another few minutes to rig a temporary LED graphic analyzer. One obvious thing missing in this equalizer is that rather than render all the 16 frequency components, it renders only 1 component. This is because, I had only 8 LEDs with me, and would need extra acrobatics to come up with a complete 16-channel equalizer. (Well, to tell the truth, I was damn sleepy as it was 2 AM in the morning, and I just wanted to see it work before I went to bed)

So with the hardware of 8 red LEDs connected to my PORT1 of the micro, and the plugin compiled and ready for xmms and my PC serial port connecting my micro and my plugin, I was all set to go!

So there it was! It worked! Of course, there were a few hiccups but those were ironed out easily. At last, I went bed a satisfied man, with the assurance that I created something nice, if not useful :-).

Here is a youtube video of the same. Do post in your comments. I shall post my other creations over here soon.

admin Embedded Hobbyist, My Creations, Tech , , , , ,