Audio Pcb Layout Techniques

Hi Gootee,
I've been etching pcbs as I go on various projects using the toner transfer method. I've mostly completed a small cnc router, with the intent that I can whip up a layout in eagle and then output code to cut it for me. Hopefully once thats working properly I'll have a workflow that allows time efficient experimentation.

I actually really enjoy the circuit layout side of the designing process. It intrigues me like a complex puzzle that actually has no perfect solution but can be tweaked to be 'best' in a number of different ways. I'm really happy putting hours into what I hope is a good design - although explaining why I think it's an enjoyable challenge is harder :) I guess I'm looking for the 'rules' that guide this part of the process to the best possible result given the constraints.

In a perfect world I'd just build multiple iterations of whatever I'm trying to build and compare empirically as to the improvements, but cost and time prevents this being a viable way forward for most projects. Hence me looking to develop a theoretical background on which to base design decisions on.

In terms of testing finished builds, I've a few older oscopes around - the best of is a 50MHz unit which appears to only have one working channel. Standard probes and ARTA on a pc for testing amp distortion into dummy loads. The sort of equipment you're talking about is beyond my needs, and sadly beyond my understanding as yet :)

You're living the dream, aspringv. Living the dream. I'm jealous of your CNC router. I was on that path once. But life got in the way and I never got back to it. Around that time, I was also doing a few PCB layouts, for kits I had designed. I too really enjoyed doing them. But that was back when I was just starting to try to get back into circuits and I actually wasn't very good at it, because I had no experience and no mentoring. I could make the circuits work fairly well, and even made them robust and stable in certain ways, and could come up with clever ways to fit them onto PCBs, and even greatly enjoyed the puzzle-working aspect of that.

My fairly-rusty EE degree was helpful, but would have helped a lot more if I had known what questions to ask myself, and what to analyze. LT-Spice was a Godsend. And I became extremely proficient with it, in many ways. But again, I didn't really know WHAT to simulate and analyze, in order to be able to generate good PCB layouts. I was trying to learn, but I was also in production mode most of the time.

The fundamental physics that is involved is not too conceptually difficult. And a well-done EE degree gives probably all of the needed tools to even apply it quantitatively. But I also have, for example, woodworking tools. And I can tell you, for sure, that possessing the tools does not make one a master craftsman of fine furniture. (They don't even tell me that such a thing as furniture could exist, if I don't already know.)

I could have tried to imagine all of the possible cases of what electromagnetic theories or equations might apply where, and how. But even if I thought of ALL of the possibilities and how they might apply to circuits on PCBs, although it's possibly a lot better than never having thought about them there would still be a long way to go, because, as often occurs when thinking about the behaviors of complex systems, I still wouldn't know, or even have a good "feel" for, which effects might be significant, and in which situations, and which ones would totally waste my time to even consider them. i.e. I probably still wouldn't have a good estimation of what was important to think about, or which approaches to those considerations would be useful and practical.

Basically, life is too short to make all of the possible mistakes, by yourself. So you need to try to learn from the mistakes of many others.

Even that takes some significant amount of time, before you can feel a little comfortable in the amount of knowledge and experience you have acquired by reading and examining and then applying what others have learned the hard way. "Experience" is also needed. But again, life is too short to go down too many wrong paths in the dark. So I think that you have to spend at least SOME time trying to reach a sort of "critical mass" just by absorbing the "distilled experience" of the many who have come before us.

There is a famous quote about "standing on the shoulders of giants". But if each one stands on the shoulders of all of those who came before them, altogether they will BE a giant. And it should be much quicker and easier to scramble up to the top of their shoulders than it would be to grow that tall, yourself.

Here is one post that I think touches on, in simple terms, examples of a couple of the types of basic areas that need to be considered, in audio circuit design and layout. This is just an example of how you will want to learn to think. But it also serves to point out that WHO you read and listen to is important.

http://www.diyaudio.com/forums/chip-amps/43423-high-cap-unregulated-psu-chipamps-65.html#post1761186

It took me a long time to even think about what was really going on and what was important, in the high-power portions of an audio power amplifier layout, and even longer to then think the right way about it. But in hindsight, it seems obvious and simple. And it helps me to know what layout questions to ask, and how to answer them:

