Tuesday, August 2, 2011

MSGEQ7 with a LED cube matrix!!

http://www.youtube.com/watch?v=KGAUCPmDVYE&feature=channel_video_title

So i got put on to sound spectrum analiser IC....

http://www.youtube.com/watch?v=KGAUCPmDVYE&feature=channel_video_title

The above image shows how i hooked it up. What it does in a nutshell is for every clk signal that i give it it changes what frequency range it is outputting (as the output is multiplexed). We can then take this data and read it into the arduino which gives us a number that we can fiddle with.
See the data sheet for the msgeq7: http://www.mix-sig.com/datasheets/MSGEQ7.pdf
The internal clock of the msgeq7 (and this effects how it checks the frequecies) is set by some eqternal circuitry, namely the stuff connected to pin 8. I'm still trying different values here to see what gives the best result.

So what i did was to convert the number to one between 0 and 4, and then display this information on the led cube that i had made, volia i have a led cube that reacts to music :) I should note here as well that i used 2* 3.5mm audio jacks so this can be connected inline between any device.

Here's the code: (all can be opened in a txt file)
- cube.pde is the main file
- within patterns.pde the finction entitled pattern_sound() hadels the stuff with the msgeq7



Enjoy.
I
 p.s here's some images