Op amp needs bias? - Page 1
Forum section: electronics / beginners

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 07, 2021, 03:34:43 pm
content: I hooked my electric guitar up to an op amp (TL082) to try to build a very basic distortion pedal with lowish gain, currently 2. I can crank that later once I've got the basic circuit working. I just wanted to make sure I understand this correctly. The output only has a positive voltage, the negative has all been clipped. I assume this is because my power supply is +5V/ground, not +5V/-5V? Am I right in thinking that I need to apply a bias to the input?The circuit is shown in the attachment.Thanks

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 07, 2021, 04:01:24 pm
content: Seems I reported that incorrectly. The new attachment gives a better picture, so I'm doing something wrong somewhere. Time to recheck my circuit.

author: rstofer
author_rank: Super Contributor
timestamp: November 07, 2021, 04:02:23 pm
content: Yes, you need to bias the input to 1/2 Vcc.https://www.ti.com/lit/an/sloa030a/sloa030a.pdf?ts=1636228792351&ref_url=https%253A%252F%252Fwww.google.com%252F

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 07, 2021, 04:03:22 pm
content: Quote from: rstofer on November 07, 2021, 04:02:23 pmThanks; I'm working on that change (in between watching the rugby).

author: Terry Bites
author_rank: Super Contributor
timestamp: November 07, 2021, 05:01:37 pm
content: The opamp inputs always need a path to a DC potental. To over come your problem, bias this input to half rail 2.5V. The TL082 is "high voltage opamp" and not well suited to a single supply of just 5V. A low cost opamp such as an MCP6281 may better suit your deisgn. Note the AC coupling and cap in the feedback loop to ground. They are essential, otherwise you will be amplifiing the 2.5V DC bias.I just gave it a quick route - you could make it smaller.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 07, 2021, 05:12:12 pm
content: Thanks Terry and thanks for the reminder about the caps. Does it matter what resistor pair I use for biasing? I have a fairly small selection of resistors and I don't have 56ks.Oh, and the TL082 is the only op amp I have. I haven't bought any others as I'm learning and didn't want to spend the money. Yet.

author: TimFox
author_rank: Super Contributor
timestamp: November 07, 2021, 05:59:39 pm
content: For audio with op amps, I recommend split power supplies (two 9 V batteries, maybe) since it makes the signal chain much easier. (This shows that I was born in a previous millennium.)If you insist on a single supply, then obviously the output cannot go negative with respect to the grounded negative power input of the op amp (ignoring some exotic devices with internal power supply thingies).Therefore, the output should be somewhere between ground and the positive supply, and an output capacitor is required to drive a ground-referenced input.Assuming your source is a typical guitar pickup, which is essentially an inductor, the low bias current of the FET-input amplifier can flow through it. With a split supply, the pickup can be grounded directly. With a single supply, you need to add a capacitor from the grounded pickup, and add a voltage divider to bias the amplifier side of the capacitor to mid-voltage. Any noise or power-supply ripple at this voltage divider will be amplified by the circuit.You also need to connect the "bottom side" of the feedback circuit somewhere: the easiest is to use a large capacitor to ground, so that the gain at DC is unity although the AC voltage gain at audio frequencies is 10:1.Even with split supplies, it is a good idea to have a capacitor at the output to remove the small DC offset voltage.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 07, 2021, 08:15:13 pm
content: Thanks all, much appreciated.

author: magic
author_rank: Super Contributor
timestamp: November 07, 2021, 09:47:13 pm
content: Dual battery supply is a nasty can of worms because it turns into a single supply when one of the batteries is depleted.This may result in DC offset on the output. And it only gets worse when the opamp is prone to phase reversal: if TL072 negative supply drops down to -2V and the signal is at ground, its output will go to the positive rail which may still be a few volts.

author: CatalinaWOW
author_rank: Super Contributor
timestamp: November 07, 2021, 10:24:30 pm
content: I am also old school and am more comfortable with dual supplies. More dynamic range is often a real benefit of this approach. And to avoid the drawbacks of dual battery approaches there are switch mode inverters available which can boost a single positive supply to a negative supply. They are small, cheap and require only a couple of external components.

author: Doctorandus_P
author_rank: Super Contributor
timestamp: November 07, 2021, 10:58:41 pm
content: Another method is to generate a negative supply voltage for your opamp. For example with an ICL7660. (There are many variants of that chip).I do not see much use of adding DC blocking capacitors in each and every stage. If you use an ICL7660 and then use DC coupling for all pre amplifier stages, then that DC will (or at least should) be blocked by the power amplifier.

