Audio Sensor Development Part 4: Taming the Transient Tiger

It’s been a long time since Part 3 of this design series, but most of that is because we solved the main problems with the design and moved into production. In this article, I’ll go over the changes and release the OSHW design files for the newest version of the Shades Audio Sensor.

The first major problem with the sensor was, at no surprise to any analog designer, power supply noise. The RGB Shades posed a perfect recipe for analog difficulty:

  • A low voltage power supply delivered through several feet of thin cable
  • 68 RGB (or 204 individual) LEDs on the same supply, controlled via PWM
  • An electret microphone with millivolt-level output
  • A single-supply op-amp with about 30x gain
  • A mixed analog/digital chip with another 12x gain
  • Positive feedback (explained more below)

The positive feedback issue was pretty difficult. Any supply noise from the LEDs would leak into the microphone supply circuit, which would then be amplified greatly along with the actual audio signal. This audio signal was processed and used to drive the LEDs. Since most audio-reactive patterns show more/brighter LEDs when there is higher audio input signal, this could cause a feedback loop that drove the input to the top of the range and kept it there.

Our first measure to fight supply noise was to create a special USB cable with thicker wires; this greatly reduced the voltage drop when large numbers of LEDs switched on. It almost completely solved it, but still at higher brightness levels the positive feedback loop could still be triggered.

We tested a few filter designs (more capacitors, ferrite beads, etc). We even tried adding a separate 3.3V regulator, paying close attention to the PSRR specs. Finally ended up with this one: power everything on the Shades Audio Sensor PCB through a tiny 100uH inductor. Additionally, power the microphone and the preamp through a 390 ohm resistor with a 10uF capacitor for extra supply filtering. This works REALLY well, since the microphone and preamp draw hardly any current and the 390 ohm resistor does not drop much voltage.

The second problem involved practical use. The early microphone calculations were theoretical, based on what we’d expect in normal usage scenarios rather than actual measurement. Our own testing and early beta Audio Sensor customers confirmed that music concerts can be MUCH louder than expected. The useful range of the Shades Audio Sensor was designed to cap out around 108dB SPL. Using the excellent SPLnFFT app, we measured sustained noise levels of 115 to 120+ dB SPL at relatively low-key concerts, and the RGB Shades were also predictably maxed out all the time.

Our first effort attempted to solve the problem with a small digital potentiometer to implement a controllable automatic gain control (AGC). While good in theory, this did not work very well; it had a narrow adjustment range and only seemed to affect the signal at the two extremes of adjustment. We may revisit the concept in the future, or switch to a preamp with built-in AGC functions.

Instead, we decided to add a preamp gain switch. For quiet environments, the High setting provides about 30x preamp gain. For loud environments, the Low setting provides about 4.5x gain. This provides usable values well over 115 dB SPL, or below 70 dB SPL. It’s still not intended to react to very quiet sounds, but that could be accomplished by replacing R5 with a higher value.

This is the version we’re now producing (with a real manufacturer, instead of by hand…woohoo!). It works really well on the RGB Shades, which is a pretty difficult application…so it also works well as a general MSGEQ7+microphone breakout board for non-RGB-Shades projects.

Here is a ZIP file containing the open source hardware files: Shades Audio Sensor OSHW

Submitted by Garrett on Wed, 01/18/2017 - 18:57.