High-power-capable output transistors are used as small-signal-controlled current valves. The small control signal (the music) varies their channel resistance in exact proportion to the music (not considering feedback, yet), allowing current from the power supply capacitors to whoosh through them, to the speakers, with exactly the right amount of current at exactly the right time. The main important action in the PSU is the current, which IS, directly, the music signal that we hear from the speakers. That current almost all comes from the capacitors, either the PSU reservoir caps or the decoupling caps near the output device. There needs to be enough capacitance to sustain the worst-case current amplitude for the worst-case time duration (the time between rectifier charging pulses), or else the current will "poop out" on strong bass tones. But we also require very agile current delivery, for accurate fast transients and high frequencies. Inductance delays the delivery of current so inductance might be significantly bad. Inductance will be caused by conductor length and geometry and layout. We can relatively-easily calculate the minimum required capacitance AND how far away from the power pins it can be (i.e. the maximum tolerable inductance), to still be able to get accurate-enough transient currents, and thus we can FIND OUT how significant that effect is, and what to do about it.

Drawing current causes the capacitor voltages to fall. And drawing current through conductor inductances causes voltage spikes and sags. Both might be significantly bad. Or they might not. But we can decide how much voltage variation is acceptable and then add capacitance and/or lower inductance (e.g. shorten and fatten conductors) until it's "good enough", or maybe even "as good as we want".

I was going to mention feedback and PSRR and how it's possible that the voltage sags don't makes the response non-linear (same small control signal makes same resistance but now maybe PSU voltage across device is different, giving different current; the definition of non-linear!). But there's more-basic stuff that's important, too, and this post is already very long.

Conductors have parasitic inductance and resistance. So currents through them induce voltages across them. Even small currents that are rapidly time-varying can make large voltages across an inductance. So not sending large or fast-varying current through the same conductor that ties your amp input's reference ground to the PSU ground, for example, is basic. It's "star grounding". Using star power AND ground is possibly even better. But much better still would be using full unbroken planes of copper for power rails and grounds.

LOOPS: Faraday's Law (part of Maxwell's Equations) reminds us that a time-varying magnetic field will induce a time-varying current in a conductive loop, and the amplitude of the current, all else being equal or held constant, will be proportional to the geometric area enclosed by the loop. The converse is also true. i.e. A current in a loop will induce a field in the surrounding space. So conductor loops can act as both receiving and/or transmitting antennas. And, they do. In fact ALL of them _ALWAYS_ DO. We can only control "by how much" they do.

(Often-)Unfortunately, for us, "circuit" MEANS "loop". An audio input, for example, with a source plugged in, and with two internal wires leading to an amplifier PCB, usually to both ends of a resistor between a device input and ground (where "device input" could be opamp input pin, triode grid, transistor base or gate pin, etc), MAKES A LOOP.

Leaving any space between the two conductors, anywhere along their entire lengths, will increase the possibility that an electromagnetic field in the surrounding space might induce a current in the conductors. That current would then induce a voltage across every impedance in the loop, such as, the resistor connected between the first active device's input and ground, which happens to be the input for a high-gain amplifier. Combine that with a power transformer, with space between the pair of AC Mains wires coming in, and space between a pair of secondary wires. HUM! Even separating the signal and ground traces on the PCB, between where they connect to the PCB and where they finally get to the input resistor, can allow significant hum.

Everything above still only barely touches on the MOST BASIC of the basic considerations. For example, what about the extemely-high-frequency stuff that the high-speed digital PCB gurus worry about? We are only dealing with audio frequencies, right? Unfortunately, no. RF and high-speed signals can and in fact ALWAYS WILL sneak in from the outside. It's only a question of how much, and what effects might occur to what degree. And since we can't predict the future environment in which our circuits might be operating, we have to assume that there could be significant RF present, at unknown frequencies. Trouble is, "everything's an input", for RF, including the outputs, the feedback loops, the power supply, and, of course, the inputs.

There are many sources of good information about thwarting RF incursion, which besides the obvious effects like hearing AM radio station programs from your speakers, can have subtle and insidious effects inside circuits and ICs, such as slightly shifting the DC operating points of transistor cicuits. Some basic ideas are mentioned in Chapter 7 of ADI - Analog Dialogue | Op Amp Applications Handbook .