author: rstofer
author_rank: Super Contributor
timestamp: November 07, 2021, 11:04:45 pm
content: For breadboarding, these Power Bricks work really well. They take USB (or +5V) in and provide a dual rail output up to +-12V. I wish they went to +-15V but that's the way it ishttps://digilent.com/shop/powerbricks-breadboardable-dual-output-usb-power-supplies/

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 08, 2021, 12:29:32 am
content: I biased the non-inverting input and the input signal looks great now. However, I'm getting 3.65V (DC coupled, 0V AC coupled) out of the output pin?I think I need to pull the components and rebuild, perhaps tomorrow when I'm not so tired. I'm seeing references online to the input voltage being too low (voltage swing?).

author: rstofer
author_rank: Super Contributor
timestamp: November 08, 2021, 01:06:16 am
content: With a properly biased single supply op amp, you can expect the output to idle at Vcc/2. For a dual supply setup, the output will idle around 0V. I'm just guessing but it seems that your bias voltage may not be quite correct if you are getting 3.65V on a 5V single supply circuit. Tie your signal input to Vcc/2 and make some measurements. Remember, all measurements should be made relative to Vcc/2, not 0V.Vcc/2 is the new ground.Single supply circuits aren't my favorite...

author: RJSV
author_rank: Super Contributor
timestamp: November 08, 2021, 02:43:55 am
content: Gawd, I pity you, with all this good info at once. But a little more basic theory might help:OK, I view an OP AMP as a super gain device, (way more than the circuit it will be in). Think something like 100,000 X gain. So, the trick is to utilize feedback, from the output and consider this output as 'controlling' the OP AMP minus or negative input, which it does, but via some reduction.So, if the positive input (feeble) rises a bit, the huge gain cause a big rise in the output, which also gives a feeble rise in your negative input (you connected it to drive a reduced output to the negative input).That's a control type response, where the OP AMP fights to eliminate the (voltage) difference, between the two inputs. That is the circuit, with the negative feedback is arranged to do this.So you never see that huge gain, directly, just think of it as strongly keeping the two inputs equal.Now, for DC, looking at previous examples, your desired negative feedback is for one to one 'gain', or just have your DC level at about half way, like 2.5 volts if you are using single 5 V supply. The OP AMP will fight, strongly, to control your negative input to also be at 2.5 V steady. Except for noise, there.Your negative input, from a DC standpoint, should just follow the output, no reduction, and that is what the other posts do show. Therefore, you will see 2.5 V DC right there on your output, too.You can see, the capacitor keeps the ground out of any DC feedback calculation, the negative input gets the DC 2.5 V since the DC part of the output is not reduced, in that negative feedback.One way to look at the AC (audio) is that it is a little disturbance, on top of the DC 2.5 V you've set up.You can also appreciate, a pair of 100 k or a pair of 56 k makes no difference, as long as it's fairly large, so as not to start loading down the feeble AC. You can kind of think if it as two circuits, right there in same place!Now then, you have a DC level being controlled, putting those 2 resistors dividing the output AC, (because for AC your ground IS connected, so that divides) you have, paradoxically, actually TWO different gain situations, simultaneously.And one last concept: by feedback having less than the output, you can say it the other way: In other words the output is MORE than the (negative) input, and, hey, same thing can be said about the positive input, your feeble guitar signal. That's because the circuit is controlling itself, to have the positive input be, also, a certain factor or fraction of the output.Very wordy, and round and round, but it's the key to all those variations being tossed at you.Question ? I will check back, hope my (limited) expertise helps...

author: RJSV
author_rank: Super Contributor
timestamp: November 08, 2021, 07:09:30 pm
content: ...the thing I wouldn't spend much time on, is any modification to basics, guitar-wise. Some mention, of 'input bias current' of FET input going through the guitar pickup(s).? And messing with the ground side, of the guitar / cable.?Dude, put a DC blocking capacitor, first thing at input jack... Next thing, we get a half-hour discussion, on 'which' guitar type to use, for a bit of trickle current thru the pickups...and how to 'isolate' your ground sheild. Maybe a transformer, under the guitar plate...All due respect, just thinking aloud.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 09, 2021, 12:10:11 am
content: Got it! I used the circuit that Terry posted above and rebuilt it. However, I do have a question.The Capacitor C1 is reversed, so cathode connects to the guitar input and the anode connects to the voltage divider. Is this right, if so, what is the reason for doing this?Thanks all.

