Recenlty I was at my local library to get EPFM. The only copy's they had were for refrence only, so I didn't get a chance to take it home. I did however look and read through the Noise gate section. The noise gate design he uses makes use of a Comparator op-amp in the envelope follower. Can most op-amps work as a Comparator or are there specific models that must be used. Also, is the resulting square wave (then rectified) better for gating than just rectifing the original input? And finally, I don't remember exactly what the schematic looked like, for a Comparator is the same signal sent to both the inverting and non-inverting inputs?
Thank you.
Hi William,
A comparator is simply one of many ways you can configure an op-amp. All op-amps can be comparators, if configured in that way. The principle of operation is really quite simple:
Place two signals you want to compare into the inverting and non-inverting inputs of the OA. When the non-inverting input is higher in voltage than the inverting input, the output of the OA is the value of the positive rail supply voltage (ie: what you're using to power the chip itself). When the inverting input is higher in value than the non-inverting input, the output of the OA is the value of the negative rail supply voltage.
The ACTUAL operation of a comparator involves the open-loop gain of the OA. Open loop gain comes into play any time there is no feedback loop (negative or positive) from the output to one of the inputs to control the gain. This is the maximum gain value of the OA, and is typically (741) around 200,000. It is a gain like any other, in that it is multiplied to the value of the input to become the output voltage. When one input is greater than the other, the difference between the two is amplified by the open loop gain of the OA to become the output. Essentially, since this value is almost always going to be quite high (any input multiplied by 200,000 is going to be high!), it will be limited by the rail supply voltages of the op amp, and thus the rail supply voltage of the op amp will appear on the output.
Well I thought I'd include a technical and not-so-technical description of how it works for ya ;-) Take care, and good luck!
Evan Haklar
Evan did a nice job on the explanation, but there is at least one opamp that won't work as a comparator. The NE5532/34 family has inverse parallel protection diodes connected between the inputs so you can't change one more than about 0.7 volts from the other. That's the one caveat to using any opamp as a comparator.
Going in the other direction, there are some comparators that use open collector output stages (they pull to V-, but not to V+). I keep thinking that there is some cleaver design hiding in using one (or more in parallel) as an opamp.
Take care,
-Peter
The advantafge of a "real" comparator, is that they are guaranteed to behave "nicely" as a comparator, wheras an op amp (depending on the part) might latch up, oscillate, or otherwise cause grief.
Thanks guys, I wasn't aware of these other devices created for specific use as comparators! And thanks for the heads up on that Op-amp, Peter. Will be sure not to use it!
The LM339 is the first comparator that comes to mind. It's a quad with open collector. There is also the LM311 which is a single. :D
Evan, if you haven't used 5532s before in general, give 'em a test for sure. I'm totally hooked (unless I need a comparitor ;)).
Take care,
-Peter
I think I will Peter, I have several projects with socketed op-amps, would be interesting to see how Noise/Distortion/Fourier/Transfer is affected. I'll let you know ;-) They're just plugged with 741s and TL071s.