Additionally, most of the active devices we use will be quite happy to oscillate or ring at high frequencies, even without any RF present. You have to pay attention to things like the effect of having open traces near IC pins. That's often bad because the tiny amount of parasitic inductance or capacitance could make the IC behave badly. So usually any component that connects to an IC pin should be connected right at the pin, not centimeters away, for example.

Here is another link I saved:

Analog Devices : Analog Dialogue : PCB Layout

Anyway, I'm certainly not an expert at any of this stuff, yet, but I hope that you get the idea.

Do some searches at some of the IC manufacturer sites (ti.com, analog.com, linear.com, maxim.com, and so on, for things like "PCB layout". And google it. Also, I've noticed that adding the word TUTORIAL to google searches can often be very helpful.

And learning LT-Spice well could also be extremely helpful. It's a free download from linear.com . Pay attention to parasitics, in both the components AND the conductors that connect them.

Cheers,

Tom
 
Last edited:
Member
Joined 2010
Paid Member
thank you for taking the time to reply in such depth

Gootee; Wow.

I'll take me a little bit of time to absorb your post (and do the amount of effort you've put into it justice), but I primarily wanted to say thanks for the time and thought you've put into that post. I now appear to have an astonishing amount of reading to do!

I'll reply in depth later today sometime...
 
Last edited:
Member
Joined 2010
Paid Member
working through an example

Marce - thanks for the offer! The last thing I tried to design was a preamp so If I could present that here for discussion would that suffice? If there's a better class of example circuit for working through then please let me know and I'll pull a schematic up from somewhere and work through that

I'd better cast another eye over that preamp pcb though - all of a sudden this is a slightly intimidating audience for my baby steps in pcb design :)
 
Last edited:
Thanks for that Gootee was a Lumberjack:) We are so busy in the bureau, its getting crazy. This is a sad reflection on the UK electronics industry, our gain is other people loss as numerous PCB designers have been made redundant in the last several years as firms tighten their belts.
Interestingly, over the last couple of years, I am seeing more designs where the GND (0V, return) is split into definite power, analogue and digital planes joined either by ferrite beads or a star point. This is becoming more prevalent with our automotive customers, a shift brought on by the recent Toyota problems in the USA.
I look forward to us all playing with a design, it will be fun to do a board for fun and my own enjoyment.
 
That IS interesting! If you were referring to the "sudden acceleration" problem, then it's even more interesting! I have to admit that I pretty-much quit following all news (and all media, actually), well before that, but I remember that many people here assumed that whole affair was probably bogus. (Or maybe it was just me. :) ). To learn that it might have been caused by grounding and power circuit problems, and what has been changed to attempt to fix it, and why, is very gratifying. Can you please say a bit more about the differences between the behaviors of the old and new topologies?
 
