Inverting opamp gain stage setups

Started by Chugs, May 03, 2015, 06:32:46 AM

Previous topic - Next topic

Chugs

I am experimenting with inverting gain stages on the breadboard. I have tried the two examples below. In the first example, there is a fixed low pass filter of 1500hz while the gain control makes a variable high pass filter as the gain is increased. In the second example, the high pass is set at 150z while the low pass filter varies as the gain control is increased.

Is there a way of setting up an inverting gain stage where by the low end and high remain constant as the gain is varied?




samhay

Yes, remove* the caps that work with the variable resistance - C3 in the top example and C6 in the other.

*You don't actually have to physically remove them though, you 'just' have to make them so big or small (depending on where they are) to shift the filtering out of the audible range.
I'm a refugee of the great dropbox purge of '17.
Project details (schematics, layouts, etc) are slowly being added here: http://samdump.wordpress.com

Chugs

Yes, but want if you want like to vary the gain whilst keeping a specific high and low pass filter setting? So, in this example 150hz and 1500z.

Digital Larry

To preserve the frequency response of the stages you can't have variable resistance in either input or output loops where it would interact with a cap.  So you could vary the input resistance of the second stage.  Another thing you can do is just set up a volume control like arrangement between stages and forget about having it be within the op-amps magical zone of influence.  Now there might be times where you want the frequency response to change with gain.
Digital Larry
Want to quickly design your own effects patches for the Spin FV-1 DSP chip?
https://github.com/HolyCityAudio/SpinCAD-Designer

slacker

What Larry said, you need to do one lot of your filtering elsewhere, in your first circuit for example you could do the high pass with C2/R3 then jumper C3 or make it big enough not to matter.

Chugs

Ok, good suggestions. I thought as much.

What happens if I try and set it up like this?


PBE6

At very high frequencies the cap will behave like a short circuit, so the gain will approach -(R7||(R5+Rpot))/R4. At very low frequencies, the cap will behave like an open circuit, so the gain will approach -(R5+Rpot)/R4. This is a shelving low-pass filter.

In between the two extremes, the gain expression is frequency dependent, and if I'm doing my algebra correctly there are two frequencies of interest at f(zero) = 1/(2*pi*C*R7) and f(pole) = 1/(2*pi*C*(R7+R5+Rpot)). f(zero) is always larger, and corresponds to where the shelf begins to level out. f(pole) is smaller, and corresponds to where the full gain begins to drop off.

With this arrangement you can keep the shelving frequency constant, but the drop off frequency will be a function of Rpot. Still, that might be a workable compromise depending on what you're trying to achieve.

amptramp

C3 should not be necessary in the above circuits.  It serves to keep the offset of the input stage out of the second stage, but this is only about 13 mV.  Since the next stage has a virtual node biased off the same source, the capacitor will be reverse biased half of the time.  If you need the highpass characteristic, film caps in the 2.2µF size are reasonably small these days.

Chugs

Thanks for the math PBE6.

The circuit will work without C3. But C3 is being used to provide a high pass in conjunction with R4. (And the gain control in the first example.)

merlinb

Quote from: Chugs on May 04, 2015, 03:57:28 AM
The circuit will work without C3. But C3 is being used to provide a high pass in conjunction with R4. (And the gain control in the first example.)
Make the first opamp a non-inverting gain stage and use that for gain control. Then use the second opamp to do the (fixed) filtering.

Chugs

Thanks for the great suggestion Merlin.

I am tinkering around with exploring inverting gain controls so I am trying to stick to using the inverting op amp for the gain control. Just breadboarding for fun here.  :)

This one sounding interesting on the breadboard. Better than the third example.


PBE6

Wow! Very interesting. This filter appears to stay very constant for most of the pot travel, until you get down under 1k:


It looks like the controlling factor is the current going to ground through R6/C6. Making R6 very large or C6 very small minimizes the bass boost effect and makes the gain look like a normal inverting opamp stage, while also increasing the minimum pot setting required for stable filter frequencies.

On a side note, making C7 smaller extends the bass boost into a bass-mid boost, while making it very small adds treble too (essentially making it a flat boost with a slight bass roll off).

Good tinkering Chugs!

anotherjim

Variable gain with a fixed hi and low shelf?
First amp. High pass input with variable feedback gain. Second amp is low pass (feedback) only.


PBE6

All of the solutions recommending the use of two opamps are simple and effective, and you can't go wrong with any of them. But I gotta say, I have a soft spot in my heart for Chugs' third diagram for a few reasons:

1. It's wacky and unique.
2. It works! (for over 99% of the pot value)
3. It uses one inverting opamp instead of two, as per the stated goals.
4. We all told him he couldn't do it, and he did it anyway.

Edison may have "invented" 100 duds before getting to the electric light bulb, but you have to admire the gumption of an Edison.

Kudos Chugs!

Chugs

#14
Thanks for for the graph PBE6. Very interesting! I actually had C7 as a 0.01uf on the breadboard. Accidentally labelled 0.1uf on the schematic.

Utilising the first opamp to provide filtering and/or gain in conjunction is the logical way to go but I was just trying to see what would happen when sticking to the inverting opamp.

PRR

Your #1 wants a REVerse-Audio taper for happy hand-action. As this is a less-common part, it can lead to an "Oh, carp!!" moment when you nearly finish and UPS is on strike.

Why so complicated? Inverting stages are usually NOT your first choice. They hiss. (Though with the values and chips you use, probably non-issue.) They invert (duh), which sometimes complicates fancy interconnections. They only have two places to mess-around, whereas an NI stage gives you three places. Yes, inverters have some for-sure applications. But as you are finding out, they can be awkward.

Especially since you are only going down to Unity-Gain. Inverters readily give gain OR loss, but you are not asking for that, only 1-100. And that's a snap in a *one-opamp* NI-design.



Keep messing. You are learning what an inverter is and is-not good for. But when you need something in 15 minutes, reach for an NI idea first.
  • SUPPORTER

Chugs

PRR, thanks for the response. Will having the 1500z filter formed by the 100K resistor and 1nf cap on the input as shown in your diagram be sensitive to the output impedance of a pedal active in the signal chain?

If a pedal with a poor output impedance is in front on the circuit as drawn will the frequency response of the filter change?