Op amps as comparators

steveb

Joined Jul 3, 2008
2,436
then recall better next time.
I shall endeavor to do so. Irrespective in any age-induced shortcomings I may have with memory and comprehension, I can still see and read, and upon rereading I can't extract an answer to my honest question, so I'll restate it one final time. It's up to you if you choose to answer for the benefit of others.

So what is your opinion? Is it preferable that opamps be used as comparators, or is it better to use a comparator that has been designed specifically for that purpose? I'm curious of the general answer, understanding of course that all rules have exceptions.
 
Last edited:

beenthere

Joined Apr 20, 2004
15,819
With reference to my post #22, you do realize that your reply -
for many valid reasons, some mentioned before. a Buick Roadmaster is foundamentally a car, as is a 911. But that doesn't mean 911 will do as good of a job hauling people as the roadmaster, or the roadmaster can race down a track as gracefully as a 911.

for example, comparators are typically NOT internally compensated, and opamps aren't. that means opamps may not swing as fast as a comparator, everything else being equal.

But you can find plenty of opamps that will swing plenty other comparators. ad815 for example, it can swing in as fast as 10ns, and lm119 (a high speed comparator) may take as long as 50ns - 100ns to swing to full output.

saturation: many comparators use CCS loading to avoid deep saturation (not on the open collector architecture though). many opamps also use CCS loading (to achieve high gain) that will also prevent deep saturation. examples of the opposite also exist: some opamps use baker clamps to avoid saturation and you rarely find them on comparators.

the list goes on. but if you look at devices in both classes, you will find that they are surprisingly similar and foundamentally identical: most of them follow the Linn 3-stage topology; both of them have very high open loop gain; both of them have inverting and non-inverting inputs, ...

opamps typically can moonshine for comparators, and comparators may have a harder time working as opamps. But none of those differences are fundamental.
- is not an answer to my actual question -
if op amps can be made to behave adequately as voltage comparators and vice versa, why have the various IC manufacturers gone to the trouble of making these devices just as if there really were some significant difference between them?
Perhaps you have some store of circuits in which any old comparator has been substituted for an op amp with the same or better performance? Or perhaps you might like to rise to a challenge where someone will post up an op amp circuit and you can show us all how to use a comparator to the same effect? It might be fun to see how I can get rid of the OPA134's in my preamp and sub in LM311's - they're so much cheaper.

Oh, yes - I particularly want to see how to sub in a 741 op amp for any comparator. How about a contemporary design, like an LM311? - that most useful of comparators.

What, by the way, is a definition for "moonshine"?

Just to arrive at some clearly stated understanding - let us say that operational amplifiers are intended to work with analog signals in a linear fashion. Let us say that voltage comparators are intended (designed) to assume two states, off or on, according to the input voltages. This is not, by the way, a linear response.
 

Thread Starter

millwood

Joined Dec 31, 1969
0
Oh, yes - I particularly want to see how to sub in a 741 op amp for any comparator. How about a contemporary design, like an LM311? - that most useful of comparators.
let me just put a short paragraph here for your enjoyment:

It's always easy to take a statement of someone and interpret it too literally and make a big deal about it. Nobody here is fooled by this type of nonsense.
silly questions like yours deserve no answer from anyone.
 

beenthere

Joined Apr 20, 2004
15,819
Gosh and golly, guess you can't walk the walk after all. Or use your own quotes.

Let us in on one secret though, pretty please - which was the Buick Roadmaster? The 741 or the LM311?

It's just curious-making - you tell us that op amps and comparators work in so essentially the same ways that they can hardly be distinguished, but have no examples to share. My question was not meant to be silly, I really wanted to see if you could back up your assertions.

Now we know.
 

Thread Starter

millwood

Joined Dec 31, 1969
0
Steveb - technically he did not - see post #16. This got split off another thread because it was not serving the OP's needs.
but he was too interested in hearing himself talking he forgot what he was saying.

:)
 

beenthere

Joined Apr 20, 2004
15,819
So nothing technical to say? You really can't tell us how to make a comparator accurately follow a linear signal? I really thought there was no significant difference.

Try an answer rather than an attack. Or simply admit you are over your head.

The accurate quote is -
My question was not meant to be silly, I really wanted to see if you could back up your assertions.
 

Thread Starter

millwood

Joined Dec 31, 1969
0
So nothing technical to say?
plenty, just NOT to you, because you have not shown the ability to comprehend the discussion, nor have you shown the willingness to participate in a civil discussion.

The accurate quote is -
the "accurate" answer would be: you don't deserve it.
 
You said "opamps typically can moonshine for comparators, and comparators may have a harder time working as opamps. But none of those differences are fundamental."

What is it about comparators that give them a harder time to work as an opamp?

Are there any benefits of using a dedicated comparator over an opamp for the comparator function?
 

russ_hensel

Joined Jan 11, 2009
825
Too much emotion, lots of heat, a little light; I would vote for closing this thread. Lets all try to be friends and share expertize not fight over it.
 

Thread Starter

millwood

Joined Dec 31, 1969
0
You said "opamps typically can moonshine for comparators, and comparators may have a harder time working as opamps. But none of those differences are fundamental."

What is it about comparators that give them a harder time to work as an opamp?
quite a few. comparators typically run very lean, to help switching fast. that means their ability to drive heavy load is limited, and their (open loop) linearity can be poor.

most comparators are not compensated (no miller cap). while you can add loop compensation it really hurts your skew rate.

comparators are analog devices designed for digital applications so they don't care much about their "DC performance". they usually drift more, and have higher bias offset too.

Are there any benefits of using a dedicated comparator over an opamp for the comparator function?
however, comparators hold considerable advantages over opamps for some applications, especially when high-speed opamps were lacking, 10 or 15 years ago. it is not that difficult to get sub 50ns or sub 20ns comparators even in the old days. it was very very difficult to produce that kind of large signal response time for opamps.

but for 99% of what we do, it doesn't matter. both chips are identical topology wise; both have incredible amount of open loop gain, which makes them practically identical closed loop, etc.

most opamps textbooks will cover comparators as a special kind of opamp or a subset of opamp for that reason.
 

steveb

Joined Jul 3, 2008
2,436
I'll just reference this application note from Analog Devices to provide some additional information.

An interesting comment as follows:

"However, the best advice on using op amp as comparator is very simple - don't!"

Interestingly, it then goes on to explain why you might not want to follow this advice.

Not that app-notes are the end-all answer to questions and can't become outdated, but it shouldn't be surprising that some people here have also provided similar comments as are in this app-note.

EDIT: I see StayathomeElectronics already referenced this app note. Anyway, it's a good summary.
 

Attachments

Last edited:

Thread Starter

millwood

Joined Dec 31, 1969
0
I particularly liked the conclusion section:

In conclusion, although op amps are not designed to be used as comparators, there are, nevertheless, many applications where the use of an op amp as a comparator is a proper engineering decision. It is important to make an educated decision to ensure that the op amp chosen performs as expected.
 
Top