Last edited:
Yep, the associated braking problem was not electrical or mechanical, but driver error, saving a lot of money for Toyota.
The actual problem was finally blamed on tin whiskers, I have the 700 page report from NASA (I was working on a project for Cobham/NG and part of the project was an investigation into moving to lead free solder and the implications for Military electronics, so had to read the report!!!). As part of the investigation Keith Armstrong (Cherry Clough Consultants) was also involved looking at the possibility of EMC being the cause, another few hundred pages of exciting reading.
What it did do is make the automotive industry nervous about future problems and the possibility of major law suits, so a lot of the information from both reports was examined and design practices for car electronics were updated and changed (to the extreme) to cover all possibilities for failure. A lot of automotive layout we now do is more stringent than mil/aero and medical, including such practices as all SMD MLCC capacitors doubled up and laid out at 90 degrees to each so that if one cracks under PCB flexing you minimise the chance of a short circuit (these being used for decoupling a short would take out the power, not what you want on say an ABS braking system.
As a result of the Keith Armstrong report a lot of transport based designs are now going back to segregated grounds (not only automotive but also railway systems), this is becoming more common, especially isolating the boards 0V from the main system 0V which as you can imagine can be quite noisy in a car.
Interestingly instrumentation and other areas of design are pretty much one ground for all, though obviously high current areas are separated from low current to avoid the obvious problems that mixing these two can cause.
Over the forthcoming years as more and more devices use RF, power line communication, LCD display etc there will be (there is) a move towards isolating more and more the core circuitry on a board from the rest of the world, ie its IO. This already happens a lot on commercial designs with both EMC and ESD protection on most inputs and outputs, for both incoming problems and to minimise any chances of the equipment transmitting crud to the outside world.
What segregation does mean that we have to be more pedantic with component positions and routing as crossing any barriers in ground planes becomes even more of a no no.
Have Fun
Marc
 
Member
Joined 2007
Paid Member
Hi all,

why dont you post your initial schematic and we can all work through it with you.
Doing layouts is the best way to learn, we train apprentices that way (generaly have a degree or other electronics qualification).

... sounds like a great offer and chance to learn (for me as well)! BTW I've been reading through parts of Henry Ott's book and for a newbie in higher speed PCB layout (me) I find it to be surprisingly straightforward and illustrative. Currently I'm looking into Howard Johnson's High speed Digital design (a handbook of black magic) which to me is also a superb read.

It seems to me that one of the main challenges in PCB layout is the overall signal path lenght and this also relates to the inductance of the capacitors used. To that end different capacitor types (SMDs or leaded) seem have quite different inductances associated with their terminations. Might one of you know of a source for impedance/inductance vs. frequency measurements on high-quality capacitors (e.g. like rubycon ZLH (radial leads) http://www.rubycon.co.jp/en/catalog/e_pdfs/aluminum/e_zlh.pdf

or rubycon SWZ (SMD) http://www.rubycon.co.jp/de/catalog/e_pdfs/pccon/e_SW_NSX_SWZ.pdf)?

Hmmm... Let me know if I'm bumping the thread too much with this question ;-) Otherwise I look forward to following it!

Jesper
 
Last edited:
Some of the capacitor manufacturers have that kind of data on their websites. I forget which ones and lost a lot of links when one of my computers died. I remember that Cornell Dubilier has a Java applet for their electrolytics, which gives plots of C and ESR versus frequency and temperature, and also provides neat frequency and temperature dependent spice models that work for both time and frequency domain simulations. (I realize that's not exactly what you're asking for but wanted to mention it.) But I can't remember which manufacturers had comprehensive impedance data for the small types of caps. Kemet, maybe?
 
I will find a link to a long thread (very long) that covers in some detail bypass (or decoupling) capacitors. Where Gootee, goes into some depth on the maths etc involved. Me I'm a lazy PCB designer and lucky enough to have access to ALL Zukens PCB software tools so I use this:
http://www.algozen.com/DS_CADSTAR_LT_PowerIntegrityAdvanced_ENG_2011_10_05.pdf
I did have to spend a week in Germany learning to use the software, and discussing decoupling caps, planar capacitance and power delivery impendences:( a heavy going week, saved by nice German Beer and food:)
I am just doing a couple of urgent jobs so will be quiet rest of the day, but one of the first things we try to teach budding PCB designers, is:
PCB design is always a compromise, you have restrictions on layers, size, connector positions, technology (cost sometimes) and many other factors, so if you cant get the perfect textbook so9lution don't worry, their are many other options that will do the job. The skill comes in knowing which bits of circuit can be compromised and which cant. SMPS, clock circuitry etc you need to get near as perfect as possible, DDR memory interfaces must be perfect, but other digital that is lower speed, general IO etc you can relax the rules a bit. I don't mean you can cut corners, but do the best layout that the circumstances dictate.
One interesting thing we did learn on the PIA course was how ineffective decoupling caps are above 20MHz (it is the power plane and on chip capacitance that provide the first level of charge). You still need the decoupling and reservoir caps to control the overall power system impedance.
Some hi-tech boards are built with high planar capacitance which allows the removal of a lot of decouplers, this nest link illustrates better, and I'm going to work:(
Have fun
http://www.laocsmta.org/archive/Embedded_Capacitance_Presentation.pdf
 
Member
Joined 2010
Paid Member
Hi all, apologies for going quiet on this thread, just when its getting interesting! Im away on a trip at the moment and away from my computer for at least the next 10 days. Im quite eager to get stuck into a design example when I get home. Thanks again all!
 
Member
Joined 2010
Paid Member
And we're back

Hi All, I'm back from a quick jaunt interstate, and keen as mustard to jump into this.

First a question - what will serve best as a learning example for everyone that's chipped in with interest so far? I'll put my most recent project up for dissection but I'm happy to defer to other interested parties should there be more learning potential in a different design.

And finally - how best to facilitate tweaking a layout? I use eagle, and I assume passing a gerber back and forth is the easiest way to exchange the layouts? Or is there a better way?
 

Attachments

  • SStart.pdf
    17 KB · Views: 279
Member
Joined 2007
Paid Member
Hi - & welcome back ;)

I've actually been looking forward to this thread - and where it may go - in the time since the last posts. Hopefully without interfering with the OP's wishes I have a project suggestion that I reckon could be interesting to others as well as it combines many different frequency areas and domains:

- It is a pcb layout for the ESStech ES9102 ADC or for the TI PCM 4202 (or similar). It combines analog circuitry layout & digital circuitry layout (including clock placement considerations, digital data transmission), as well as possibly a venture into which components could be feasible to use in the various parts of the circuitry.

And finally - how best to facilitate tweaking a layout? I use eagle, and I assume passing a gerber back and forth is the easiest way to exchange the layouts? Or is there a better way?

Eagle is fine with me - it is my impression that it is more or less the de facto standard with DIYs for PCB layouts ... ? I've heard, though, that KiCAD is also used where more board layers are desired as the freeware version of Eagle only allows for two layers.

- And then I have one more suggestion and that is that the first post in this thread is used some kind of "library" of what has been talked about in the various posts in the thread. That could be literature mentioned, links to other key threads, key component links, key posts in the thread, or ...? The idea is - in a short form - to make it accessible for others starting up with the thread to quickly find key information. Apart from maybe suggesting additions to this first post I do, however, realize that I will not be doing this work so entirely up to aspringv ;)

