Next Generation: beyond the ADAU1701

The ADAU1701 is a powerful DSP chip, with enough “horsepower” to implement over 100 biquads while also controlling volume, delays, mixing, and dynamic range compression (DRC). With built-in 2-input, 4-output CODECs, the chip is easy to integrate into active speaker designs, and with excellent development tools, it is easy to develop complex audio processing flows. It is still a good solution for implementing high-quality 2-way and 3-way active systems. However, we have pretty well explored that territory on other pages on this site, and there aren’t too many more new challenges left to be found. Also, the designs so far have used all of the ADAU1701 resources, and the CODECs are not up to modern standard for noise and distortion. It’s time to look at some more complex designs using newer technologies. As noted in a previous post, there are 4 areas we need to address. We’ll look at the DSP block first.

DSP

The ADAU1701 was introduced over 15 years ago, and today there are much more capable devices available to address modern needs. Back when the ADAU1701 was launched, Analog Devices did not make their tools available to non-OEM’s or provide end-user support. But that changed quite a while ago, and now Analog Devices is one of the most “DIY-friendly” chip manufacturers, with great tools that are easy to use, even for those without an engineering background. A particularly nice DSP chip for our next generation designs is the ADAU1466. This chip has more pins and more I/O than the ADAU1701, so it is easiest to use one of the many ready-made boards available from Aliexpress or eBay rather than trying to build your own circuit. The board we will focus on in these next few articles is the one from MediaWorks, available for around $50 shipped:

This chip has a lot more processing capability than the ADAU1701, with 6 times the clock speed, far more memory and better precision. However, the biggest attraction of this chip for our application is that it provides multiple channels of asynchronous sample rate converters (ASRC), which allow the DSP to interface to many different digital sources that have their own clocks. The ASRC clocks the data at the incoming rate, upconverts the data to a much higher speed, filters the data and then resamples to the rate expected by the DSP. This capability is needed for using Wi-Fi modules or connecting to televisions or CD players, as all of these devices use their own clock to transmit data.

The other great feature of this DSP chip is the same feature we used in controlling the ADAU1701: a simple mechanism for updating the DSP parameters in real-time. The ADAU1466 provides both an I2C and SPI slave port that allows updating filter coefficients and other parameters using a “safe mode.” Safe mode updates ensure the coefficient data isn’t updated during a calculation, which might result in noise or instability. This port allows using a simple Arduino device to control the parameters, which greatly simplifies the software design.

And finally, another feature of this DSP chip that we will exploit is that it has 48 channels with flexible serial I/O. The article on the line array prototype pointed out the difficulty of implementing electronic curvature in the ADAU1701, as the design required 20 channels of DSP. The ADAU1701 is an 8-channel device, so 3 of those chips and some clumsy routing software was required for the line array amplifier. The ADAU1466 can interface directly to an array of SSM3582 chips using a TDM stream with multiple channels, which will prove useful in one of the upcoming designs.

Audio Input

This section of the design is where we address issues that take on religious significance for audiophiles. There is a long tradition of using CD players, turntables and other analog sources for music playback, and for some listeners eliminating analog inputs in a music system would be sacrilegious. But our next-generation active speaker design will feature only digital inputs, and the primary inputs will be completely wireless, using either a WiFi or Bluetooth connection.

The world keeps changing, and the new paradigm for listening to audio is streaming from a web-based server at high resolution. There are a number of very high-quality streaming services that provide up to 24-bit 192KHz audio, with a huge datastore of sources, with music from all genres. Increasingly, music lovers are turning to these services because they are easy to browse and play on modern home audio equipment. And designing a speaker that can connect to these services is now quite easy, as some of the same Wi-Fi interface modules used in expensive active loudspeakers are available to the DIY community.

And there are huge benefits when we cut those cords and go with a Wi-Fi input. There is no longer an equipment rack to take up space and piss off the wife. And the CD racks disappear and go into storage. The amps are discreetly inside the speakers and the only exposed wires are power cords. The music sources are maybe on a PC or network drive somewhere in the house, or else are on the web. There is no equipment front panel to deal with, as all control is via a cell phone or tablet, and anyone can control the audio. Plus, you get audio routing to any other wireless speaker in the house. If we can make sure the television can easily share the speakers, it’s a huge step toward simplifying home audio and freeing up valuable space in the living room.

