ohmio

Circuits / 555 and op-amps

Op-amp comparator

Without feedback the output saturates: high when V+ > V−, low when V+ < V−

Op-amp comparator, simulated on a breadboard

Tap a part to see its voltages and currents. It is a model, not a measurement.

What do you need?

How does an op-amp work as a comparator?

Without feedback, an op-amp amplifies the difference between its inputs so much that the output simply goes to one side: high when V+ is above V−, low when it is below. Here R1 and R2, two 10 kΩ resistors, set a 2.5 V reference on V− of an LM358, and the potentiometer feeds V+. With the knob at 30 % of its turn, V+ is at 3.5 V, above the reference, so the output is high and the LED lights through R3 (330 Ω) at about 4.8 mA. Turn the knob until V+ drops below 2.5 V and the output falls to near 0 V: the LED goes off. The switch is sharp, not gradual. One detail of the LM358: its output only reaches about 1.5 V below its supply, so on 5 V the high level is near 3.3 V.

Values from the Protoboard ISO simulation: a model, not a bench measurement.