Note: Editable PCB files are available for this project here.
The LM3886 is one of the most highly regarded audio chip amplifiers in the DIY community. The reason for its popularity is due to its very low distortion, minimal external components, and low cost. With the right layout and component selection, you can build an excellent sounding Hi-Fi audio amplifier that will rival high-end amps retailing for several thousand dollars or more.
In this tutorial, I’ll go step by step through the amplifier design process as I build a 40 Watt stereo amplifier using the LM3886. I’ll explain what each part of the circuit does, and show you how to calculate the right component values with examples from the amplifier I’m building. I’ll also show you how to layout the PCB and wire the amplifier in an enclosure for minimal noise and hum.
My amplifier is based off of the same circuit provided in the datasheet, with all of the optional stability components included.
I highly recommend reading the datasheet before building your amplifier. It has all of the performance specifications, absolute maximum ratings, schematics, and design tips:
Application note AN-1192 has additional information that fills in gaps left out of the datasheet. It also has schematics for bridged and parallel amplifier circuits:
It’s also good to have the Overture Design Guide. This is an Excel spreadsheet that calculates output power, heat sink size, gain, and other useful parameters:
Since this is a rather long article, here are links to the different sections:
- Things to Decide Before Starting
- Determine the Required Power Supply Voltage and Power
- Required Power Supply Voltage
- Required Transformer Power
- Determine the Proper Heat Sink Size
- Calculating the Component Values
- Find the Minimum Gain Required
- Setting the Gain
- Balancing the Input Bias Current
- Set the Low Frequency Cutoff at the Amplifier’s Input
- Set the Low Frequency Cutoff at the Feedback Loop
- Set the High Frequency Cutoff at the Amplifier’s Input
- Stability Components Rf2 and Cf
- The Zobel Network
- The Thiele Network
- Power Supply Decoupling Capacitors
- The Mute Circuit
- The Final Schematic
- Designing the Ground Layout
- Designing the PCB Layout
- Wiring it All Together
- How Does it Sound?
You can also check out this video to see a quick overview of the design process. At the end I wire up the amp so you can hear what it sounds like:
Before starting to design your amplifier, you should have an idea about how much output power you want to get out of it. Output power is what you’ll typically see stated as the Wattage rating of an amplifier. The maximum output power of the LM3886 is 68 Watts, but the actual power you get will depend on your power supply voltage and speaker impedance.
You’ll also need to know the impedance of your speakers. You should be able to find your speaker’s impedance on the back of the speaker or in the user manual.
Finally, you’ll need to know your input voltage. This is the output voltage of the audio source you’ll be amplifying. It may be in the device’s user manual, but if not, you can get a rough estimate by playing a 60 Hz pure sine wave (there are apps that will do this) at full volume and measuring the AC voltage between ground and the left or right channel with a multi-meter.
WARNING: THIS PROJECT INVOLVES WORKING WITH MAINS SUPPLY VOLTAGES THAT CAN SERIOUSLY INJURE YOU OR KILL YOU. BE SURE TO TAKE ALL NECESSARY SAFETY PRECAUTIONS, AND NEVER WORK ON A LIVE CIRCUIT!!
Let’s start by figuring out how much voltage and power your amplifier will need from the power supply. These calculations will tell you the correct voltage and VA ratings for the transformer you’ll use to power your amp. This step is important because if the transformer’s voltage is too low, the output power of the amplifier will be less than what you expected. If the transformer’s VA rating is too small, the amplifier might clip or distort the audio at higher volumes.
Before you can find the required power supply voltage, you need to calculate the amplifier’s peak output voltage.
Peak output voltage (Vopeak) is the maximum voltage measured across the amplifier’s speaker terminals. Your amplifier’s peak output voltage will depend on your desired output power (Po) and speaker impedance, according to this formula:
The amplifier I’m building will be 40 Watts with 6 Ω speakers, so my peak output voltage is:
Now that you’ve found the peak output voltage of your amplifier, you can calculate the maximum supply voltage (Vmax supply). This is the voltage the amplifier needs from the power supply to get the desired output power.
To find the maximum supply voltage, take the peak output voltage and add the voltage drop (Vod) of the LM3886 (4 V). Then factor in your transformer’s regulation and the variation in your mains voltage.
Regulation is the increase in output voltage of a transformer when the load isn’t drawing current (i.e. the amp stops playing music). Regulation values can usually be found in the transformer’s datasheet, but if you don’t know your transformer’s regulation, a safe value to use is 15%. The regulation of the transformer I’ll be using is 6%.
Mains voltages can vary up to 10% depending on your location. It usually peaks late at night when people are asleep and drops in the daytime when more people are awake and drawing current from the power grid.
Use this formula to calculate the maximum supply voltage required by your amplifier:
For my 40 Watt amplifier, the maximum supply voltage it needs is:
So my power supply will need to deliver a peak voltage of ±30.2 V for my amplifier to output 40 Watts into 6 Ω speakers. The ± symbol indicates that the voltage is +30.2 V on the positive rail and -30.2 V on the negative rail.
The next step is finding a transformer voltage rating that can deliver this maximum supply voltage.
Keep in mind that a transformer’s voltage rating only tells you it’s AC voltage output. The DC voltage will be higher after the bridge rectifier diodes on your power supply convert the AC voltage to DC.
To find the maximum DC supply voltage output by a transformer and power supply, take the transformer’s AC voltage rating and factor in a 1.41 increase in voltage from the rectifier diodes, the 10% mains supply variation, and the transformer’s regulation:
I tried the above calculation with a transformer rated at 18 V AC to see if it could supply the 30.2 V maximum supply voltage needed by my amplifier. With an 18 V transformer, I would get a maximum supply voltage of:
29.6 V is pretty close to the 30.2 V maximum supply voltage needed by my amplifier, but let’s calculate exactly how much output power I’d get with this transformer.
To calculate the output power you’ll get from a particular transformer’s voltage rating, use this formula:
Using the maximum supply voltage I calculated for an 18 V transformer (29.6 V), the output power I’ll get is:
38.2 Watts of output power is pretty close to my goal of 40 Watts, so an 18 V transformer will work fine.
Now let’s find a minimum VA rating for the transformer that will power your amplifier.
First you’ll need to calculate the total power (Psupply) required by the amplifier. Total power depends on the maximum supply voltage output by the power supply, the amplifier’s peak output voltage, and the speaker impedance. The formula to use is:
I’ve already calculated the maximum supply voltage of an 18 V transformer (29.6 V), and the peak output voltage of my amplifier (21.9 V). The total quiescent power supply current (QPSC) is given in the LM3886’s datasheet as 85 mA.
So my 18 V transformer needs to supply the amplifier with at least:
The total power can now be used to find a minimum VA rating for your transformer.
To convert the total power to a transformer VA rating, a general rule of thumb is to multiply it by a factor of 1.5:
This is the VA required for each channel, so for a stereo amplifier powered by a single transformer, just double it:
Finding a transformer with a VA of 222 will be hard, but you can round-up to the next closest value and use a 250 VA transformer or larger.
The LM3886 needs a heat sink large enough to dissipate the heat it generates or it will quickly become damaged. The minimum size of the heat sink can be found by calculating its maximum thermal resistance (in °C/W).
First though, you’ll need to know your LM3886’s maximum power dissipation (Pdmax), and the thermal resistances in the path heat takes from the chip die to the ambient air.
The maximum power dissipation is the limit at which the LM3886’s internal SPiKe circuitry is enabled. Sound quality is severely compromised when the SPiKe circuitry is enabled, so to prevent this we need a heat sink with a thermal resistance low enough to dissipate the maximum power dissipated by the LM3886. Pdmax depends on the maximum supply voltage of your power supply and your speaker impedance:
The maximum supply voltage output from my power supply is ±29.6 V, and I’ll be driving 6 Ω speakers, so my Pdmax is:
So my heat sink needs to be able to dissipate 29.6 Watts of power to prevent activation of the SPiKe protection circuit.
There are three resistances to heat flow away from the LM3886:
θjc: The thermal resistance from the chip’s junction (the die) to the case.
θcs: The thermal resistance of the gap between the chip case and the heat sink.
θsa: The thermal resistance from the heat sink to the ambient air.
More power will be dissipated when any of the thermal resistances in the path to ambient air are lowered. θjc is a property of the plastic case enclosing the die, so we can’t do anything to lower that.
θcs can be lowered by using a thermal paste between the chip and the heat sink. Thermal paste has a thermal resistance of around 0.2 °C/W, but the exact value of the type you use should be available from the manufacturer.
The most effective way to reduce the total thermal resistance is by lowering θsa with a more efficient heat sink. Heat sinks with a lower θsa are better at dissipating heat.
The heat sink will dissipate the peak power produced by the amplifier (Pdmax) if its thermal resistance (θsa) is less than or equal to the value calculated with this formula:
The LM3886 is manufactured in two different packages, the LM3886T and the LM3886TF. The LM3886T has a metal flange on the back of the case, and the LM3886TF is all plastic. The plastic case of the LM3886TF gives it a higher θcs:
- LM3886T: θcs = 1 °C/W
- LM3886TF: θcs = 2 °C/W
Tjmax is the maximum junction temperature, or the temperature at the chip’s die above which the thermal shutdown circuitry is enabled. The datasheet gives a value for Tjmax of 150 °C.
Tamb is the ambient temperature in °C that the amplifier will be operated at. A typical value for Tamb is room temperature (25 °C).
So the maximum thermal resistance (θsa) of the heat sink for my amplifier with a Pdmax of 29.6 W is:
So I’ll need a heat sink rated at less than or equal to 2.1 °C/W to ensure it can dissipate the maximum power produced by the LM3886.
Here’s one channel of my amplifier attached to a properly sized heat sink:
Now that you’ve calculated the power supply and heat sink requirements, the next step is to find values for the components in the amplifier circuit. I’ll be using the schematic below. It’s basically the same as the one in the datasheet, but with the optional stability components included:
Note: The components are labeled as they appear in the datasheet.
Here’s a diagram of the LM3886’s pin layout for your reference:
The gain can be set to any value above the LM3886’s minimum of 10 Vo/Vi, but in order to get your desired output power, it needs to be above a certain minimum value. The minimum gain setting of your amplifier will depend on your input voltage, speaker impedance, and output power according to the formula:
I plan on using an iPhone as the audio source for my amplifier, which has an output voltage of 1 V. The output power I’ll get with my transformer and power supply is 38.2 W, and the impedance of my speakers is 6 Ω. So my minimum gain is:
So I’ll need to set the gain to at least 15.1 Vo/Vi if I want 38.2 Watts output power into 6 Ω speakers with a 1 V input voltage.
The gain of the LM3886 can be set by changing the values of resistors Ri and Rf1. These resistors form a voltage divider that determines the voltage at the inverting input (pin 9) of the LM3886:
Setting the gain too high might cause distortion. Setting it too low might make your amplifier too quiet. A good gain setting that’s not too high to cause distortion, but not too low to give you a good range of volume is around 27 to 30 db.
The gain is calculated with this formula:
This gives you the voltage gain (Vo/Vi), or the factor of amplification. To convert voltage gain to decibels (db) gain, use this formula:
Higher value resistors create more Johnson-Nyquist noise, so it’s best to find an Rf1 / Ri ratio that provides your target gain with low resistor values.
I decided on a gain of around 27 db (22.4 Vo/Vi) for my amplifier. To keep the resistances low, I started out by setting Ri to 1 kΩ. Then I rearranged the gain formula to solve for Rf1 with a gain of 22.4 Vo/Vi:
I’m going to use Vishay-Dale PTF series metal film resistors throughout my amplifier, but the closest value I could find was 20 kΩ. But using a 20 kΩ resistor for Rf1 would make the gain:
Which is close enough to 27 db, and above the 15.1 Vo/Vi minimum gain required for my desired output power, input voltage, and speaker impedance.
If you’re building a stereo amplifier, you want Ri and Rf1 to have close resistance tolerances. If these resistors vary much between the two channels, the gains will be different and one channel will be louder than the other. Metal film resistors with a tolerance of 0.1% or less are ideal.
After setting the gain, the next step is to balance the input bias currents by choosing values for Rin and Rb:
If the currents at the non-inverting input (pin 9) and the inverting input (pin 10) are different, a voltage will develop between them. This difference in voltage will be amplified as noise.
The inverting input sees the resistance of Rf1 and the non-inverting input sees the resistance of Rin and Rb in series. You already found a value for Rf1 when you set the gain of the amplifier. The values of Rin and Rb are chosen so together they equal the value of Rf1. This will make the current at the non-inverting input equal to the current at the inverting input. To find values of Rin and Rb for a particular Rf1, use this formula:
I used the value given in the datasheet for Rb (1 kΩ). So with Rf1 at 20 kΩ, the value of Rin that balances the input bias current for my amplifier is:
You’ll probably be able to find a 19 kΩ resistor available with the type of resistors you’re using, but 20 kΩ is the closest value I could find with Vishay-Dale PTF resistors so I’ll have to settle with that.
Cin is in series with the non-inverting input. It’s main function is to block any DC present in the audio source, while allowing AC (the audio signal) to pass. DC in the audio source needs to be blocked or it will be amplified along with the audio signal and create a high DC offset at the speakers. This distorts the audio, which we don’t want for obvious reasons.
In addition to the DC blocking function, Cin and the input resistor (Rin) form a high pass RC filter that sets the low end of the amplifier’s bandwidth at the non-inverting input:
This filter’s cutoff frequency (also known as the -3db point or corner frequency) is the frequency at which the filter starts to work. In a high pass filter, frequencies below the cutoff frequency will be attenuated (muted). In a low pass filter, all frequencies above the cutoff frequency will be muted. We’ll use combinations of low pass and high pass filters to set the amplifier’s bandwidth and improve stability.
The cutoff frequency (Fc) of this filter can be found with the equation:
The equation can be rearranged to find a value of Cin for a particular Fc:
You found the value for Rin when you balanced the input bias currents, so all you need now is to choose a cutoff frequency. The lower limit of human hearing is 20 Hz, so the Fc should be well below that to prevent attenuation of bass frequencies. Lower than 2 to 4 Hz is ideal.
I tend to listen to music with lots of bass, so I decided on a fairly low Fc for my amplifier. I started with 1.5 Hz, but you can use higher or lower values if you want. Just be sure to stay well below 20 Hz or the bass will be weak.
With an Fc of 1.5 Hz, the value of my Cin needs to be:
A 5.3 µF capacitor will be hard to find, but a close value that’s fairly common is 4.7 µF. The Fc with a 4.7 µF capacitor would be:
An Fc of 1.69 Hz is pretty close to my desired 1.5 Hz, so a 4.7 µF capacitor should be good.
Since Cin is directly in the path of the audio input signal, the type of capacitor used will have an influence on sound quality. Electrolytics, ceramics, and tantalum capacitors should be avoided. A good quality polypropylene metal film, or even better a polypropylene metal film in oil capacitor will sound best here.
A second high pass filter exists in the feedback loop with Ri and Ci:
The cutoff frequency of this filter should be 3 to 5 times lower than the Fc of the Cin\ Rin high pass filter at the input. If the Fc of this filter is higher than the input filter, the amplifier will pass low frequencies to the feedback loop that it can’t handle. This will create a voltage across Ci and cause DC voltage to appear at the inverting input, which will be amplified and cause distortion. Therefore, the input filter (Cin and Rin) should determine the lower bandwidth frequency of the amplifier, not the feedback loop filter (Ci and Ri).
The input filter defines the low end of the bandwidth, but Ci still has an effect on the bass response. With smaller values of Ci, the bass will be softer and have less punch, but with larger values of Ci, the bass will be tighter and have more impact.
The formula below will give you a starting point for the value of Ci:
I already found values for Rin, Cin, Rb, and Ri, so the value of my Ci should be greater than:
Rounding up to the next common capacitance value gives 220 µF. Lets see what the cutoff frequency would be with that. We can use the Fc equation with Ri and Ci:
Now I’ll check to see if 0.72 Hz is 3 to 5 times lower than the 1.69 Hz Fc of my input filter:
It’s 2.3 times lower. Lets try some larger values for Ci to see if we can’t do better than that. Repeating the Fc calculation for a 330 µF capacitor gives 0.48 Hz.
3.5 times lower is okay, but I might be able to do even better with a 470 µF capacitor. Repeating the calculations again with a 470 µF capacitor gives an Fc of 0.34 Hz.
A 470 µF capacitor will set the Fc of my feedback loop filter to 4.9 times lower than the Fc of my input filter. This is great, so I’ll use a 470 µF capacitor for Ci.
Ci is also in the audio signal path, so a good quality capacitor should be used. The capacitance will probably be too high to use polypropylene, so you’ll likely have to use an electrolytic. However, there are good quality audio grade electrolytics like the Elna Silmic II or Nichicon KZ series which shouldn’t adversely affect the sound quality.
Rb and Cc form a low pass RC filter that sets the upper limit of the amplifier’s bandwidth at the non-inverting input:
In the datasheet, Cc is shown connected between the non-inverting input and the inverting input. In that configuration, Cc filters radio frequency and electromagnetic interference picked up by the input wires. Unfortunately, it also increases the chance for oscillation. A better way is to connect Cc from the non-inverting input to ground as shown in the image above. That way Cc still filters radio frequencies, but it also acts as a low pass filter that will set the upper limit of the amplifier’s bandwidth.
The Fc of this filter should be set well below the lowest radio broadcast frequency in your area, and well above the 20 kHz upper limit of human hearing. Broadcast radio frequencies in the USA are:
- FM: 87.5 to 108 MHz
- AM: 535 to 1605 kHz
I chose to start with an Fc of about 250 kHz. It’s well below the lowest AM broadcast frequency (535 kHz), so radio frequencies and most electromagnetic interference should be filtered out. It’s also well above the upper 20 kHz frequency of human hearing, so higher audio frequencies won’t be attenuated.
To find a value for Cc that gives an Fc of 250 kHz, I’ll just rearrange the cutoff frequency formula:
Since 636 pF is not a common value, I’ll round up to 680 pF. With a 680 pF capacitor, the Fc becomes:
So a 680 pF capacitor will set the upper cutoff frequency to 234 kHz, which is close enough to my desired Fc of 250 kHz. Cc is also in the signal path, so a good quality capacitor should be used. The best dielectric types for audio capacitors in the picofarad range are silver mica or polystyrene.
Rf2 and Cf dampen resonance in the feedback loop and enhance stability:
Rf1, Rf2, and Cf form a low pass filter in the feedback loop, but as you can see from the formula in the datasheet, calculating the Fc of this filter is quite complicated:
The best way to determine values for Rf2 and Cf is with circuit simulation software such as LTSpice. That’s beyond the scope of this article though, so I’m just going to use the values given in the datasheet.
But if you want to experiment, decreasing the value of Cf will raise the upper Fc of the bandwidth, and increasing the value will lower it.
Csn and Rsn form a Zobel network at the amplifier’s output:
The Zobel network is used to prevent oscillations caused by inductive loads. It also prevents radio frequencies picked up by the speaker wires from getting back into the amplifier’s inverting input via the feedback loop.
At high frequencies, the impedance of Csn is very low, so high frequency current is shorted to ground. Rsn limits the high frequency current so there isn’t a direct short to ground, which could exceed the current limit of the LM3886. Therefore, smaller values of Rsn make the Zobel network more efficient at filtering radio frequencies, but it also increases the cutoff frequency, which in turn reduces it’s effectiveness.
The datasheet gives a value of 2.7 Ω for Rsn, and a value of 100 nF for Csn. This makes the Fc:
589 kHz is fairly high, especially since the lowest frequency of AM radio broadcast is 535 kHz. In order to bring this down to a more reasonable level, I decided on using 4.7 Ω for Rsn and 220 nF for Csn, which lowers the Fc down to 154 kHz:
154 kHz is well above the 20 kHz limit of human hearing, and well below any radio frequencies the speaker wires might pick up.
Since Rsn will need to shunt high currents to ground if the amplifier oscillates, the power rating should be at least 1 Watt. Csn should have low ESR and low ESL, with a voltage rating greater than the rail to rail swing of output voltage. To minimize inductance, locate the Zobel network close to the output pin (pin 4) and keep the traces short.
While the Zobel network reduces oscillations caused by inductive loads, the Thiele network reduces oscillations caused by capacitive loads, usually due to long speaker cables. It also prevents radio frequencies picked up by the speaker wires from getting back into the amplifier’s inverting input through the feedback loop.
Inductors have a low impedance to low frequency current and a high impedance to high frequency current. Audio signals are relatively low frequency, so they will flow through the inductor uninhibited. High frequency oscillation current will be impeded by the inductor and be forced to flow through the resistor, which will dampen it.
The datasheet recommends a 10 Ω, 5 Watt resistor in parallel with a 0.7 µH inductor. In a stereo amplifier, there will be one Thiele network per channel. They should be located away from the amplifier’s input circuitry to prevent interference from the magnetic fields generated by the inductor. A good location is near the speaker output terminals, separated a bit or at 90° angles to each other to prevent magnetic field coupling between them.
The inductors for the Thiele network are wire wound air core types, made by wrapping enamel coated wire (magnet wire) around a cylindrical object. Since the inductor will be carrying the full output current of the amplifier, the wire should be heavy gauge. 12 to 18 AWG would be good. Use this Single-Layer Air Coil Calculator to find out how many turns you need for a particular wire diameter and coil diameter.
Or you can calculate the inductance yourself with this formula:
I used 14 AWG magnet wire in my build since it’s thick and easy to find. The diameter of 14 AWG is 1.62814 mm. I planned on using a screwdriver shaft with a diameter of 11 mm to form the coil. Entering this information into the inductance calculator, I found I’d need about 12 wraps to get a 0.7 µH inductor.
The LM3886 has one negative power supply pin (pin 4) and two positive power supply pins (pins 1 and 5). The negative supply pin needs it’s own set of decoupling capacitors and the positive supply pins share a separate set of decoupling capacitors.
The large decoupling capacitors provide a lasting source of reserve current when the low frequency output of the amplifier is high. Larger values will improve the bass response. Typical values are between 470 µF and 2200 µF.
The medium value decoupling capacitors supply extra current for mid-frequency output. These should be somewhere between 10 µF and 220 µF.
The small value decoupling capacitors provide current very quickly to help the amplifier output higher audio frequencies. They also filter noise and radio frequency interference in the power supply.
The decoupling capacitors also compensate for the parasitic inductance and resistance of the power supply wires and traces leading to the the chip’s power pins. Inductance and resistance inhibit the flow of current, which increases with longer wires and traces. Since the power supply is relatively far away from the chip, inductance and resistance are a problem. To maximize current flow to the chip, the decoupling capacitors should be placed as close as possible to the chip’s power pins.
Capacitors with lower equivalent series resistance (ESR) and lower equivalent series inductance (ESL) are the best types to use here.
Research by Tom Christiansen shows that a 4.7 µF ceramic X7R capacitor in parallel with a 22 µF electrolytic and 1000 µF electrolytic has significantly better performance than the paralleled 100 nF, 10 µF, and 470 µF capacitors recommended in the datasheet. That is what I’ll be using in my amplifier.
Rm, Cm, and D1 form the mute circuit:
When the current flowing out of the mute pin (pin 8) is less than 0.5 mA, the amplifier’s output is muted, and when the current is greater than 0.5 mA, the output is un-muted.
To un-mute the amplifier, we need to find a value for Rm so that the current allowed to flow out of pin 8 is greater than 0.5 mA. That can be found with this formula:
For my amplifier running on a ±29.6 V supply voltage,
So, my Rm will need to be less than 54 kΩ for the current at pin 8 to be greater than 0.5 mA.
Rm and Cm create a time constant that slowly decreases the current at the mute pin when power to the amplifier is shut off, and slowly increases the current when the amp is turned on. The 16 V Zener diode (D1) blocks current flowing out of pin 8 until the diode’s breakdown voltage (16 V) has been reached. This produces a soft start/stop effect that gradually increases or decreases the volume instead of abruptly cutting it.
The time it takes the current to ramp up and down can be adjusted by changing the values of Rm or Cm according to the formula for the RC time constant:
For example, if I want a one second long soft start, I could arbitrarily set Rm to 10 kΩ, then find a value for Cm:
So setting Rm to 10 kΩ, and Cm to 100 µF will give me a one second long soft start.
Now that we’ve seen how to calculate the component values, we can start designing the PCB layout and wiring scheme. If you don’t want do all of the calculations we did above, you can use the values I used. Here’s the final schematic:
Note: The component labels match the labels on the PCB layout provided below. Click on the image to edit the schematic or change component values.
The ground layout of your amplifier has a major effect on sound quality. With a properly designed grounding layout, the amplifier’s output will be completely silent when the source is connected and no music is playing. With a poorly designed ground layout, the amplifier can produce a very noticeable hum or buzzing sound.
The key to a good grounding layout is to keep low current grounds separate from high current grounds. Low current grounds are the ground feeds to the input circuitry and feedback loop. High current grounds are the ground feeds to the power supply decoupling capacitors, the Zobel network, and the speakers. High currents flowing through the low current ground conductors will create a DC voltage that can show up at the amplifier’s input and get amplified as noise.
To separate the low current grounds from the high current grounds, we will create several ground networks:
- Audio input ground: Ground for the audio input cable
- Signal ground: Ground for the input circuitry – Rin, Cc, and Ri/Ci
- Speaker ground: Ground for the speakers
- Power ground: Ground for the power supply decoupling capacitors, Zobel network, mute capacitor, and the ground pin of the LM3886
These grounds should connect only once at a set of terminals called the main system ground. The main system ground is located as close as possible the reservoir capacitors on the power supply. The main system ground will connect to the mains earth wire via a ground loop protection circuit (explained later), and the amplifier chassis.
The individual ground networks are connected to the main system ground so that higher current grounds are closer to the reservoir capacitors. The diagram below shows how to order the ground connections:
The speaker grounds and audio input grounds are routed directly from their terminals on the chassis to the main system ground.
PCB design also has a major influence on the performance of your amplifier. Below I’ll discuss the guidelines I used to design this PCB layout. The PCB is for a single channel, so for a stereo amplifier, you’ll need to build two boards:
Note: The components on the PCB layout match the schematic above. You can click on the image above to edit the PCB layout, change the component footprints, and order PCB’s.
The PCB was designed with EasyEDA’s online design software. EasyEDA is a full suite schematic and PCB design software/manufacturing service that’s free to use and offers great prices on custom PCB manufacturing.
If you click on the “Fabrication Output” button in EasyEDA’s PCB editor, you’ll be taken to a page where you can order the PCB. You’ll be able to choose the copper thickness, PCB thickness, color, and order quantity:
I ordered 5 boards for $17.10 USD and they were delivered in about 10 days. The finished boards look great. All of the traces and printing came out very clean and precise, and there were no defects on any of the boards. Here’s one of the PCBs:
High currents flowing through the power supply and output traces will create magnetic fields that can generate currents in the feedback loop and input traces if they’re routed parallel to each other. This can distort the input signal, so it’s best to keep them far apart or route them at 90° angles. Placing their PCB terminals on opposite sides of the board will make it easier to keep them separate when you route the traces.
Any space between traces of the same circuit will create a loop that can transmit or receive electromagnetic fields. The traces for the power supply feeds and power ground should be routed close together to reduce the loop area. Likewise, the audio input and signal traces should be routed close to each other. An easy way to minimize the loop area is to use ground planes on the bottom layer of the PCB, which I’ve done in this layout.
The power ground and signal ground are the only ground networks on the PCB. Each one has its own electrically isolated ground plane on the bottom layer. Since the power ground carries high currents and the signal ground carries low currents, they’re kept separate until they connect at the main system ground. On the top layer of the PCB, the power supply, output, and Zobel network traces are routed over the power ground plane. The input and feedback loop traces are routed over the signal ground plane. The traces for the power supply feeds were made very wide to minimize the resistance and inductance.
The feedback loop should be kept as short as possible to reduce the loop area. I trimmed the leads of the feedback resistor (Rf1) and soldered it directly to pins 9 and 3 to keep the loop area as small as possible:
Inductance inhibits the flow of current and creates resonance with a capacitor that’s in series. Since inductance increases with trace length, it’s best to keep all traces as short as possible. This is especially important for the power supply decoupling capacitors, feedback loop, input circuitry, and Zobel network. Keep the components for these circuits right up against the chip’s pins so the traces will be short.
We have more tips and tricks on designing PCBs in our How to Make a Custom PCB article, so check that out if you’re interested.
The LM3886 is a Hi-Fi chip amp, so I used high quality audio grade components for my amplifier:
The total cost came to about $118 for both channels, not including the chassis, power supply, and wiring parts. You can build it for a lot less with cheaper components if you’re on a budget, just be sure to change the component footprints in the PCB layout.
Before soldering the components to the PCB, use a piece of fine grit sandpaper to remove any oxidation from the component leads. This will give you a stronger solder joint and better electrical conductivity.
To hold individual components in place while soldering, use a putty like Sticky-Tac on the top side of the PCB. Start soldering the smallest components first, and work your way up to the larger components.
Try to avoid the standard 60/40 tin lead solder and use a 63/37 eutectic solder instead. 60/40 solder has a wide melting range, and when it’s at the lower end of the range it becomes pasty. If the component moves in the pasty phase, it can create a cold solder joint. The smaller melting range of eutectic solder makes the solder set faster and gives a better electrical connection.
Here’s one channel of my amplifier after I soldered the components:
You’ll need an enclosure to keep the PCBs and wires contained and to mount the input, output, and power connectors. Metal enclosures are the best type because they shield the amplifier from interference caused by fluorescent lights, radios, and cell phones. Unfortunately it can be hard to find a chassis that fits everything and looks nice too. After a lot of searching, I found a company called Hi-Fi 2000 that manufactures some really nice metal enclosures. Their website is in Italian, but it can be translated to English. I ordered their 330×280 mm Galaxy model with a 10 mm black anodized aluminum front panel and it looks great:
They also do custom drilling and printing, so I had them customize the back panel:
Before you order a chassis, do a test layout of the transformer, power supply, amplifier PCBs, and heat sinks. Then measure the overall dimensions to make sure the enclosure will fit everything.
After the PCBs have been assembled and you have a chassis, it’s time to wire everything together. The wiring layout is just as important as the PCB layout and grounding layout. Use the diagram below as a guide for wiring the various parts together:
Click on the image to view a larger version.
The goal with wiring is to reduce or eliminate electromagnetic interference between high current and low current wires. The audio input wires and signal ground wires are the most sensitive to interference from surrounding magnetic fields.
The power supply wires, speaker output wires, transformer, rectifier diodes, and AC mains wires are a major source of magnetic fields. To reduce interference, keep the audio input and signal ground wires away from these parts or run them at 90° angles if separating them is unavoidable. If you orient the input side of the amplifier PCBs near the input terminals on the chassis, the wires can be kept short and away from sources of interference.
Any space between the wires of the same circuit will create a loop that can transmit or receive electromagnetic fields. To minimize the loop area, the following sets of wires should be twisted together tightly:
- Hot and neutral AC mains wires from the input terminal to the transformer
- AC zero and secondary voltage wires from the transformer to the power supply
- V+, V-, and power ground wires from the power supply to each amplifier PCB
- Speaker output and speaker ground wires from the amplifier PCB/main system ground to the chassis terminals
- Audio input and input ground wires from the input terminals to the amplifier PCBs
Three power supply wires (V+, V-, and power ground) connect the power supply’s DC output to each amplifier PCB. These wires should be thick, as short as possible, and twisted together tightly. I used 14 AWG, but anything larger than 18 AWG should be fine.
Only low currents flow through the input wires and signal ground wires, so they don’t need to be heavy gauge. I used solid core 22 AWG, which works well because it can be twisted into a tight coil.
Audio input cables running from the source to the amplifier chassis can pick up interference. If this becomes a problem, you can install a 1 nF capacitor between each input terminal ground and the chassis to filter it.
The mains earth wire should be secured directly to the chassis with a bolt and ring terminal. I’d also use a lock nut or lock washer to prevent it from getting loose. All metal parts of the amplifier (like the heat sinks) should be electrically connected to the chassis to provide a path to earth for any mains voltages that could contact them in the event of a fault.
The main system ground connects to the ground protection circuit (discussed below), which then connects to the chassis. The ground protection circuit can connect to the chassis at the bolt where the mains earth wire is connected to the chassis, or at a separate location.
The two Thiele networks are located close to the speaker output terminals. To prevent interference between the inductors, they should be spaced apart or oriented at 90° angles to each other.
Here’s how I installed everything inside my chassis. The right channel PCB is mounted upside down so that the input side of the board is close to the RCA and 3.5 mm input terminals. In this arrangement, the heat sinks provide some shielding from the Thiele networks and the AC wires leading to the transformer:
Click on the image to view a larger version.
GROUND LOOP PROTECTION CIRCUITS MAY BE ILLEGAL IN SOME AREAS. PLEASE CHECK YOUR LOCAL ELECTRICAL CODE OR CONSULT AN ELECTRICIAN BEFORE INSTALLING THIS…
When you connect a powered audio source to your amplifier, magnetic fields from the source’s transformer and power supply wires can be coupled into the ground wires of the audio input cables. This is know as a ground loop, and it can create hum in your amplifier’s output.
A ground loop protection circuit will break the ground loop current:
Under normal operating conditions, low voltage ground loop currents flow through the resistor (R1) to earth (the chassis). The resistor reduces this current and breaks the ground loop. If a high current fault occurs, the fault current can flow through the diode bridge to earth. Note that the chassis MUST be electrically connected to the mains earth wire to prevent mains voltages on the metal chassis in the event of a fault. The capacitor is there to filter any radio frequencies picked up by the chassis.
If a ground loop protection circuit is used, all input and output terminals must be electrically isolated from the chassis. Otherwise, the ground loop protection circuit will be bypassed entirely by the input/output ground wires that connect to the main system ground.
The ground loop protection circuit can be hard wired, but it’s a little neater to mount the components on a PCB. The “PSU 0V” terminal connects to the main system ground. The “Chassis” terminal connects to the chassis:
Click on the image to edit the layout, change component footprints, and order the PCB.
The amplifier I built sounds incredibly good. It’s the best amp I’ve ever owned by far. The bass is very deep and clean. You can really feel it. The highs are clear, but not harsh at all. I can hear details in songs that I never knew were there. Trust me, if you build an amp with the LM3886 you will not be disappointed. It definitely lives up to it’s reputation as a Hi-Fi amplifier. The video at the beginning of the post will give you an idea of what it sounds like.
This should about cover most of what you’ll need to build an excellent sounding Hi-Fi amplifier with the LM3886. Due to the length of this post, I decided not to cover the power supply in detail, but I may do so in the future.
If you’re interested in building other amplifiers, we also have a tutorial on making a 25 Watt amplifier with the TDA2050, and making 10 Watt stereo and bridged amplifiers with the TDA2003 as well.
Thanks for reading… If you have any questions on this build, be sure to leave it in the comments below and we’ll try to answer it. And be sure to like, share, and subscribe if you found this helpful! Talk to you next time…
Sign Up & Get at Least Two $5 Coupons Now: https://jlcpcb.com/quote