# Schmitt trigger

Circuit symbol for Schmitt trigger.
Circuit symbols for an
inverted Schmitt trigger.

The Schmitt trigger , named after its inventor Otto Schmitt , who invented it in 1934 as a student, is an electronic comparator circuit in which the switch-on and switch-off thresholds do not coincide, but offset against each other by a certain voltage, the switching hysteresis are. The Schmitt trigger represents a multivibrator in the extended term. A Schmitt trigger is used to generate binary signals or to obtain clear switching states from an analog input signal curve. Application examples are (in connection with an RC element ) the debouncing of switches or the generation of vibrations ( tilting vibrators ).

## function

Output signal of a comparator (A) compared to the output signal of a Schmitt trigger (B).

The Schmitt trigger is an analog comparator with positive feedback . It works as a comparator for two analog voltages and functions as a threshold value switch : If a certain threshold voltage set in the Schmitt trigger is exceeded, the output assumes the maximum possible output voltage (logical 1) in the non-inverting version, in the other case the minimum possible output voltage (logical 0). In the case of the inverting version, the output behaves in reverse. Output voltages between the maximum and the minimum value do not occur in static operation. As a result of the positive feedback, in contrast to the pure comparator, it has different switch-on and switch-off thresholds that are apart by the value called hysteresis .

If the input voltage exceeds the upper switching threshold of the Schmitt trigger with an inverting Schmitt trigger, its output voltage changes from the maximum voltage value to the minimum voltage value. If the input voltage then falls below the lower switching threshold, the output voltage switches back to the maximum output voltage. The small difference voltage between the two threshold voltages on the input side is the hysteresis and can be defined in the structure of the discretely structured version of a Schmitt trigger by resistors . With Schmitt triggers, which are designed as an integrated circuit , it is usually not possible to change these switching thresholds.

The hysteresis of the Schmitt trigger (the voltage between the two switching thresholds) can range from a few millivolts to above the value of the supply voltage. This is determined by the dimensioning of the resistors in the positive feedback of the included comparator.

## Inverting Schmitt trigger

Circuit diagram of an inverting Schmitt trigger with U e as the input voltage and U r as the reference value.
Characteristic curve of an inverting Schmitt trigger.

The adjacent circuit diagram shows an inverting Schmitt trigger built with an operational amplifier with an adjustable threshold value in the form of the voltage U r . In circuits mostly only the input, here marked U e , and the output U a . The positive feedback is achieved in that part of the output voltage is returned to the positive (non-inverting) input of the operational amplifier via the resistor network .

The precise switching thresholds U 1 and U 2 for switching on and off differ from the externally specified threshold voltage U r due to the hysteresis and can be determined using the following equations:

${\ displaystyle U_ {1} = U_ {r} + {R_ {2} \ over {R_ {1} + R_ {2}}} \ cdot (+ U_ {v} -U_ {r}) = {{R_ {1} \ cdot U_ {r} + R_ {2} \ cdot U_ {v}} \ over {R_ {1} + R_ {2}}}}$
${\ displaystyle U_ {2} = U_ {r} + {R_ {2} \ over {R_ {1} + R_ {2}}} \ cdot (-U_ {v} -U_ {r}) = {{R_ {1} \ cdot U_ {r} -R_ {2} \ cdot U_ {v}} \ over {R_ {1} + R_ {2}}}}$

The characteristic curve of an inverting Schmitt trigger shown opposite , shown in the input to output voltage level, illustrates the different threshold voltages.

In the modeling, the voltage U v corresponds to the symmetrical supply voltage of the operational amplifier. In the case of a real operational amplifier, however, the saturation voltages of the output should be used to calculate values ​​that are slightly below the supply voltage.

It is also possible to operate an operational amplifier as a Schmitt trigger with an asymmetrical supply voltage. In this case, the negative supply voltage U v is equal to 0 V and the output switches between 0 V, which corresponds to logic 0, and U v , which corresponds to logic 1. The threshold voltage U r is then usually chosen equal to half the supply voltage U v - the exact voltage levels can, however, differ depending on the logic family . This type of asymmetrical supply is mostly preferred in digital circuits. Widespread types in CMOS technology are CD / HEF / HCF 4093 (which combines four NAND gates in one housing) and 40106 (six inverters ). This can be used to build very simple oscillator circuits .

