High pitched whine in preamp. Oscilaltion?

Started by marcelomd, June 04, 2023, 06:12:47 PM

Previous topic - Next topic

marcelomd

Hi!

I designed a preamp based on the Zvex SHO and Box of Rock. Post here

Using the spare components I modded the circuit to the '59 Sound specs:
- Soldered a 10k in parallel with R5 and R18 for a total of 5k (5kC potentiometer in source);
- Changed C15 and C17 to 10n;
- Changed R22 to 270r;
- Changed R25 to 510k;

There is a high pitched whine. Even with both volumes and gains set to zero.

The unmodded circuit is higher gain and doesn't have this whine.

The oscillation is there even with no other pedals. Just guitar, this preamp and a power amp.

Any ideas? How can I track it?

Thanks!

(I am creating a new post for each question regarding that preamp, is this ok?)

Rob Strand

#1
Does changing setting of RV1 or RV6 have any affect?

I suspect adding the 10k's in parallel with R5 and R18 is what's doing it.  Adding the 10k's actually decreases the gain.

To avoid oscillation is a good idea to put a small values resistor in series with RV1 and RV6, placed near the MOSFET source.  The side effect of the resistor the gain drops a when RV1, RV6 are set to full gain.  The intent of the resistors isn't about reducing gain but to damp parasitic oscillations.

The addition of the 10k resistors in parallel with R5 and R18 also reduces the gain.  So adding the 10k's and the small value resistor will reduce the gain more.  The difference is the parallel 10k resistors affects the gain at both ends of RV1, RV6 where a the small valued gain resistor only affects the high gain end.   So what you want is to keep the added source resistor small as possible and instead of adding 10k in parallel with R5, R18 you add a slightly larger resistor than the 10k

Suppose adding 22 ohm  to the source is enough (it might not be) then place 22k in parallel with R5 and R18 instead of 10k to match the maximum gain.

That's all assuming the first stage going into parasitic oscillation.

It could be something simple.  Maybe try 100uF on the power rail for the MOSFET supplies.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

marcelomd

Thanks for the ideas.

The whine is there even with everything set to minimum. It doesn't appear to change with the gain setting. After a point the "gain hum" (pickups, lack of enclosure, grounding, etc.) is louder than the whine.

The reason I put 10k with the option of 10k in parallel (to get a total of 5k) on the drain is because I have only a few units of 10kC and 5kC potentiometers at home. These are super rare here and sometimes I can get only one or the other.

In this case I put 10k//10k to match the 5kC potentiometer I had for the gain.

Another unit of the same batch got a 10kC potentiometer and no parallel resistor. No oscillation.

I'll try adding a larger capacitor on the V+.

Thanks!

Rob Strand

QuoteThe whine is there even with everything set to minimum.
Very odd for those changes to make the whine.

Also, I didn't quite factor in all your info.  If the Volume pots are off then the noise
much come out from the Q5 and Q6 stages.   

The power supply is the only place that might affect it.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

antonis

Marcelo, mods are made on an already existing (and well working) ciruit or on a brand new one..??
"I'm getting older while being taught all the time" Solon the Athenian..
"I don't mind  being taught all the time but I do mind a lot getting old" Antonis the Thessalonian..

marcelomd

Quote from: antonis on June 05, 2023, 05:32:35 AM
Marcelo, mods are made on an already existing (and well working) ciruit or on a brand new one..??

I got 5 units already assembled from the factory. I mounted the pots and connectors to two of them. One was kept original and one has the mods.