author: RJSV
author_rank: Super Contributor
timestamp: November 09, 2021, 04:08:50 am
content: I like the responses Terry has given.My guess is the cap polarization just indicates which side is the higher DC potential. Op amp input device is powered, so cap reflects that, (but that doesn't cover the case for two batteries, so I'm over my head, in that water, lol).Output, same thing. The OP amp has positive potential, so the cap polarization reflects that polarity direction, although again, my certainty factor is, likeperhaps 61.5 %.My philosophy is to generally cap isolate things coming into your 'box', and DC isolate outputs. That leaves room for a design, like for example, having 3 stages, DC coupled, no caps. Then a cap isolates the last stage.Wouldn't worry too much about 'noise' getting in, on distortion settings.I might try this: First two stages with gain of X5, and a foot switch to insert a third stage with crazy high gain maybe X 12. Then, you pad down that output, with potentiometer, or resistor divider. WAIT... I guess that's wrong, as you seek distortion effects. Perhaps try messing with that last stage, try put back to back diodes clipping the 3rd stage output.I've used a toy tape recorder circuit board, for great homemade distortion, probably due to overdrive the Fender Super Reverb.BTW something like the Fender Princeton Reverb is a great mid-size.You can also send PM for guitar chord info, I've taught some, and interested in music careers (Jimi Hendrix).Friends eyes glaze over whenever mentioned too much...lol

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 09, 2021, 12:35:09 pm
content: Thanks RJHayward. I was confused, as other schematics I've seen had a non-polarized capacitor at the front.Anyway, it works so that's progress.

author: Zero999
author_rank: Super Contributor
timestamp: November 09, 2021, 03:50:26 pm
content: Quote from: YurkshireLad on November 09, 2021, 12:10:11 amThe capacitor symbols drawn are non-polarised.Here's a drawing, showing the correct polarity for the capacitors, if polarised parts are to be used.

author: HB9EVI
author_rank: Frequent Contributor
timestamp: November 09, 2021, 04:08:04 pm
content: there's nothing wrong using single 9V supply for a stompbox; all the professional manufacturers (Boss, Ibanez et.al.) are doing it already for years; that works well with all common audio opamps like tl072, ne5532 or lm833; bias to vcc/2 and everything is fine.

author: Zero999
author_rank: Super Contributor
timestamp: November 09, 2021, 06:08:01 pm
content: Another option is to use the spare op-amp to make a virtual earth.

author: TimFox
author_rank: Super Contributor
timestamp: November 09, 2021, 06:19:06 pm
content: The rail-splitter circuit above works well for small-signal amplifiers like yours, where the positive and negative currents drawn by the other amplifier are almost equal; the splitter amplifier then supplies only a very small current equal to the difference between the two currents.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 10, 2021, 01:59:42 am
content: I replaced the resistor with a 10k potentiometer, the only one I have, to control the gain. I bravely connected the output to my guitar amp. If I turn the pot down, I get a clean tone from the amplifier. If I turn it up, the amplifier is overloaded a bit, but there's no distortion from the op amp. I don't know if the cable to the amplifier is of good quality or not. It might be crap. I'm not sure if I'm forgetting something in my circuit.

author: HB9EVI
author_rank: Frequent Contributor
timestamp: November 10, 2021, 11:16:07 am
content: which resistor did you replace with the pot?distortion is mainly reached by 2 anti-parallel placed diodes which clip the signal; the way of over-driving one stage with the signal of previous one doesn't work in silicon the way it does in valve overdrive circuits

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 10, 2021, 11:45:54 am
content: I replaced R4 in the diagram in this attachment -https://www.eevblog.com/forum/beginners/op-amp-needs-bias/msg3797660/#msg3797660

author: HB9EVI
author_rank: Frequent Contributor
timestamp: November 10, 2021, 11:56:38 am
content: ok, with a 100k pot you have a G between 1 and 11; that won't be in the range, where the opamp starts to clip the signal with a plain passive guitar on the input.you can either place 2 anti-parallel diodes in the feedback path over the pot, or clip the output by adding a resistor before the diodes

author: Terry Bites
author_rank: Super Contributor
timestamp: November 10, 2021, 01:06:48 pm
content: Here are some more friendshttps://www.diystompboxes.com/smfforum/index.php?topic=110272.0

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 10, 2021, 02:02:41 pm
content: Quote from: HB9EVI on November 10, 2021, 11:56:38 amI don't have any diodes; can I add a resistor to the output, before the capacitor?

author: HB9EVI
author_rank: Frequent Contributor
timestamp: November 10, 2021, 03:02:13 pm
content: it's not a bad idea to decouple opamp outputs from possible capacitive loads (e.g. long, coaxial audio cables); common value would be 100Rbut for clipping that won't do it. the diodes 'cut off' the signal above their forward voltage, so ~0.7V, so the signal turns from sinusoidal to squarewave-like, it adds odd and even harmonics to the signal, which are responsible for the distorted soundcheck here once:https://www.electrosmash.com/big-muff-pi-analysisthey are based on transistors, but that doesn't matter; watch how the diodes in circuits are places - this is what a circuit makes a distortion

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 10, 2021, 06:37:35 pm
content: Thanks all. I need to understand the amplitude of the output signal from a typical pedal. Likely mine was too high as it was post-gain. The guitar input signal is about 200mV for low E, so it makes sense that a pedal would output a similar voltage (in my naive opinion) for the next pedal in the chain.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 13, 2021, 01:49:48 am
content: I thought I'd post my latest diagram for any feedback. I managed to simulate it in LTSpice, but values may be wrong.

author: Zero999
author_rank: Super Contributor
timestamp: November 13, 2021, 08:37:10 am
content: That looks sensible enough. Presumably this is going to be powered off a 9V battery.Yes, the values are wrong. R3 is 1m which is 1 milliohm, or 0.001Ohms. It should be 1M, which is a million Ohms. SPICE is not case sensitive. It would treat 1M, as 1m, so to get round this, you need to set the value to 1Meg, instead of 1M.I believe guitar pickups have a fairly high impedance. I'd up the values of R1 & R2 to 1M and move R3 to in-between the op-amp's +input and the 4.5V node.R6 should be a much lower value, like 100R.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 13, 2021, 01:47:47 pm
content: Yes, I realized it was taking 1m as milli ohms, but I didn't realize I could use 1meg, so thanks! I'll, update that and I'll add your other suggestions too. Many thanks.

author: TimFox
author_rank: Super Contributor
timestamp: November 13, 2021, 03:04:05 pm
content: SPICE started out as Fortran on Hollerith cards, and was case-insensitive.Therefore, "m" or "M"alwaysmeans "milli" and "meg" or "MEG" is required for "mega".This is required for backwards-compatibility with earlier SPICE models.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 21, 2021, 08:06:29 pm
content: This is what I have so far. I wired it up on the breadboard, but the signal is only being biased with 20mV and not 4.5V (measured where R1 is connected to the signal input).

author: TimFox
author_rank: Super Contributor
timestamp: November 21, 2021, 08:42:13 pm
content: The indicated polarity on the input capacitor is backwards: you expect +4.5 V on the right side and 0 on the left side for DC voltages.However, C2 should not be a polarized capacitor at only 100 nF. The other two capacitors C3 and C4 should be polarized.What did you use to measure the DC voltage at the junction of C2 and R1?

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 21, 2021, 08:44:46 pm
content: Damn, sorry. It isn't polarized - I forgot to change the circuit diagram.I used my multimeter.

author: TimFox
author_rank: Super Contributor
timestamp: November 21, 2021, 09:59:56 pm
content: "Multimeter": do you mean an analog "VOM" or a modern digital "DMM"?The reason for that question is how much current you are pulling through the 1 megohm resistor from +4.5 V.Unless your opamp is blown, or you have an undocumented short circuit, or you have mislabeled the pins in your diagram (inverting the power connections), you should have very close to +4.5 V at that junction, assuming you have +4.5 V at the voltage divider connected to the top end of the 1 megohm resistor R1. Check that node (junction of R7 and R8) first, then disconnect the opamp and see if the +4.5 V reappears.A typical DMM has an input resistance on DC of 10 megohms, but some cheap ones have only 1 megohm input resistance. Assuming 10 meg, you have a Thevenin equivalent of +4.5 V in series with 1.5 megohm driving the voltmeter, so the theoretical voltage is about 3.9 V with no load besides the voltmeter. However, if a polarized C6 is in backwards, it will short out the +4.5 V.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 21, 2021, 10:12:51 pm
content: I'm using a modern digital multimeter to measure the bias voltage at R1/C2.The junction of R7/R8 is 4.5V. This is what I'm seeing.

author: TimFox
author_rank: Super Contributor
timestamp: November 21, 2021, 10:25:02 pm
content: Double-check the pinout on your opamp (none shown in your drawing) and look for accidental short from +input to -power.Then replace the opamp with a new one, after measuring the voltage when you removed the first one.

author: rstofer
author_rank: Super Contributor
timestamp: November 21, 2021, 10:32:32 pm
content: I don't understand C3. It doesn't provide a DC path to ground so the gain is probably not correct as shown on the most recent schematic.I would eliminate it completely.I'm not convinced about the bias circuit either. See Figure 3 Non-inverting here:https://mil.ufl.edu/4924/docs/TI_SingleSupply_OpAmp.pdfGoogle term: non-inverting amplifier single supplyOr, cut to the chase, second schematic here:https://electronics.stackexchange.com/questions/437278/single-supply-non-inverting-amplifier-using-op-ampI stand corrected on C3, it is useful.

author: TimFox
author_rank: Super Contributor
timestamp: November 21, 2021, 10:47:53 pm
content: C3 is a typical circuit to get a low DC gain (+1, since the output goes almost directly to the - input at DC) but a high AC gain at audio frequencies. If his circuit were working, the + input would be at +4.5 V, and the output and - input would follow, except for small deviation due to small bias currents through the highish resistances.If you eliminate C3, the - input would be far from the bias on the + input.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 21, 2021, 11:04:50 pm
content: Quote from: rstofer on November 21, 2021, 10:32:32 pmI started with the 2nd schematic but everything I read said that voltage divider can noise from the supply to the input audio signal. So I changed to what I'm using now.

author: rstofer
author_rank: Super Contributor
timestamp: November 21, 2021, 11:16:29 pm
content: Quote from: YurkshireLad on November 21, 2021, 11:04:50 pmYes but with that 1 Mohm resistor, even the slightest bit of bias current will drop the voltage substantially. Look at the values used in other circuits. It is more on the order of 10k top and bottom.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 21, 2021, 11:19:16 pm
content: Quote from: rstofer on November 21, 2021, 11:16:29 pmWill do, thanks.I've been referencing the ProCo cat -https://www.electrosmash.com/images/tech/pro-co-rat/pro-co-rat-schematic-parts.jpg

author: TimFox
author_rank: Super Contributor
timestamp: November 21, 2021, 11:38:53 pm
content: Quote from: rstofer on November 21, 2021, 11:16:29 pmYes, 1 uA of bias current (far larger than should happen with a TL072) would give 1 V change in the voltage from 1 megohm. However, at room temperature, the TI spec (TL072H, similar for other grades) for maximum bias current is 120 pA. Over temperature extremes (-40 to +125 C), the maximum bias current is 5 nA. 5 nA x 1 megohm = 5 mV.The OP's choice of resistor and capacitor values may not be optimal, but the huge error in the DC voltage at the + input indicates either a wiring error, a component failure, or an accidental huge difference between the circuit diagram value and the actual resistor value.

author: rstofer
author_rank: Super Contributor
timestamp: November 22, 2021, 12:43:48 am
content: Quote from: TimFox on November 21, 2021, 11:38:53 pmI lost track of the device, it doesn't show on the latest schematic. Nevertheless, 4.48 uA is going somewhere. The thing is, that's not a lot of current. Or, maybe the resistor is a lot larger - like 10M ohm.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 22, 2021, 12:44:57 am
content: Quote from: rstofer on November 22, 2021, 12:43:48 amThe output signal (GAIN_OUTPUT) for now is going to my guitar amp.

author: Jan Audio
author_rank: Frequent Contributor
timestamp: November 22, 2021, 03:03:01 pm
content: You always need a resistor at the input of your opamp.If you want 5volt you could take a microchip rail to rail opamp.Are you overdriving your signal with this opamp ?, it sound nicer if you use germanium diodes.

author: Zero999
author_rank: Super Contributor
timestamp: November 22, 2021, 09:57:33 pm
content: Quote from: YurkshireLad on November 21, 2021, 10:12:51 pmThat's a little ambiguous. Are both of those voltages measured, with respect to 0V, or are you actually measuring 20mV, across the 1M resistor?If both voltages are measured, with the meter's negative/common probe on 0V, then something is badly wrong: either the op-amp is completely busted, or C2 is short circuit.If you're measuring 20mV across the 1M resistor, that's a bias current of 20nA, which is quite high for the TL072 and is a sign it's fake, or broken. Where did you buy it from? A proper distributor, or a random ebay/Amazon seller?Have you tried swapping the op-amp, for a different one?

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 22, 2021, 10:31:30 pm
content: Quote from: Zero999 on November 22, 2021, 09:57:33 pmSorry, I meant with respect to 0V.I've tried different TL082s with the same results.It works if I use a voltage divider on the input signal as in this diagram (not my diagram, I found it online).Edit - I rebuilt the gain circuit and it appears to now buss the op amp, but there's no gain.haha! That must be progress of some kind.

author: Zero999
author_rank: Super Contributor
timestamp: November 23, 2021, 08:46:31 am
content: Quote from: YurkshireLad on November 22, 2021, 10:31:30 pmThe two circuits are very similar and both use voltage dividers. Theone with the separate 4.5V node, as you've drawn it, is the better one, because the capacitor in parallel with the lower part of the divider, smooths the 4.5V node, do it doesn't fluctuate with the power supply voltage. It means noise on the power supply, isn't coupled to the output of the amplifier. The one you've posted there, which just couples the signal onto the voltage divider, is simpler, but any noise on the power supply rail, will go through the potential divider and to the input of the op-amp and be amplified.Have you checked the coupling capacitors aren't bad?How are you building it? Is it on a stripboard? Are you sure the tracks have been cut where they need to be and none have been cut, where they shouldn't be?QuoteWhich circuit? Note the circuits have different gains. The most recent one has a gain of 11 and the other one, a gain of 101.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: November 25, 2021, 10:42:28 pm
content: ok, some success. I rebuilt the circuit from scratch and I can get gain from the op amp. I played my guitar through my amp (minimal tone circuitry) and it worked. However, the output was around 7V (relative to ground), so I put in a 1k resistor and a potentiometer in series on the output. I also replaced the gain resistor with a 50k potentiometer. Now I'm getting around 0.7V (relative to ground) on the output but it's saturating my amp, even when I turn the volume pot and gain pot down.Edit:I added a high pass filter with a cutoff around 80Hz and that improved things. However, if I roll back the guitar's volume control, the output signal from my "pedal" loses all of the positive signal. That's weird. I probed around and it's the op amp. Time for some more reading.

author: Zero999
author_rank: Super Contributor
timestamp: November 26, 2021, 08:47:00 am
content: You've obviously got far too much gain.Do you know which amplifier is saturating?Do you have an oscilloscope and signal generator? If not, there's some software to enable you to use a PC's sound card as a poor man's oscilloscope and signal generator.What sort of guitar pick-up do you have? You probably don't need much gain, just an amplifier with a high input impedance.

author: HB9EVI
author_rank: Frequent Contributor
timestamp: November 26, 2021, 11:20:30 am
content: did you check if the bias on the output is correct, so +/- the voltage applied to the positive input?also i think you're running too low impedance on the input for a guitar with the 56kohm voltage divider; in stompboxes you normally find a voltage divider with 2 10k and an electrolytic cap and bias to the opamp is done from the middle of this voltage divider over a 470k resistor. If you go too low with the input impedance you lose signal level in the upper frequency spectrum, so you get a very dull sound out of itif you're not just playing a guitar with a builtin active electronics, you have to have an eye on the input impedance; if it's too low it's like you use a far too long cable - the frequency response of the guitar starts to suffer.

author: Zero999
author_rank: Super Contributor
timestamp: November 26, 2021, 12:28:09 pm
content: Quote from: HB9EVI on November 26, 2021, 11:20:30 amI would use a bootstrapping circuit to give a much higher input impedance, but it's more complicated, so I wouldn't recommend it to someone who's struggled with a simpler circuit.Here's an example, for educational purposes. It uses positive feedback to eliminate the effect of the input bias resistors on the input impedance. The voltage where R1 and R2 join, follows the input voltage and has a relatively low impedance of R1||R2. C1 couples this to one side of R5, so the voltage at this node follows the input, thus very little current passes through R5. R3, R4 & R6 bias the input to half the supply voltage. C2 can be two 47µF polarised capacitors connected back-to-back.The circuit will be more stable if built with two op-amps: one bootstrapped stage, with a unity gain and the second one with the required gain.

