GLOBAL KNOWLEDGE ARK

Electronics · Analog circuits and feedback

Make stable threshold decisions with comparators and hysteresis

A sensor near a decision threshold can produce many unwanted transitions as small disturbances push it back and forth. Hysteresis gives the decision two boundaries and a memory of which state came first.

Lesson preparation and course links

Use the component and device lessons. Gain, feedback, frequency and uncertainty are developed through the stated circuit models.

Back to the Electronics chapter

After reading, you can

Trace a comparator decision, derive two hysteresis thresholds and explain the input, output and uncertainty conditions needed for a reliable transition.

01

A comparator reports which input is higher

A comparator compares two input voltages and produces one of two output states. In the ideal model, its output is high when the noninverting input, marked +, is above the inverting input, marked −, and low for the opposite relationship. Those signs label the input's effect on the decision; they do not mean the inputs must be positive or negative relative to ground.

The supply establishes the permitted operating range and available output levels. Real inputs also need to remain within the common-mode range, the range of input voltages for which the comparison is specified. A small input offset acts like an additional differential voltage, shifting the switching point. At exact equality, an ideal rule needs a state or transition convention; a real circuit has offset, noise and delay.

02

One threshold can chatter

Suppose a slowly varying signal crosses a fixed 2.5 V reference. Small noise around that value can repeatedly change the sign of the input difference. Chatter means those repeated output transitions near the decision boundary. Increasing amplifier gain alone does not remove the underlying sign changes.

Hysteresis uses one threshold for an input moving upward and another for an input moving downward. Between them, the circuit retains its preceding output state. A disturbance that does not reach the opposite threshold cannot reverse that state in the ideal model. The price is a deliberate decision band: the output no longer describes a unique threshold independent of history.

03

Positive feedback moves the comparison level

Feedback returns some output influence to an input. In positive feedback, the influence reinforces a transition rather than correcting it back toward a central value. Our inverting example connects the signal V_IN to the − input. The + input joins a resistor R_REF to an ideal 2.5 V reference and a resistor R_FB to the output.

Assume negligible input current and a reference that can both supply and absorb the network current. Current balance at the + input gives V_PLUS = (V_REF/R_REF + V_OUT/R_FB)/(1/R_REF + 1/R_FB). The threshold therefore changes when V_OUT changes. This weighted-average expression is a resistor-network result, not a special comparator law.

04

Solve each output state separately

Take R_REF = 10 kΩ, R_FB = 100 kΩ, and ideal output levels of 0 V and 5 V. The expression becomes V_PLUS = (10V_REF + V_OUT)/11. When output is high, the threshold is 2.727 V. A rising input must cross that upper threshold to drive the output low. The feedback then lowers the threshold to 2.273 V.

The low output persists until a falling input crosses 2.273 V, where the output returns high. At 2.5 V, either output is consistent with its own feedback threshold. History determines the state. At power-up, history may be unknown, so a system that requires a definite start needs a specified initialisation or input condition.

Two thresholds create an inverting hysteresis loopAn inverting comparator remains high until a rising input reaches 2.727 V and remains low until a falling input reaches 2.273 V. The same input can belong to either stable state 5 V0 VV_OUTV_IN → 2.273 V2.727 V Rising input →← Falling input Ideal output levels and resistors; hysteresis width ≈ 0.455 V.
For the model output levels 0 V and 5 V, an inverting comparator switches high-to-low at 2.727 V on a rising input. It switches low-to-high at 2.273 V on a falling input. Between those thresholds, the output depends on its earlier state.
05

Output loading also changes the thresholds

A push-pull output actively drives both states. An open-drain or open-collector output actively pulls one way and requires a pull-up path for the other state. Its high level depends on that path, leakage and loading. If feedback draws current from the output, those conditions belong in the threshold calculation.

Propagation delay is the time between an input crossing and the specified output response. It depends on device conditions, including how far the input is driven beyond the threshold. Hysteresis is not a time filter: a sufficiently large brief excursion can still cause a transition if the device responds. If a requirement includes minimum pulse duration, analyse filtering and timing separately.