The designs for our next-generation active speaker will use a Wi-Fi module from Linkplay. Linkplay provided a module for Wi-Fi connectivity several years ago (the A31), and although it has been used in a huge number of active speakers, it didn’t catch on in DIY audio. But a new version of the module features important upgrades that will almost certainly make it a popular building block for high end home audio systems. The primary improvement is providing support for high resolution audio (24-bit/192KHz). Another major improvement is the support for a wide range of home distribution protocols, such as the low-latency AirPlay2 and compatibility with Nest, Sonos, Chromecast and Echo devices. Yet another major improvement is the ability to transmit the received audio using the 5GHz band as well as 2.4GHz. The 2.4GHz band is commonly used by garage door openers, smart appliances, and shares the same frequency range as the microwave oven. Using the 5GHz band, with its much greater number of channels and fewer devices, is a major upgrade. And by adding a microphone array, these devices can response to Alexa, Siri or Google voice commands.

The Linkplay module is far from being the only solution for Wi-Fi audio, as Cypress (now Infineon) and Qualcomm both show capable modules in their portfolios. Bose, Denon, Sonos and many others appear to be using proprietary solutions. But the Linkplay modules are available to the DIY community, and they are proven solutions that are well supported. Not everyone likes the app used to stream to these devices, but it works and is well supported. The module we will focus on is the A98:

Our next-generation device will also support Bluetooth audio. Bluetooth audio has evolved considerably in the last 5 years, although it still lags behind Wi-Fi given its bandwidth restrictions. However, it is a viable alternative for casual listening when the source is a music store or streaming service directly from a cell phone. Additionally, there will be an input for digital audio using a TOSLINK optical interface. This will provide an alternative for devices such as televisions, where low latency is essential to ensure the audio is synchronized with the video.

Amps

How much power is needed?

Multichannel audio has an important benefit of allowing lower powered amplifiers in the design. When a woofer and tweeter in a passive system both need a lot of power to reproduce a music spike, the total voltage required can be up to twice what is needed for each driver. But in an active speaker with an electronic crossover, these voltages are sourced by separate amps, so the maximum voltage required would be one-half what is needed for the passive speaker. Half the voltage results in one-quarter the power, so using multiple amps can allow using less powerful devices that run at a lower voltage.

Another issue in determining the size of the power amplifiers is the frequency range. The article on “Audio Power” in Wikipedia makes it clear that there are no definitive answers to how much power is needed for each frequency band, but that some guidelines are often applied:

  • 20 – 200Hz: 200W
  • 200 – 1000Hz: 50W
  • 1000 – 20000Hz: 5W

The higher wattage requirement for the frequencies below 200Hz means we will need to provide an output for an external subwoofer channel. Since subwoofer amps typically use an analog input, we will need to include a DAC in our design for the lower frequencies.

Who makes the best small amplifiers?

The next generation projects on these pages call for arrays of small amplifiers (10-50W) that provide a digital input (I2S) to simplify audio routing and minimize analog circuitry. And we want the devices to be low noise, low distortion, and low EMI to keep RF radiation from disrupting our wireless network.

There are several good choices from Analog Devices, TI, Infineon, and there are also some economical designs from overseas design houses targeting LCD TV’s: Neofidelity, ESMT, etc. However, the SSM3582 is a standout for this application for a number of reasons. First, it is very low distortion. You can Google “AD1994 eetimes” to see the early marketing hype the initial version of this chip received, and there is an in-depth article on the design of this chip published by the IEEE at this link. The AD1994 design evolved to the ADAU1592, and then became the SSM3302 several years later. The SSM3302 was the main amp chip used in the line array prototype referenced earlier–it is a very good sounding amplifier.

The SSM3582 features a Delta-Sigma modulator that eliminates much of the RF interference and power distribution issues of other designs, and it allows placing a large number of these chips in close proximity. There is also logic to spread the switching frequencies across a larger spectrum–TI provides this same feature on several of their devices as well. Also, the SSM3582 allows accessing the device at 16 different I2C addresses, which is another feature that simplifies using these chips in an array. The devices also support the TDM mode of the ADAU1466 to simplify audio routing to multiple chips.