author: HB9EVI
author_rank: Frequent Contributor
timestamp: November 26, 2021, 02:54:30 pm
content: sure, technically a good option, but it always seems to me a little bit complicated transporting the 'magic' of bootstrapping to beginners; its function is not so evident at first glance

author: Jan Audio
author_rank: Frequent Contributor
timestamp: November 27, 2021, 03:12:02 pm
content: gain_stage.png is good.Post scope movie and schematic.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: December 19, 2021, 07:48:59 pm
content: I re-built a new circuit without gain to make sure the op amp is correctly biased. However I'm seeing a DC voltage of approximately 2.3V at the non-inverting input of the op amp. It should be 4.5V?

author: TimFox
author_rank: Super Contributor
timestamp: December 19, 2021, 08:11:33 pm
content: To clarify, is that voltage measured on a physical circuit, or just simulated in Spice?If measured, what is the input resistance of your voltmeter?

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: December 19, 2021, 08:13:24 pm
content: This is a real circuit - I haven't measured the input resistance of my DMM.

author: TimFox
author_rank: Super Contributor
timestamp: December 19, 2021, 09:24:27 pm
content: The voltage you measured is consistent with a voltmeter resistance of 1 megohm, which is less common than 10 megohm, but I have some with that value. There is 1 megohm feeding that node, so a 1 megohm load would divide the 4.5 V source by a factor of 2. The manufacturer’s spec should include the input resistance, which may be different on AC and DC modes. Oscilloscopes usually have 1 megohm input resistance, in case you were using that to measure the DC voltage.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: December 19, 2021, 09:41:18 pm
content: Quote from: TimFox on December 19, 2021, 09:24:27 pmThanks, that makes sense. How would I verify that the op amp is correctly biased?

author: TimFox
author_rank: Super Contributor
timestamp: December 19, 2021, 09:53:28 pm
content: With that circuit, the output DC voltage should equal +4.5 V if you move the voltmeter (with any reasonable resistance greater than, say, 10 k, to the op amp output (pins 1 & 2), so long as you don’t have a voltmeter at the non-inverting input pin (3) to load the bias voltage.Note that I did not proofread the pin numbers on your circuit drawing.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: December 19, 2021, 10:49:00 pm
content: Quote from: TimFox on December 19, 2021, 09:53:28 pmGood point I forgot to note the output pin's DC voltage.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: December 20, 2021, 12:04:40 am
content: I re-measured and I'm getting about 3V on the non-inverting input and the output pins.

author: TimFox
author_rank: Super Contributor
timestamp: December 20, 2021, 12:14:53 am
content: Assuming no wiring errors or shorted capacitors, and further assuming that no AC generator is connected, that implies about 1.5 uA input bias current, which is far too high for a FET input op amp. Perhaps you have one of the notorious forgeries, where a cheaper BJT amplifier has been relabeled.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: December 20, 2021, 12:16:12 am
content: Maybe it is a forgery - I do have some LM358s (perhaps they're LM393s, must check) I could try instead, though maybe they're forgeries too!I am using a Wemos D1 R32 ESP32 as a simple signal generator, as I don't have anything else to use - except my guitar.

author: TimFox
author_rank: Super Contributor
timestamp: December 20, 2021, 12:20:12 am
content: 1.5 uA is also high for a 358 (which is higher than a TL082). Check the DC voltages on both ends of R2. The LM393 is not an op amp (dual comparator), with the same pinout.Make sure the AC generator is disconnected when you measure the DC voltages.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: December 20, 2021, 12:28:24 am
content: 4.5v and 3.1v with the signal disconnected.

author: YurkshireLad
author_rank: Frequent Contributor
timestamp: December 20, 2021, 01:02:27 am
content: Maybe it is working; I put in a gain loop with a gain of 11 (10k + 1k resistors) and I'm getting a clipped output signal of about 7.8vpp. I'll plug the guitar into it tomorrow.With a gain of 1, I'm getting an output signal of about 3vpp, which is the same as the input signal.Thanks for your help.Edit: I thought I had some LM358s but I can't find them at the moment.

author: nigelwright7557
author_rank: Frequent Contributor
timestamp: December 21, 2021, 09:49:48 pm
content: You can either use split rails or bias the inputs around half rail voltage and use a coupling capacitor on input and output.