06

Use the device intended for the job

An operational amplifier normally uses negative feedback to produce a proportional analogue output. A comparator is intended to make a switching decision. Similar triangle symbols do not establish interchangeable input structures, logic-compatible output levels or recovery time after large input differences. Use an op amp in this role only when its relevant behaviour is actually established.

For a real threshold requirement, combine reference error, resistor tolerance, input offset, input current and output-level limits. Then verify the upper and lower extremes with the chosen source impedance and temperature. Hysteresis should be wide enough for the disturbances the system must reject, while remaining narrow enough to distinguish the required signal changes.

Worked example: calculate the two switching thresholds

With V_REF = 2.5 V, R_REF = 10 kΩ and R_FB = 100 kΩ, a 5 V output gives V_H = (10 × 2.5 + 5)/11 = 30/11 = 2.727 V. A 0 V output gives V_L = 25/11 = 2.273 V. The hysteresis width is V_H − V_L = 5/11 = 0.4545 V, approximately 455 mV.

Start with V_IN = 2.0 V, which makes the output high. Raising V_IN to 2.6 V leaves it high because 2.6 V is below 2.727 V. Raising it to 2.8 V makes the output low. Returning to 2.6 V now leaves it low until the input falls below 2.273 V. The calculation assumes exact resistors, exact output levels and a zero-offset comparator; component limits widen the real threshold uncertainty.

Try the reasoning

  1. At V_IN = 2.5 V, what output must this hysteretic comparator have?

    Show the answer and reasoning

    No unique state is implied. High output gives a 2.727 V threshold, making 2.5 V consistent with high. Low output gives a 2.273 V threshold, making it consistent with low. The earlier state or startup condition matters.

  2. The output is high and the input rises from 2.0 V to 2.6 V. Does it switch?

    Show the answer and reasoning

    No in this ideal model. The high-state threshold is 2.727 V, and 2.6 V has not crossed it. A rising input must exceed that upper threshold before the output changes low.

  3. Why is the rising-input threshold calculated using the high output level?

    Show the answer and reasoning

    Immediately before a rising-input high-to-low transition, the output is still high. That existing state sets the feedback threshold that must first be crossed. Using the future output state would choose the wrong boundary.

  4. If the high output droops while the low level and reference remain unchanged, does the hysteresis remain 455 mV?

    Show the answer and reasoning

    No. The high-state threshold contains V_OUT. A smaller high level lowers the upper threshold and narrows the band in this network. Recalculate with the specified loaded output levels.

  5. Does hysteresis guarantee rejection of every short noise pulse?

    Show the answer and reasoning

    No. It supplies an amplitude/history band, not a minimum-duration test. A pulse that crosses the relevant threshold and lasts long enough for the comparator to respond can switch it. Timing or filtering requirements need separate analysis.

  6. Why is an unused op amp not automatically a suitable comparator?

    Show the answer and reasoning

    Its input protection, allowed differential/common-mode range, saturation recovery and output interface may differ from a comparator's requirements. The shared symbol does not establish switching behaviour under the intended conditions.

What to carry forward

Derive the threshold from the state that exists before the transition. Hysteresis creates an intentional decision band; real device and network limits determine where that band actually lies.

References

Sources supporting this lesson’s explanations and examples.

  1. Texas Instruments2 sources
    1. Inverting comparator with hysteresis circuit, SNOA997ATexas InstrumentsReference guideti.comRead source
    2. CIRCUIT060076 — Inverting comparator with hysteresis circuitTexas InstrumentsReference guideti.comRead source
  2. Walt Kester; Analog Devices2 sources
    1. MT-083: ComparatorsWalt Kester; Analog DevicesReference guide · PDFanalog.comRead source
    2. MT-084: Using Op Amps as ComparatorsWalt Kester; Analog DevicesReference guide · PDFanalog.comRead source