Whatever becomes the object of a layout I'm genuinely interested:)

Greetings,

Jesper
 
Last edited:
PDF of the layers is the best way then everyone can have view the data. I am just recovering from a holiday(!).
I have had a quick look at the schematic and will look in more detail later.
One thing I will state now, where possible I always advocate ground planes if costs etc permit, some audio experts here have argued long and hard with me over ground planes. At the bureau I work at, and places where I have worked in the past where I have done low level analogue and audio design (mainly professional) we have always used ground planes for the best signal integrity and robust design in the face of RF/EMC immunity.
Gentlevoice I plan to duplicate any design we do on Cadstar, it will be the best way of discussing points, and it will be interesting to see how different people approach component placement (the most important skill a PCB designer can develop) and routing.
As with PCB design especially there is always more than one way to lay out a board and it still work, until you get to DDR memory, gigabit Ethernet and SMPS's where the data and rules provided are thereto be followed, and it is stupid not to follow the data sheets.
 
One of the most critical aspects of ECAD and PCB design is the quality of your library parts information and footprints. The following document is an excellent starter for library information, and details a lot of information that is part of the IPC-7351 standard. (THe IPC is a source of lots of PCB related information and standards).
http://www.dnu.no/arkiv1/The CAD Library of the Future.pdf
http://pcdandf.com/cms/images/stories/mag/0502/0502hausherr.pdf
The IPC-7351 footprint library is used globally now by most companies involved in electronic production and design, including most big firms you can think off.(I know for certain for a few cos I have done their libraries).

The attached document is MY generic manufacturing instructions for manufacturers, it is useful as it lists the relevant IPC spec for each process (solder resist, base laminate etc) so gives a basis for extra research if anyone is so inclined. Also it can be manipulated to form the basis for your own manufacturing documentation, just acknowledge the author (Marc England).
Another important aspect (and a bit boring) is issue control of your designs, even though its DIY and you may not do a lot of design work, using issue control and documenting the design history (at each issue step) will help build a knowledge base for your designs and avoid **** ups with data or using old design with say an incorrect footprint.
I'll shut up for a bit::D
 

Attachments

  • PCB manufacturing instructions.doc
    84.5 KB · Views: 306
  • Issue Control of PCB Assembies.doc
    34.5 KB · Views: 206
Last edited: