Prototype PCB troubleshooting - Audio preamp

Ian0

Joined Aug 7, 2020
13,132
I wondered about this, I'll test it out. Help me understand the purpose of C28 and C25 below, and how to size them. C28 is a coupling cap, blocking DC but not AC. Is C25 the same?

View attachment 364309
It keeps someone busy soldering a few components. Electrically it doesn't do anything.
Screenshot from 2026-03-06 20-09-12.pngThere's a very marginal difference in the frequency response below 1Hz, less than the variation due to tolerance on the capacitor.
At low volume settings it gives a boost to frequencies in the 0.1Hz to 1Hz region - like fret noises, noises due to dropping the guitar on the floor etc!
You're probably copying from a bit of a second rate design. Whoever designed it got his Sallen & Key filter wrong, as I mentioned in an earlier post.
 

Thread Starter

rpschultz

Joined Nov 23, 2022
812
I'll be curious to hear what you think of the testing with a guitar. Did you base your design off an existing product, or are you hoping to have something novel? In other words, what were the design goals?
The original intent 2.5 years ago was, I didn't want to have to pay $600 for a Grace Designs Alix, which is now $842. Very similar functionality, I have a Q knob for the Notch that Alix doesn't, but don't have an FX loop and DI out (that could easily be added later). I started with a Fishman Mini schematic and added the 3 knob mid sweep from ESP State Variable design and LPF/Notch. Grace Designs also uses higher quality op amps than the TL074 series but I've tested the OPA's and I can't hear a difference. Similar headroom, they run at +/-18v, I run at +/-15v.

Along the way, I've learned a ton about electrical engineering (I'm a mechanical engineer), lots and lots of spice simulations, oscilloscopes, AWG's, bode plots, PCB layout, etc. It's a hobby. I'm a guitarist. Loads of fun learning. The 2nd prototype has been on my pedalboard for many months, it works well. This 3rd one was mainly to learn EasyEDA and venture into 4-layer boards.

In a similar vein, a friend of mine and I designed a DIY Tuner kit in the past year.
 

Thread Starter

rpschultz

Joined Nov 23, 2022
812
It keeps someone busy soldering a few components. Electrically it doesn't do anything.
There's a very marginal difference in the frequency response below 1Hz, less than the variation due to tolerance on the capacitor.
At low volume settings it gives a boost to frequencies in the 0.1Hz to 1Hz region - like fret noises, noises due to dropping the guitar on the floor etc!
You're probably copying from a bit of a second rate design. Whoever designed it got his Sallen & Key filter wrong, as I mentioned in an earlier post.
I see the negligible difference between 10u and 1u, that would be an easy fix. But you're saying there's no need for a coupling cap there Removing them all together would be nice! Is that a safety feature or something? Why would there EVER be DC voltage on the signal line... because if there was, it would sound TERRIBLE... not even terrible, just a loud buzz.
 

Ian0

Joined Aug 7, 2020
13,132
DC on the signal line is usually due to accumulation of offsets from a chain of op-amps. If the gain is not rolled off below 20Hz, then it gets multiplied by the gain at every stage.
And DC doesn't sound like buzz, DC is silent, apart from the loud click when the jack is plugged in.
If allowed to propagate as far as the loudspeaker if is an off-centring of the voice coil in the gap.
The SPICE simulate shows the difference between 10uF and 1fF.
You can take out the R4 C1 network it doesn't do anything.
But keep the coupling capacitor.
 

skstrobel

Joined Nov 29, 2023
28
It's an inverting amplifier. The inverting input is a virtual earth.
Don't forget that the job of an op amp it to keep its two input pins at the same voltage, and it seems as though it has succeeded perfectly.
Exactly! Even though the op amp inputs have the same voltage, the signal still exists on the net connected to pin 6 as a current.

To elaborate a bit more, if the op amp has negative feedback (as this one does through the gain pot) and it isn't saturated, the inputs should have the same voltage. With pin 5 connected to ground, that means your scope is just going to show ground on pin 6. But by measuring the voltage on the other end of any resistor connected to that net, you can easily determine the current flowing into or out of that net through the resistor. Note that pin 6 won't sink or source any significant current (it is a high impedance input), so any current entering that net has to leave the net in another way.

For example, if at some instant the voltage on the left side of R12 is 4.7mV (to make the math easy), 1uA will flow through R12 (Ohm's law). Ignoring C11 for the moment, the op amp will notice the voltage at pin 6 start to rise and try to counteract it by driving the voltage at pin 7 negative by maybe a million times more (whatever the open loop gain for that amp is, you can assume infinity in most cases). The output voltage will continue to go more negative until the voltages at pin 6 and 7 match again, which will happen when the 1uA of current entering the pin 6 net through R12 gets pulled out of it through the gain pot. If the gain pot is set for 20K, that will happen when the op amp's output voltage is -20mV (Ohm's law again). Note that the voltage gain is -20mV/4.7mV = -4.25, which is exactly what you would predict based on the ratio of resistances: 20K/4.7K. Increasing the resistance of the gain pot increases the gain because the op amp has to work harder to cancel out the current flowing through R12. C11 rolls off the high frequencies because it makes it easier (requires less gain) to cancel out the current for high frequencies.
 

MisterBill2

Joined Jan 23, 2018
27,524
HERE IS AN ANSWER about DC on a signal line, and what it does! At least in theory!!

The normal intention is for the quiet voltage on a signal line to be midway between CUTOFF and SATURATION, which are the defined ends of the linear segment of operation. Usually the intended operation is only a portion of that voltage range. A published standard, long ago, was based on the common practice of analog circuits using supply voltages of +15 and -15 volts, with the signal voltage between +10 AND -10 VOLTS, because early op-amps were not so good towards the supply voltages. So as the DC level of the signal voltage drifted away from "zero", the signal peak voltages would enter the ranges where there was distortion that would become extreme and cutoff (flat-topping) and saturation.

This can be a bigger challenge as the supply voltages become lower and lower.
I hope that this explanation is not excessively off topic. My apology if it is.
 

Thread Starter

rpschultz

Joined Nov 23, 2022
812
So in your example, coupling caps, are to prevent clipping, historically. But if there’s plenty of headroom on the signal vs supply, then they aren’t necessary?
 

panic mode

Joined Oct 10, 2011
4,985
First picture, all the GND's in this section of the schematic, list as GND net in the properties tab over on the right, the one under R34 is selected here....
Aha, so unless it is marked as global GND, it will be a GND that is local to current sheet and thus different/isolated from global GND. this is something rule check should warn about unless one explicitly disables that check.
 

eetech00

Joined Jun 8, 2013
4,705
So in your example, coupling caps, are to prevent clipping, historically. But if there’s plenty of headroom on the signal vs supply, then they aren’t necessary?
“coupling caps” imply interstage coupling of an audio signal between stages. Sometimes there are dc voltages existing around an audio stage that should not seen by the previous or next stage. The coupling cap blocks the dc while passing the audio signal between the stages.
Some times dc is needed to pass between stages, like a bias voltage used to keep audio at vcc/2 when using a single supply opamp.
 

MisterBill2

Joined Jan 23, 2018
27,524
Coupling capacitors certainly reduce the effort required to assure adequate DC voltage matching between stages. That is quite a challeng when using non-perfect components. (That is, components that do not exhibit any changes as the temperature varies.)
 

Thread Starter

rpschultz

Joined Nov 23, 2022
812
I finally fixed all the PCB issues and got it working. Here's a Bode plot, HPF at about 90 Hz and mid cut around 265 Hz.
Thanks for all the help!

1773502693707.png

1773503369736.png

Side bar: The combination of the Siglent SDS804X HD and the SDG1022X Plus AWG to create Bode plots is freakin amazing. I use it a lot. I remember in college (early 90's), we created Bode plots in my circuits class, by HAND! It was so tedious. I feel lucky that these 2 pieces of equipment (I bought for ~$800 total in last 2 years) can do this. But this capability has only been available for ~10 years??? How did people make Bode plots before the newer scopes and AWG's could talk to each other like this?
 

Thread Starter

rpschultz

Joined Nov 23, 2022
812
Please share the solution.
1. Designing/installing D2 backwards was bad (see this thread), it blew a number of coupling caps and possibly other stuff too. I never got it working and eventually moved on and assembled a new one, knowing that it had all new caps.
2. Three op amp grounds, were not grounded. This was a weird situation in EasyEDA, see post #17. At this point I got signal all the way through...
3. ... but some of the audio functionality wasn't right (Bode plots). I missed 3 connections within HPF, Parametric Mid and High when I copied schematic from Eagle to EasyEDA. (EasyEDA is so much better than Eagle in most ways)
4. Based on this thread, post #18 @eetech00 suggested changing the 10u polarized coupling caps to 1u film. I agree, film caps are better for audio signal, so 5 electrolytic caps were changed to 1u film.
5. Also based on this thread, I removed C25, R31 (volume) and C44, R46 (boost) based on post #21 @Ian0 suggested to remove them. Tests fine.
6. After fixing all the above, and doing extensive Bode plot testing, I realized that the Notch Q knob was backwards.

So all the above got fixed in EasyEDA (and a few other minor labeling/layout type stuff), and I sent updated files to JLC. Should have the next round in 3 weeks or so.
 

Thread Starter

rpschultz

Joined Nov 23, 2022
812
It keeps someone busy soldering a few components. Electrically it doesn't do anything.
View attachment 364316There's a very marginal difference in the frequency response below 1Hz, less than the variation due to tolerance on the capacitor.
At low volume settings it gives a boost to frequencies in the 0.1Hz to 1Hz region - like fret noises, noises due to dropping the guitar on the floor etc!
You're probably copying from a bit of a second rate design. Whoever designed it got his Sallen & Key filter wrong, as I mentioned in an earlier post.
I began to notice some differences in low end behavior (measured Bode plots) between the latest prototype with the 10u's coupling caps replaced with 1u, and an older prototype all with 10u coupling caps. So I went back to spice to check this out, this is effectively the same circuit as post #1. I can adjust various pots and resistor values to mimic the posts/switches on the actual device.

1773602070315.png

I found that the coupling caps (in spice model above) C9, C25, C26 need to be 10u. If I change them to 1u, the low end (<250 hz roughly) is less. Depending on how I do the rest of it (HPF, Notch, Mid, etc), it can be anywhere from 0.3 to 3 db loss in the low end. The high end doesn't seem to be affected. C20 and C30 are also coupling caps, but they aren't related to a frequency circuit, these are just basic volume op amps and so 1u seems fine there. Because this model seems to reflect what I'm measuring, it seems good to leave them at 10u.

I'm guessing that these coupling caps are acting as a HPF, somehow? I'm not sure what R is though, and I'm not sure what the cutoff frequency is... I just know that the low end is affected.
1773602607391.png
 
Last edited:

Ian0

Joined Aug 7, 2020
13,132
When you have a lot of coupling capacitors, the effect is cumulative, and it's easily overlooked, when each individual one seems to be large enough.
 

MisterBill2

Joined Jan 23, 2018
27,524
Consider that very few of us non-audiophiles can hear one hertz, or even ten hertz, what does it matter in a sound system?? It could be important in an instrumatation system though.
 

Ian0

Joined Aug 7, 2020
13,132
Consider that very few of us non-audiophiles can hear one hertz, or even ten hertz, what does it matter in a sound system?? It could be important in an instrumatation system though.
You can probably hear it indirectly if it is large enough and moves the speaker cones out of the magnetic gap.
 
Top