Skip to main content
shopping_basket Basket 0
Log in

Building an Amplifier Test Set with Analog Discovery 2 and Raspberry Pi 4 Part 3: Hardware

audio amplifier with an Analog Discovery 2

Building the hardware to safely interface an audio amplifier with an Analog Discovery 2.

In part two of this series, we took a look at the Waveforms software and SDKused to control the Digilent Analog Discovery 2 instrument. In this post, we’ll be taking a look at the components necessary to safely interface the Analog Discovery with an amplifier, and wiring up all the parts to complete the test set.

Case Machining

Arguably one of the most important parts of any project is a nice enclosure; we settled on a suitably sized case from nVent-SCHROFF, from their Interscale M series (810-4352) . A fan tray (810-4440) was also purchased to go inside the enclosure, as the audio dummy load resistors will need some airflow to keep cool.

case machining for audio amp

To start, all the components were roughly placed inside the enclosure — this gave a good idea on the amount of room that we would have leftover (to run wire within), and how much space every component would have around it. This is well worth doing even before playing with a CAD model; proportions can sometimes begin to feel distorted when working within a 3D model.

3d case model

We then downloaded the 3D model of the case available from the manufacturer’s website, which enabled us to place all the cutouts in the enclosure and ensure everything would fit as placed previously.

With this done, a drilling template was laser-cut so that the front panel could then be machined out. This is a quick and foolproof method of making sure everything lines up as it should do.

With the application of some manual labour, the front panel had all the necessary cutouts. A laser-cut front panel label was produced, utilising “Laserables II” from IPI Plastics — this is a composite material with a thin layer of one colour acrylic on top, then a thicker base colour layer behind; a light engrave is enough to cut through the top layer and expose the bottom layer colour.

front panel controls

All the front panel controls and connectors were then installed, including the chunky rotary switch (327-585), satisfying power switch (435-5556) , banana sockets for both left and right amplifier channels (888-4588) , and then two RCA connectors for left (180-6636) and right (180-6637) outputs.

A rotary encoder (737-7760) was also included as this can easily be configured to act as an input device under Linux, such as a mouse scroll wheel and enter button.

Heatsink Assembly

Two large heatsinks, each containing four resistors, need to be fitted inside the enclosure. These take up by far most of the internal volume, and contribute most to the weight of the test set.

heatsink assembly

The mounting method for the heatsinks was somewhat improvised, and consisted of bending four tabs from sections of aluminium bar, then drilling and tapping the two heatsinks to accept machine screws.

heatsink assembly

Each heatsink then had four two ohm resistors (862-5723) installed and wired in series, with taps taken off to go to the front panel rotary switch.

temperature sensors DS18B20

A DS18B20 temperature sensor was also installed into a pocket on the heatsink; meaning that the audio signal output from the Analog Discovery can be disabled should the heatsink temperature rise too far.

Electronics Subassembly

Next was the design and assembly of the main electronics sub-assembly — the stackup consisting of the bare Analog Discovery 2 instrument, Raspberry Pi and then a relay HAT (214-8064) on top of the Pi.

analog discovery with plastic case removed

The Analog Discovery was removed from the plastic case to help reduce the bulk of the unit, and was then directly mounted to an acrylic plate which forms the bottom of the sub-assembly.

audio amp Pi & relay HAT

The Pi & relay HAT were then mounted to another acrylic plate, which formed the top of the sub-assembly. Cabling was then installed to connect the outputs and inputs on the Analog Discovery to the relays, and then on to the front panel connectors — all the internal wiring is on plugs to enable removal of components.

Final Assembly

sub assembly audio amp

With the main subassemblies now completed, we moved on to finishing the last of the component installation. The power supply (843-1676) was mounted onto the back panel of the enclosure, both due to the lack of room elsewhere, and also to help keep the wiring neater as most of the power wiring runs naturally towards the back of the unit.

audio amp sub assembly

The main electronics sub-assembly and two heat sinks were affixed to the fan tray which can then be placed inside the enclosure.

audio amp sub assembly

With the internals now in place, the front panel was fixed in place, and then all the plugs for various signals were connected to their mating sockets.

The Raspberry Pi display was fixed to the cutout in the front panel using double-sided tape, and the ribbon cable and USB for power were plugged into the Pi.

audio amp assembly

Coming Up

In the final post in this series, we’ll create a simple test application and put the hardware through its paces.

Engineer of mechanical and electronic things by day, and a designer of rather amusing, rather terrible electric "vehicles" by night.
DesignSpark Electrical Logolinkedin