Given these good technical reasons to use the SSM3582, plus some non-technical ones (the Apple HomePod Mini uses this chip, which is probably a good sign), the next generation designs will be based on this amp chip. The plan is to develop a plug-in module with two SSM3582 chips (4 amp channels total for each module) and support scalability by using up to 16 sockets on the motherboard. That module is in development. The challenge here will be to get a run of these boards manufactured, because those QFN packages are not easy to solder by hand.

What about the lower frequencies?

For frequencies below 300Hz, the SSM3582 modules might not be adequate to provide sufficient output, even when used in multiples. A study is underway on how to provide a separate plug-in module that can address the need for more power at the lower frequencies. There are a limited number of commercial amplifier modules with I2S inputs, so it is not clear whether this will need to be a “custom” solution.

Also, there is a need for even greater power for the lowest frequencies below 100Hz. For this reason, the new designs will always provide a dedicated DSP channel for a subwoofer, with a DAC to provide analog output.

Control

If you look back at the early pages of Audiodevelopers.com and the designs that preceded those pages, this Control section has evolved the most. Early approaches dating back 20 years ago used Motorola 6801-based designs written in Assembly language to receive commands and data from a PC, for either a TAS3004 DSP chip or a STA326/STA308a DSP. In the current designs, the Control block receives configuration messages via Bluetooth or WiFi, and the microprocessor calculates the filter coefficients and other parameters to control the DSP. As a result, the microprocessor needs to use a high-level language for floating point calculations, and it needs to be much more powerful than the old 8-bit micros.

Also, local displays to control the DSP have been abandoned in favor of using an app on a cell phone. That’s a lot of evolution, and it will continue to evolve as this “Internet of Things” unfolds. But the basic building blocks are now well defined, and even if the language changes from C/Arduino to Python, or if the primary control changes from Bluetooth to Wi-Fi, the basic architecture will remain the same.

All of the functions in the “Execute Commands” and “Write to DSP” blocks have been written as C++ library routines. Currently, only the ADAU1701 library exists, but part of the next generation effort will be to update this library for the ADAU1466.

All of these Control block functions are currently implemented with an ESP32 chip, which provides Wi-Fi, Bluetooth BLE, the I2C interface, and all of the computing needs. The code will compile with minor modifications for any ESP32 CPU or could be adapted to any Arduino-compatible processor with Bluetooth or WiFi connectivity. Since no I/O other than I2C is needed, the new designs are based on the very small and low-cost ($5) ESP32C3 XIAO board from Seeedstudio.

The Android cell phone app has been updated to use Bluetooth BLE rather than Bluetooth classic, so it will not be difficult to provide a comparable iOS app. Some work on the iOS app was started, but there is still a lot of Swift code to be developed.

Part 2: The Plan

In the previous section the overall scope of the next generation projects were described, and now we have some details. These new designs need a modular high performance digital input class D amp design that can be scaled to address frequencies above 200Hz or so. The initial prototype boards have been designed, but a lot of debugging and control software lies ahead. Each module will provide 4 channels of bridged amps. Also, these designs need to integrate one of the new Linkplay modules, and the existing ADAU1701 libraries need to be redesigned for the ADAU1466. An Input/ADAU1466 test bed has already been laid out for that work. Once these boards have been evaluated and the software matures to a working state, we will start work on the new projects.

The first new project is a “budget” multi-way line array using very low-cost drivers. This design will provide up to 24 channels of DSP (per speaker) to control the curvature and crossovers, and to share the amplification load across 6 of the 4-channel amp modules. A separate sub amplifier will be used, with a unique SLOB design for the bass (the link is to XRK’s XSD speaker, which uses a SLOB design for frequencies below 470Hz).

The second next generation project is an amp/DSP for the infamous “Marthas” that were introduced back at DIYDC 2009. These speakers have been stored in a bedroom closet, awaiting a better amp design than the original modified XBOX Spherex amp. This will finally bring Martha out of the closet and allow her to display her true colors (it has over 100W of LED’s powered by a 3-channel color organ).

Next Generation Pages

More to come, but here are the placeholders for the ongoing projects:

Evaluation Boards

Line Array #2

Return of the Marthas