If, instead of the reference voltage U r, both switching thresholds U 1 and U 2 are given, the reference voltage U r must first be selected as follows, regardless of the resistors R 1 and R 2 :

${\ displaystyle U_ {r} = U_ {v} \ cdot {{U_ {1} + U_ {2}} \ over {2U_ {v} + U_ {2} -U_ {1}}}}$

R 2 can be freely chosen and R 1 then results from this:

${\ displaystyle R_ {1} = {{U_ {v} -U_ {1}} \ over {U_ {1} -U_ {r}}} \ cdot R_ {2}}$

## Non-inverting Schmitt trigger

Circuit diagram of a non-inverting Schmitt trigger

The circuit of a non-inverting Schmitt trigger is shown opposite. The behavior of the output voltage is exactly inverse compared to the above circuit. The input resistance of the example circuit is significantly smaller than that of the inverting Schmitt trigger circuit and dynamically corresponds to the resistance R 1 + R 2 . Due to the switchover, there is an effect on the input. This circuit is therefore rarely used - the output voltage can also be inverted by a downstream inverter and then avoids the disadvantage of the low input resistance of the non-inverting Schmitt trigger.

With the circuit specified, the threshold voltage can be set to 0 V by setting the negative input of the operational amplifier to 0 V ( ground ). In digital circuits, the middle between the switching thresholds is set to half the supply voltage (2.5 V at 5 V supply voltage) or in the middle of the "forbidden area" of the logic level (approx. 1.4 V).

## Precision Schmitt trigger

With a precision Schmitt trigger it is possible, in contrast to the coupled circuits shown so far, to set the switching thresholds precisely and independently of one another. It can be constructed from two comparators and a downstream RS flip-flop . The switching thresholds can be set with the help of voltage dividers , for example . One comparator compares the input voltage with the upper switching threshold and switches the flip-flop to the set state when this threshold is exceeded; the other comparator compares the input voltage with the lower switching threshold and resets the flip-flop when it falls below this threshold. The integrated NE521 component, for example, is suitable for setting up a precision Schmitt trigger, which contains two comparators and two NAND gates that can be connected to form a flip-flop. The NE555 also has a built-in precision Schmitt trigger and can be used as such without external capacitors.

## Discrete circuit design

A Schmitt trigger can also be implemented as a discrete circuit with MOSFETs or bipolar transistors . Circuit examples are given in the following figures.

 Schmitt trigger in CMOS technology. Realization of a Schmitt trigger with the help of two transistors . (Non-inverting)

The four MOS transistors arranged one above the other in the circuit diagram on the left create a common inverter . The same transistors can be imagined as a transistor with a center tap of the gate-source path. The two transistors on the right, switched by the output signal, change the switching threshold U GS by "shortening the path" of the gate-source path , so that the desired behavior results. The switching thresholds are set constructively by dimensioning the MOS transistor structures involved.

The circuit diagram on the right is similar to a two-stage, directly coupled, generally non-inverting analog amplifier. The difference is the common emitter resistor R E . This realizes the positive feedback and thus the desired Schmitt trigger behavior. The switching thresholds are set by dimensioning the resistors.

## application

If digital signals are transmitted over long cable sections, the signal edges are smoothed in the event of a mismatch due to the low-pass characteristic and, even if the adjustment is correct, due to the dispersion . A Schmitt trigger again generates steep signal edges and clear signal levels for subsequent circuit parts.

A simple oscillator ( relaxation oscillator ) can be built from an inverting Schmitt trigger, a resistor as feedback and a capacitor parallel to the input (RC element), which can generate oscillations up to the VHF frequency range with sufficiently fast semiconductor elements.

Schmitt trigger with upstream low-pass (RC element) can be for debouncing of keys and other contacts use. The time constant of the RC element must be greater than the maximum bounce time (usually a few milliseconds). Debouncing is required when a digital circuit is to execute a command using a mechanical button each time a button is pressed. If the key is not debounced, several commands are executed when the key is pressed, since the logic level changes several times at the moment of switching. Debouncing is also possible with software instead of hardware.

## literature

• Ulrich Tietze, Christoph Schenk, Angelo Vetro PMH: Semiconductor circuit technology . 12th edition. Springer, 2002, ISBN 3-540-42849-6 , pp. 612-615 .