In my early days back in the 90s when my feet just started hitting the ground, I had a fear (how wonderful were those days when the pair of aerodynamic feet were flying into the thin air!). A fear of going out into the dusk due to the imaginary fact that there might be ghost somewhere. Couple of days ago, a young ‘un of age four whispered with a bit quavering melody that he inherited the same fear— doesn’t cause by ghost but aliens! So, it is just another example that world is progressing in its exciting domain— technology as we name it. Too much excitements but so little time to get sync with.
Good grief— where does the time go and when is the time to do something fun and interesting? Mention not but it’s true that when you are an engineer by the trade of fate, you have little choices but to manipulate bits and bytes or to flash string of LEDs randomly to relinquish an extra chunk of fun and excitement. If you are fortunate enough on your journey, some magic smokes (another synonym of learning to hardware guys and gals) will amplify your fun and excitement further.
Enough tidbit, now time to concentrate what I’m going to do. As music gets me dancing (intrinsically as things don’t seem much flexible to yours truly), it would be nice to have an interactive, flashy audio spectrum analyzer. To avoid the complexity, accumulated from multitude of options available in different domains— display technology to use, extraction of spectrum data from audio stream, representation of extracted data on the display etc., I decided to follow the widely accepted maxim. When resources are limited and constrained, the best bet is to go with KISS (Keep It Simple
As a display technology, I’m going to use intelligent control LED (LED and control circuit are integrated in a package), named as WS2812B by its manufacturer, WorldSemi. Reason behind this particular choice is it can illuminate a total of 16M (24-bit RGB) colors with different brightness levels while blessed with the ability to convey meaning to color its cascaded siblings. So, I can have the opportunity to illuminate multiple of LEDs with different brightness levels by utilizing only a single pin from any programmable controller like microcontroller unit (MCU) or Field-Programmable Gate Array (FPGA). In order to extract spectrum data from audio stream, I decided to use MSGEQ7 , a seven-band graphic equalizer chip from Mixed Signal Integration. Inside this little ragamuffin, there are seven band-pass filters tuned to frequencies— 63 Hz, 160 Hz, 400 Hz, 1, 000 Hz, 2, 500 Hz, 6, 250 Hz and 16, 000 Hz to divide the audio spectrum into seven bands. Cheap and cheerful Arduino will empower the brain of the system since it allows me to use some of the trustworthy software components, crafted and evaluated by others.
“Something works for someone” simply doesn’t mean that the same something will go smooth for yours truly. So, before deep dive into further, I prefer to implement a basic circuitry as a proof-of-concept to evaluate the functionality of new-to-me components. I wanted to get the full flesh of MSGEQ7, though I hadn’t collected enough lipsticks (only this single NeoPixel Stick). So, Processing was the rescue. Amplitudes of synthesized seven frequency bands are sent to PC over USB-Serial interface of Arduino and finally mapped into seven colorful, dynamic vertical bars on the visual art, produced by the Processing sketch. Ooh, shiny! Rainbow Blaze is now dancing and I’m on my merry way to make it real big…