Building a sound-reactive (Trinket) LED color organ

A color organ was a staple of the music scene in the 1970s, although the instrument can still be seen today at various concerts and select home theaters. The principle is relatively simple: flash colored lights in step with music or other sounds.

“Color organs sample sound and flash lights based either the sound intensity or frequency. The higher end units use analog or digital signal analysis to determine the sound energy in selective parts of the frequency spectrum and flash the lights accordingly,” Adafruit’s Mike Barela explained in a recently published tutorial.

“The Adafruit Ampli-Tie project, which uses [the Atmel-powered] Flora, has two different algorithms to light a string of Neopixel LEDs according to sound intensity. We will reuse much of the first Ampli-Tie algorithm’s code. The more complex algorithm uses a good deal of floating point math, which is too large to fit on a Trinket or Gemma.”

According to Barela, the simpler algorithm fits with room to spare, using integer math. The code is slightly modified to give the effect one may want in a color organ, although Makers can easily alter the code to produce other effects for their own projects.

To kick off the project, Barela recommends starting with a breadboard and subsequently transferring the circuit to a small perma-proto board when a permanent mount becomes more appropriate.

“You may solder the headers supplied with Trinket to facilitate breadboarding. A small three-pin header was placed on the microphone breakout board for breadboard connection,” he added.

“For a more permanent circuit, you could use a servo extension cable to extend the microphone or wire your own three wires from the microphone breakout to the Trinket, power and ground lines.”

As we’ve previously discussed on Bits & Pieces, Adafruit’s recently launched Trinket is a tiny microcontroller board built around Atmel’s ATtiny85.

“We wanted to design a microcontroller board that was small enough to fit into any project – and low cost enough to use without hesitation,” said Adafruit’s Limor Fried (aka LadyAda). “[It is] perfect for when you don’t want to give up your expensive dev-board and you aren’t willing to take apart the project you worked so hard to design.”

Fried describes the Attiny85 as a “fun processor,” because despite being so small, it boasts 8K of flash and 5 I/O pins – including analog inputs and PWM ‘analog’ outputs.

Want to learn more about building a sound-reactive LED color organ using the Atmel-powered Trinket? You can check out Adafruit’s detailed tutorial here. Additional information about the Atmel-powered Flora is available here.

4 thoughts on “Building a sound-reactive (Trinket) LED color organ

  1. Pingback: Building an analog meter clock with Atmel and Adafruit | Bits & Pieces from the Embedded Design World

  2. Pingback: Building a Trinket-powered (ATtiny 85) rover | Bits & Pieces from the Embedded Design World

  3. Pingback: How much you can hang off a Trinket (ATtiny85)? | Bits & Pieces from the Embedded Design World

  4. Pingback: Top this Lady Gaga! A NeoPixel dress made with FLORA | Bits & Pieces from the Embedded Design World

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

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

Facebook photo

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

Connecting to %s