CD4007-Based Distortion Humming Issue

Started by Baran Ismen, February 07, 2024, 02:50:04 PM

Previous topic - Next topic

Rob Strand

Couple of fixes:



The layout actually doesn't match the schematic because the tone control has been removed.

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

Baran Ismen

Quote from: Rob Strand on February 09, 2024, 09:45:03 AMCouple of fixes:



The layout actually doesn't match the schematic because the tone control has been removed.



Like this, the drive pot acts pretty much the same as guitars volume pot, right?

Rob Strand

#22
Quote from: Baran Ismen on February 09, 2024, 12:43:23 PMLike this, the drive pot acts pretty much the same as guitars volume pot, right?
Only very roughly.

The Drive control on that unit has some behaviour which is different:
- At low drive settings there is less low cut
- At low drive settings below about 20% of full the circuit starts
  to roll-off the highs.

The intent of the Drive control is to reduce or control the gain of the first
stage.  However, in lower the 20% it has other side effects.  I'm note sure if
second point is an oversight or not. 

The thing about varying the gain, as per the original ckt, is it should be
less noisy at lower drive settings than having the circuit at maximum gain then
backing off the guitar.   If you have layout or wiring issues which let
extra noise from outside  those issues will undermine any improvements
by varying the gain.

Your mod is messing with bias. I'd need to redraw it in detail
to follow it but it does look a bit weird.

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

R.G.

I was just running through the string of posts. Is pin 3 open or connected to the wiper in the most current incarnation or not?

Baran, you're right that every single CMOS input pin, whether the section of the IC is used or not, absolutely must be tied to some fixed voltage reference. The mains-frequency field that surrounds us in modern buildings can supply enough current/voltage through meters of air to drive the even-higher impedance of a CMOS gate.

Hmm. Second question; have you tried a different pot for the drive control? Could be a high-impedance wiper connection, maybe.
R.G.

In response to the questions in the forum - PCB Layout for Musical Effects is available from The Book Patch. Search "PCB Layout" and it ought to appear.

Rob Strand

#24
Quote from: Baran Ismen on February 08, 2024, 03:32:39 PMOne rule I've read today -which I also violated here- is that no pins should be left floating on any CMOS chips, but in my case, pin 3 of the chip (Gate 2) became unused. Any ideas are most welcome

By disconnecting pin 3 what you have done is disable the whole first stage and at the same time reduced the gain of the second stage. A voltage divider on pin 1 might also been formed.    All those are going to reduce the gain the circuit considerably, so obviously it's going to be less susceptible to noise ...but... the circuit is nothing like it was before.

Actually the connection of pin 2 to Vdd will completely kill the signal!

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

Baran Ismen

Ill go thru this tomorrow again and let you guys know, i was busy with redoing my pedal board this weekend.

Baran Ismen


Baran Ismen

#27
So, this is getting out of hand; added clipping diodes with a 6-way rotary and the result is quite flexible yet good! I tried them all and all sounded good, so decided to keep them all  :icon_lol:

But a bit unsure about whether the switch wiring is correct or not, would I need a 2P6T sw or 1P6T would work?





Rob Strand

#28
Quote from: Baran Ismen on February 12, 2024, 12:14:27 PMI made a video, hope it explains.sorry for the shakings.

I think what you have done is OK.  It just removes the first stage.  It will reduce the gain bit it will still work fine as a pedal.

The short answer would be:
- leave pin 3 grounded
- you should disconnect pin 1 from the cap C3 then
  leave the pot wiper connected to C3.
That would be the correct way to bypass the first stage.

Near the end of the video:
- When you remove the pot that's OK.  It should work.
- When you connect to pin 3.  It is not expected to work
  or sound good.  It's wrong to connect the signal to pin
  3 because you are missing R1 and the Drive pot.  In order
  use pin 3 and pin 1 you need to connect the parts like
  the original circuit.

A couple of small points:
- The C4 cap and diode D1 aren't connect correctly in the video.

Here's what I see in the video.  I've added some notes to it.



Direct link:

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

Baran Ismen

Quote from: Rob Strand on February 12, 2024, 02:42:21 PM
Quote from: Baran Ismen on February 12, 2024, 12:14:27 PMI made a video, hope it explains.sorry for the shakings.

I think what you have done is OK.  It just removes the first stage.  It will reduce the gain bit it will still work fine as a pedal.

The short answer would be:
- leave pin 3 grounded
- you should disconnect pin 1 from the cap C3 then
  leave the pot wiper connected to C3.
That would be the correct way to bypass the first stage.

Near the end of the video:
- When you remove the pot that's OK.  It should work.
- When you connect to pin 3.  It is not expected to work
  or sound good.  It's wrong to connect the signal to pin
  3 because you are missing R1 and the Drive pot.  In order
  use pin 3 and pin 1 you need to connect the parts like
  the original circuit.

A couple of small points:
- The C4 cap and diode D1 aren't connect correctly in the video.

Here's what I see in the video.  I've added some notes to it.



Direct link:



