Work out comparator threshold instantly with clear inputs, formula shown and shareable results.
The comparator threshold is set by a resistor divider from the reference. Adding positive feedback through a large resistor shifts the threshold depending on the output state, creating hysteresis that prevents chatter when a slow or noisy input crosses the threshold.
Comparator with hysteresis
Vth = V x R2/(R1+R2); hysteresis window = V x (R1||R2) / ((R1||R2) + Rhyst)
Electrical results are planning estimates only. Verify against the applicable wiring rules (IEC 60364, BS 7671, NEC or local code) and have all installation work designed and checked by a qualified electrician.
Without it, noise on a slowly changing input causes multiple transitions at the crossing point. Hysteresis makes the threshold move away after each switch.
At least a few times the peak-to-peak input noise. Too much delays detection and shifts the effective trip level.