(Sorry about the blurry pictures. I'll take better pictures later today when the light improves)

Quote from: Rob Strand on June 04, 2023, 11:40:16 PM
QuoteThe whine is there even with everything set to minimum.
Also, I didn't quite factor in all your info.  If the Volume pots are off then the noise
much come out from the Q5 and Q6 stages.   

Hmmm does this have anything to do with me getting sound even with gains and volumes set to zero?

Anyway. This is the board. The power supply bits run in the middle of the board. 100n right at the connector, 10r, 3x10uF for bulk decoupling. Then a "long" line to the intermediate stages of the drive channel and a 10u near the output stages.



Thanks guys!

Rob Strand

QuoteHmmm does this have anything to do with me getting sound even with gains and volumes set to zero?
Quite possible all the same route cause. There's plenty of ways that is possible.   It seems like there's subtle problem somewhere.   

So two angles where the whine/signal is coming from: power rail or ground rail.

Try adding a 100uF cap on the power rails.  Try a few different points to see if there's any difference.

Another cause is how the grounds are routed.  Perhaps too much impedance in one of the ground lines.   Maybe check over the grounds going to the volume pots.

It's also possible there is something wrong with the ground wiring.  A simple check would be to look at the DC voltages on ground side of the source resistors.  They should all be at 0V into the small digits, use 200mV scale.  It's worth checking the source voltages and the drain voltages and perhaps the power rail at the top of the drain resistor.   These are only broad checks and probably don't have the resolution to find subtle issues which are audible.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

antonis

I'm not sure if we're talking about this: https://postlmg.cc/LhrZwVmz, with no further mods, but power supply LPF (R13/C9/C10/C11) of 530Hz corner fequency can't be effective..  :icon_wink:
"I'm getting older while being taught all the time" Solon the Athenian..
"I don't mind  being taught all the time but I do mind a lot getting old" Antonis the Thessalonian..

marcelomd

I'll be on the road for a week. I'll try measuring grounds and adding a bigger capacitor when I get back.

I can post the layout if it helps. The bottom side is one big ground plane. No signal traces there. There's also a ground plane on the top side.

Thanks!

marcelomd

Ok. Finally back home, with some time to check this.

TL;DR: Whine is still there even with volumes at zero. I noticed it changes pitch when I change any of the gains.
I can still hear the guitar with volumes at zero.

Quote from: antonis on June 06, 2023, 06:37:59 AM
I'm not sure if we're talking about this: https://postlmg.cc/LhrZwVmz, with no further mods, but power supply LPF (R13/C9/C10/C11) of 530Hz corner fequency can't be effective..  :icon_wink:

Quote from: Rob Strand on June 05, 2023, 07:31:30 PM
Try adding a 100uF cap on the power rails.  Try a few different points to see if there's any difference.

Added 100uF to power rails. Less general noisiness. Whine still there.


Quote from: antonis on June 06, 2023, 06:37:59 AM
lines.   Maybe check over the grounds going to the volume pots.

It's also possible there is something wrong with the ground wiring.  A simple check would be to look at the DC voltages on ground side of the source resistors.  They should all be at 0V into the small digits, use 200mV scale.  It's worth checking the source voltages and the drain voltages and perhaps the power rail at the top of the drain resistor.   These are only broad checks and probably don't have the resolution to find subtle issues which are audible.

Checked with a multimeter. Ground side of R34 shows 0.1V at the 200mV scale. All others are at 0.

Here's the layout. The back side is one big ground plane.




marcelomd

I just noticed a cold solder in the picture in the previous post. Corrected that. No change.

Also noticed the unmodified board has the whine too. Just a bit quieter.

At this point I just want to throw this into the fire.

antonis

"I'm getting older while being taught all the time" Solon the Athenian..
"I don't mind  being taught all the time but I do mind a lot getting old" Antonis the Thessalonian..

marcelomd

Sooo... some progress here.

I'm using this preamp with clean power amp I have here. It's a cheap TPA3118 board from Aliexpress plus buffer, volume control and power filters.

Someone suggested I try the preamp with another amp, or interface. Tried it with my Darkglass Element.

NO oscillation there. Which was totally unexpected. This little amp is usually super silent.

antonis

Some kind of PCB mix-up analog and digital grounds, perhaps..??
"I'm getting older while being taught all the time" Solon the Athenian..
"I don't mind  being taught all the time but I do mind a lot getting old" Antonis the Thessalonian..

marcelomd

I have zero ideas apart from cutting power traces to isolate the problem.

Rob Strand

#15
Quote from: marcelomd on June 13, 2023, 04:55:29 PM
Sooo... some progress here.

I'm using this preamp with clean power amp I have here. It's a cheap TPA3118 board from Aliexpress plus buffer, volume control and power filters.

Someone suggested I try the preamp with another amp, or interface. Tried it with my Darkglass Element.

NO oscillation there. Which was totally unexpected. This little amp is usually super silent.

I suspect the TPA3118 amp has no mains earth connection, or more precisely no AC path from the circuit ground to mains earth, whereas the other amplifier does.   The noise comes from the mains or some device on the mains either in your house or outside the house.   What happens is the noise capacitively couples across transformers/switchmodes onto the power rails, then find a (capacitive coupled) path to ground via the audio input, at which point it gets into the audio signal.

I don't agree with the unsafe way this is done but it demonstrates the idea.
https://www.youtube.com/watch?v=LethXhnlFMg

The reason why it works is the noise finds an easier path down the mains earth than through the capacitively coupled path to ground.

It would be a good test the connect the ground of the TPA3118 ground back to mains earth. Don't do it like the video.   Take an amp which has a mains earth and connect a temporary wire from the chassis or ground on a 6.5mm jack over to the TPA3118.

Sometimes layout can promote this problem but a significant factor is the capacitance between the  HV and LV sides of the power supply (on the TPA3118).   It can be completely unrelated to the design of your board (part values etc.)

Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

marcelomd

This is the little power amp. I power it with a 24V SMPS which looks like a laptop PSU. No mains earth anywhere. I used it with all kinds of preamps, tube based, opamp based and even with a Marshall Jubilee (via send jack).


The input buffer + volume control in it:


The Darkglass Element is an IR cab sim + headphone amp. Standard 9V.

Rob Strand

Not all power supplies with no mains earth connection cause the problem  but they are definitely more likely to have the problem.  It comes down to the finer points of the power supply design.

The most likely cause is the power supply used on the TPA3118 amp.   The whine could even be caused by that power supply.

When you connect the mains earth to the circuit ground it greatly reduces the chances of this type of problem happening.  That's a known solution.  As an experiment it very worthwhile.

It could be something else but by doing that experiment it short cuts a fairly difficult debugging process.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

marcelomd

Tried earthing the power supply and/or the input jack of the little amp. Grounded both inputs.

No change. Still whines.

I'm starting to hack the power tracks.

Rob Strand

#19
Quote from: marcelomd on June 16, 2023, 05:22:06 PM
Tried earthing the power supply and/or the input jack of the little amp. Grounded both inputs.
No change. Still whines.

It's going to be a tricky problem to debug.

And because of this,
QuoteSomeone suggested I try the preamp with another amp, or interface. Tried it with my Darkglass Element.
NO oscillation there. Which was totally unexpected. This little amp is usually super silent.
It's still unclear if the problem is caused by the pedal itself or some external effect.

Quote
I'm starting to hack the power tracks.

Are the metal backs of your pots connected to 0V on the PCB?   If you don't have a metal enclosure which does this by nature you can reduce the risk of noise and weird behaviour by connecting all the pot chassis together then connecting them to 0V on the PCB.  (There could be one or two more sensitive than the others but best to do them all.)
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.