Well, if this is the gain from 2 stages, then I can't imagine when the 3rd one is included, as its already massive and I can live with it totally.

I've made some changes on paper by heart, I'll give them a try tonight over the board. If it won't work, I'll proceed as it is now.

Rob Strand

#30
Quote from: Baran Ismen on February 13, 2024, 03:14:15 AMWell, if this is the gain from 2 stages, then I can't imagine when the 3rd one is included, as its already massive and I can live with it totally.

I've made some changes on paper by heart, I'll give them a try tonight over the board. If it won't work, I'll proceed as it is now
Yes, some pedals out there have a crazy amount of gain.

When you make high gain pedals it's a good idea to put a metal sheet connected to the circuit 0V underneath the breadboard.  You can even use a sheet of aluminium foil from the kitchen.  Also it's good idea to connect the metal chassis of the pots to the circuits 0V.   It can prevent a lot of mains buzz getting into the circuit.  In some cases it can even prevent the circuit from going into crazy oscillations.

There's better ways to do it, you can see this post and the post that it links to,
https://www.diystompboxes.com/smfforum/index.php?topic=121136.msg1137140#msg1137140

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

Baran Ismen

Quote from: Rob Strand on February 13, 2024, 04:15:19 AM
Quote from: Baran Ismen on February 13, 2024, 03:14:15 AMWell, if this is the gain from 2 stages, then I can't imagine when the 3rd one is included, as its already massive and I can live with it totally.

I've made some changes on paper by heart, I'll give them a try tonight over the board. If it won't work, I'll proceed as it is now
Yes, some pedals out there have a crazy amount of gain.

When you make high gain pedals it's a good idea to put a metal sheet connected to the circuit 0V underneath the breadboard.  You can even use a sheet of aluminium foil from the kitchen.  Also it's good idea to connect the metal chassis of the pots to the circuits 0V.   I can prevent a lot of main buzz getting into the circuit.  In some cases it can even prevent the circuit from going into crazy oscillations.

There's better ways to do it, you can see this post and the post that it links to,
https://www.diystompboxes.com/smfforum/index.php?topic=121136.msg1137140#msg1137140


This is a good idea because I've experienced during breadboarding some weird grounding issues. It was like, when I  touch my hand on the table -without touching anything else and sitting on a chair- the humming was gone for a second. An insulator for the bottom side is a good idea!

Rob Strand

Quote from: Baran Ismen on February 13, 2024, 05:18:12 AMThis is a good idea because I've experienced during breadboarding some weird grounding issues. It was like, when I  touch my hand on the table -without touching anything else and sitting on a chair- the humming was gone for a second. An insulator for the bottom side is a good idea!
When you do this for a while, you know you need a better set-up.  You quickly find those plastic breadboard with no shielding are just too noisy.   Having the 6.5mm jacks, pots, and switches on a metal panel makes life so much easier.   Poking pots into the breadboard can damage the breadboard.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

duck_arse

" I will say no more "

Baran Ismen

#34
Quote from: duck_arse on February 13, 2024, 07:53:51 AMhappy birthday, Baran.

Cheers much, man!

I have been dealing with this and surprisingly saw that, for some reason, the initial layout somehow worked, and i have literally no idea how. Everything is same as it was (supposedly). Now its working heavier than before. Also a side note, both buffered and unbuffered 4007 chips are working and they are equally as good.

Ill amend the schematics tomorrow as ill try some different caps and resistors here and there to find a sweet spot.




Baran Ismen

Here's the latest version. Will try some stuff indeed, but this one working just fine.



I wonder now, whether it's possible to add a 3-position slider switch to activate the 1st, 2nd, and 3rd stages of the transistors so that it'll act like sort of a gain switcher apart from the gain pot. It should be powering the transistors as 1, 1-2, and 1-2-3. Theoretically, it's possible but in practice, I'm not sure how to do the connections and what type of slider switch I should use. I can't find any on-on-on switches here in Turkey, only slider types are available.

amptramp

There are good reasons to have plenty of filtering for a CMOS-based analog effect.  When the CMOS gate is at either a high or low level, the power supply current is almost negligible.  But if you feed an analog signal to it, as the signal goes through the midpoint (0.5 x Vcc), each gate takes about 8 mA.  If you have a number of these in series, that is a significant current and there may be some modulation of the supply voltage.  That is more current variation than a typical op amp takes as it goes through its voltage swing.  If you have a CD4049 based effect, that could be 48 mA.  Is your supply ready to handle that kind of variation?  The effect of this variation would be like a distortion where the signal drops slightly as it goes through zero, but the drop is the same whether you are coming down or going up.

Rob Strand

#37
Quote from: amptramp on February 19, 2024, 09:31:04 AMThere are good reasons to have plenty of filtering for a CMOS-based analog effect.  When the CMOS gate is at either a high or low level, the power supply current is almost negligible.

That's why I suggested the series resistor on the power rail.

Quote from: amptramp on February 19, 2024, 09:31:04 AMBut if you feed an analog signal to it, as the signal goes through the midpoint (0.5 x Vcc), each gate takes about 8 mA.  If you have a number of these in series, that is a significant current and there may be some modulation of the supply voltage.  That is more current variation than a typical op amp takes as it goes through its voltage swing.  If you have a CD4049 based effect, that could be 48 mA.  Is your supply ready to handle that kind of variation?  The effect of this variation would be like a distortion where the signal drops slightly as it goes through zero, but the drop is the same whether you are coming down or going up.
In this pedal the first two stages break the push-pull output stage with a 10k resistor.  In effect the n-channel MOSFET to ground doesn't do much (a switch to ground) and the gain is like a p-channel class-A amplifier with a 10k drain resistor.   The current draw on these stages is pretty low (less than 1mA).

Only the last stage retains the push-pull drive.  I suspect the current draw is pretty low for this stage maybe 2mA or 3mA - but I haven't verified it by measurement.

Quote from: Baran Ismen on February 19, 2024, 08:16:09 AMHere's the latest version. Will try some stuff indeed, but this one working just fin

It's more or less the original circuit now.  I'm not sure why your first build had issues.

Quote from: Baran Ismen on February 19, 2024, 08:16:09 AMI wonder now, whether it's possible to add a 3-position slider switch to activate the 1st, 2nd, and 3rd stages of the transistors so that it'll act like sort of a gain switcher apart from the gain pot. It should be powering the transistors as 1, 1-2, and 1-2-3. Theoretically, it's possible but in practice, I'm not sure how to do the connections and what type of slider switch I should use. I can't find any on-on-on switches here in Turkey, only slider types are available.

What about a rotary switch.

The last stage driving the tone control is different to the other stages.  Not sure if it would work OK being fed by the first or second stages.

If you switch out the first stage you will lose the gain control.

Maybe switching out the second stage is a better plan.   Certainly much simpler.
Send:     . .- .-. - .... / - --- / --. --- .-. -
According to the water analogy of electricity, transistor leakage is caused by holes.

Baran Ismen

Quote from: Rob Strand on February 19, 2024, 05:44:14 PM
Quote from: amptramp on February 19, 2024, 09:31:04 AMThere are good reasons to have plenty of filtering for a CMOS-based analog effect.  When the CMOS gate is at either a high or low level, the power supply current is almost negligible.

That's why I suggested the series resistor on the power rail.

Quote from: amptramp on February 19, 2024, 09:31:04 AMBut if you feed an analog signal to it, as the signal goes through the midpoint (0.5 x Vcc), each gate takes about 8 mA.  If you have a number of these in series, that is a significant current and there may be some modulation of the supply voltage.  That is more current variation than a typical op amp takes as it goes through its voltage swing.  If you have a CD4049 based effect, that could be 48 mA.  Is your supply ready to handle that kind of variation?  The effect of this variation would be like a distortion where the signal drops slightly as it goes through zero, but the drop is the same whether you are coming down or going up.
In this pedal the first two stages break the push-pull output stage with a 10k resistor.  In effect the n-channel MOSFET to ground doesn't do much (a switch to ground) and the gain is like a p-channel class-A amplifier with a 10k drain resistor.   The current draw on these stages is pretty low (less than 1mA).

Only the last stage retains the push-pull drive.  I suspect the current draw is pretty low for this stage maybe 2mA or 3mA - but I haven't verified it by measurement.

Quote from: Baran Ismen on February 19, 2024, 08:16:09 AMHere's the latest version. Will try some stuff indeed, but this one working just fin

It's more or less the original circuit now.  I'm not sure why your first build had issues.

Quote from: Baran Ismen on February 19, 2024, 08:16:09 AMI wonder now, whether it's possible to add a 3-position slider switch to activate the 1st, 2nd, and 3rd stages of the transistors so that it'll act like sort of a gain switcher apart from the gain pot. It should be powering the transistors as 1, 1-2, and 1-2-3. Theoretically, it's possible but in practice, I'm not sure how to do the connections and what type of slider switch I should use. I can't find any on-on-on switches here in Turkey, only slider types are available.

What about a rotary switch.

The last stage driving the tone control is different to the other stages.  Not sure if it would work OK being fed by the first or second stages.

If you switch out the first stage you will lose the gain control.

Maybe switching out the second stage is a better plan.   Certainly much simpler.


Ah, you're right about the gain pot, it's bound to 1st one indeed. I'll just keep it as it is now, then.

Rob Strand

I was cleaning up some of my parts and it just so happens I had a CD4007.  Just to be clear I didn't build this circuit.   However, it occurred to me the reason this circuit is noisy and needs a lot of bypassing is because the first two stages use the P-channels of the CD4007 for amplification.   That means these two stages are effectively positive ground circuit.  What happens is the supply noise gets amplified with the full-gain of the amplifier!

A possible mod is to use the N-channels for gain like this,



Using the N-channels for gain makes the first two stages negative ground which will greatly reduce the amplification of the supply noise.

The gain look very similar for the P-channel and N-channel but since it's unverified I can't guarantee the mod sounds the *exactly* the same.  The bias points should be close and if they aren't close enough the bias point could be tweaked.

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