We are Apogeeweb Semiconductor Electronic

WELCOME TO OUR BLOG

Home arrow Semiconductor Information arrow What is a Comparator in Electronics?

arrow left

arrow right

What is a Comparator in Electronics?

Author: Apogeeweb Date: 9 Mar 2021  162

comparator op amp

Introduction

Comparing two or more data to determine the number size and arrangement order between them is called comparison. As for comparator definition, a circuit or device that can realize this function is a comparator. In electronics, a comparator is a device that compares two voltages or currents and outputs a digital signal indicating which is larger, or it is a circuit that compares an analog voltage signal with a reference voltage. The two inputs of the comparator are analog signals, and the output is a binary signal 0 or 1, and the output is ideally. When the difference of the input voltage changes and the positive and negative sign remains constant, the output remains unchanged. Comparators play an essential role in designing electrical and electronic projects.

Comparator Explained (Inverting Comparator, Non-Inverting Comparator and Window Comparator)

Catalog

Introduction

Ⅰ Working Principle

Ⅱ Main Parameters

2.1 Hysteresis Voltage

2.2 Bias Current

2.3 Super Power Swing

2.4 Drain-source Voltage

2.5 Output Delay Time

Ⅲ Comparator Classification

3.1 Voltage Comparator

3.2 Window Comparator

3.3 Hysteresis Comparator

Ⅳ Comparator ICs

Ⅴ How Do You Select a Comparator?

Ⅵ Comparator Applications

6.1 Zero-crossing Comparator 

6.2 Relaxation Oscillator (ROSC)

6.3 A/D Converter

6.4 Voltage Comparator

Ⅶ Difference between Comparator and Operational Amplifier


Ⅰ Working Principle

Generally, in electronics, the comparator is used to compare two voltages or currents which are given at the two inputs of the comparator. A comparator circuit compares two voltages and outputs either a 1 (the voltage at the plus side; VDD in the illustration) or a 0 (the voltage at the negative side) to indicate which is larger. The operational amplifier can be used as a comparator theoretically without negative feedback. However, the open-loop gain of the operational amplifier is very high, so it can only process signals with a very small input differential voltage. Moreover, in general, the delay time of the op amp is long, which cannot meet the actual requirements. The comparator can be adjusted to provide a very small time delay, but its frequency response characteristics will be limited. To avoid output oscillation, many comparators also have internal hysteresis circuits. The threshold of the comparator is fixed, some have only one threshold, and some have two thresholds.

comparator symbol

Comparator Symbol

Ⅱ Main Parameters

2.1 Hysteresis Voltage

The voltage between the two input terminals of the comparator will change the output state when it crosses zero. Because the input terminal is often superimposed with a small fluctuation voltage, the differential mode voltage generated by it will cause the comparator output to change frequently.  In order to avoid output oscillation, the new comparator usually has a hysteresis voltage of several mV. The existence of it requires two switching points of the comparator: one is used to detect the rising voltage, the other is used to detect the falling voltage. The difference of the voltage threshold (VTRIP) is equal to the hysteresis voltage (VHYST). The offset voltage of hysteresis comparator is the average of TRIP and VTRIP-. The input voltage switching point of the comparator without hysteresis is the input offset voltage, not the zero of the ideal comparator. In addition, the offset voltage generally varies with temperature and power supply voltage. And the power supply rejection ratio is usually employed to express the influence of power supply voltage changes on the offset voltage.

2.2 Bias Current

The input impedance of an ideal comparator is infinite. Therefore, there is no effect on the input signal theoretically. However, the actual input impedance of the comparator cannot be infinite. There is a current at the input end that flows through the internal resistance of the signal source and flows into the comparator, thereby generating an additional voltage difference. The bias current (Ibias) is defined as the median of the input currents of the two comparators and is used to measure the effect of input impedance.

2.3 Super Power Swing

To further optimize the operating voltage range of the comparator, Maxim uses the parallel structure of the NPN tube and the PNP tube as the input stage of the comparator. Thus the input voltage of the comparator can be expanded. In this case, the lower limit can be lower to the lowest level, and the upper limit is 250mV higher than the power supply voltage to reach the Beyond-the-Rail standard. The input of this comparator allows a larger common-mode voltage.

2.4 Drain-source Voltage

The comparator has only two different output states (zero level or power supply voltage). Its output stage of the comparator with full power swing characteristics is an emitter follower, which makes its voltage difference smaller between input and output signals. The voltage difference depends on the emitter junction voltage under the saturation state of the internal transistor of the comparator, which is equal to the drain-source voltage of the MOSFFET.

2.5 Output Delay Time

It includes the transmission delay of the signal through the components and the rise time and fall time of the signal. For high-speed comparators, such as MAX961, the typical value of the delay time can reach 4.5ns and the rise time is 2.3ns. Pay attention to the influence of different factors on the delay time when designing, including the influence of temperature, capacitive load, input overdrive and so on.
Although the comparator has different types. The design and construction of each should take care of ordinary uses without affecting its measuring accuracy. The instrument should be very sensitive and withstand a reasonable ill usage without permanent harm.

high gain comparator

Ⅲ Comparator Classification

Comparators are classified into various kinds, such as electronic, electrical, mechanical, optical, sigma, digital and pneumatic comparators. These are used in various applications. Here we are talking about electronic comparator.

3.1 Voltage Comparator

A voltage comparator is a circuit that discriminates and compares input signals, and is a basic unit that forms a non-sine wave generating circuit. Voltage comparators are commonly used including single-limit comparators, hysteresis comparators, window comparators, and three-state voltage comparators. Voltage comparator can be used as an interface between analog circuits and digital circuits, as well as waveform generation and conversion circuits.

3.2 Window Comparator

Combine two comparators to form a "window comparator", which is widely used. The window comparator can set the upper limit voltage and lower limit voltage of the input at the same time, within limited voltage range, or outside the range, which we need. When the potential level of the high-level signal is higher than a certain specified value VH, it is equivalent to the positive saturation output of the comparator circuit. When the potential level of the low-level signal is lower than a certain specified value VL, it is equivalent to the negative saturation output of the comparator circuit. The comparator has two thresholds, and the transmission characteristic curve is window-shaped, so it is called a window comparator.

3.3 Hysteresis Comparator

It is a comparator with hysteresis loop transmission characteristics, and can be understood as a single-limit comparator with positive feedback. When the input voltage vI gradually increases from zero and VI is less than VT, the comparator output is a positive saturation voltage, and VT is called the upper threshold (trigger) level. When the input voltage VI>VT, the comparator output is a negative saturation voltage, and VT is called the lower threshold (trigger) level.

analog voltage comparator circuit

Ⅳ Comparator ICs

Common chips are LM324, LM358, uA741, TL081\2\3\4, OP07, OP27, which can all be made into voltage comparators (without negative feedback). LM339 and LM393 are professional voltage comparators with fast switching speed and small delay time, which can be used in special voltage comparison occasions.

 

Ⅴ How Do You Select a Comparator?

The working principle of a comparator is simple and straightforward. It has a positive pin and a negative pin. When the voltage on the positive pin is high, the output drives a signal. When using open-collector output, the output pin of the comparator is the collector of a transistor or the drain of a FET. When using push-pull output, the comparator has a complementary NPN/PNP stage, like in an operational amplifier. The open-collector output is used when the load and the comparator use different power supplies. This kind of scheme can realize the solenoid of 12V, although the comparator may only work at 3.3V. Another function of the open-collector output is to minimize the quiescent current when the output is turned off. Among them, no base current flows in the N-type output transistor, and some base current always flows through one of the two output transistors.
However, open-collector output also has some disadvantages. For example, they require external pull-up resistors. These resistors must complete the pull-up task during the high-impedance period, so that when the output is lower than turn-off, the comparator can switch faster, and the pull-up resistor makes the output high. Therefore, when you need a symmetrical waveform, it is not suitable to use an open collector output, such as a clock recovery circuit. If your circuit does not require level conversion, you should choose push-pull output, such as ALD2321APC, it can provide 24mA output drive capacity, quiescent current is 90μA.

The high-speed comparator may also have a latched output, so that the output can be kept in a known state to meet the set-up and hold time requirements of the digital input behind it. Once the digital part has read the output of the comparator, the latch pin can be released and the output can track the input.
High-speed comparators may also use ECL (emitter coupled logic) levels from -5V to 0V. PECL (positive emitter coupled logic) outputs have the same voltage swing, from 0V to 5V. There is also RSPECL (reduced amplitude PECL) output. The two output pins of some high-speed comparators use LVDS (low-voltage differential signaling) output, which converts 300mV around a 1.2V common-mode voltage in a complementary manner. You can send these outputs directly to the LVDS input pins of FPGA (field programmable gate array) and other digital circuits.
In production, CMOS technology is generally used to build low-power devices, while bipolar devices are used to build high-speed devices. This represents a basic compromise: high-power high-speed, accurate devices, and low-power, low-speed devices. Another compromise is gain and high speed. The low-power comparator may take 70µs conversion time and consume less power. The response time of the high-speed comparator is 150ps. Some devices can overcome the trade-off between speed and power consumption. When converting at the highest rate, the power consumed by the comparator is much higher than its static power consumption. In the static state, the current is low. When the comparator is operated at a higher speed, it must be able to charge the capacitor. In dynamic mode, the current increases as the working speed increases. Another factor in power consumption is the load on the chip. For a switching current, the capacitance will also become a load, and the capacitive and resistive components in the load must be considered. Many devices are related to broken pins, which can reduce the power consumption to less than 1µA.
As with all simulation, the declared propagation delay is meaningful only under strictly defined conditions, because the degree to which the input pin is driven directly affects the propagation delay. The greater the overdrive, the faster the device. Dispersion is the range of propagation delay values of a device under various overdrive levels. The relationship between overdrive and speed is one reason why some engineers are reluctant to consider comparator speed as a function of slew rate. It necessary to define the output level that is quantized as a valid transition, usually the maximum output level is 10% to 90%. The slew rate also represents a requirement for overdrive, that is, to keep the propagation delay as short as possible.

Another parameter to consider when choosing a comparator is noise. However, manufacturers often omit noise specifications of the comparators and instead use random jitter to measure noise. In addition to the noise signal passing through the device gain, the input aperture error and the output rise and fall time can also affect jitter. A clock-driven device is nothing but a lower gain comparator optimized for noise. Designers can use larger input transistors in a CMOS device to reduce flicker noise, but this method increases the input capacitance.
The next consideration should be the rated voltage of the comparator. One factor related to the power supply interval is the allowable common-mode voltage at the input pins of the comparator. Some devices allow you to pull the output to a voltage range higher or lower than the power supply. For other devices, when you pull the input pin below the negative power rail, the output will be inverted. Comparator with rail-to-rail input stage expands the range of input common-mode mode. These devices have a dual-input stage, using N-type transistors or FETs in parallel with the P-type input stage. The input voltage of the P-type input stage operates at near the ground or the negative voltage rail, and the N-type input stage works when the input swings to the positive voltage rail. IC designers generally make the device switch between level 1 or 2V below the positive voltage rail. When sweeping over the rail-to-rail devices, some structures can minimize the offset voltage.

Another important specification of the comparator is the input offset current, that is, the amount of current flowing into or out of the input pin when the device is working. CMOS products have a low offset current, which represents a mismatch in the leakage of the input pin ESD (electrostatic discharge) structure. For every 10°C increase in temperature, the input offset current doubles. The offset current of high-speed comparators can be obvious, but it is not a problem because low-impedance circuits are generally used to drive these high-speed comparators. The input offset current of a bipolar device depends on the relationship between the two inputs. In a comparator, a 60mV difference in the base voltage of a differential input pair will get a 10 times higher difference between the pair's collector current and the input offset current. Therefore, one pin can pull or sink twice the rated input offset current, while the other pins have almost no input offset current, depending on which pin has a higher voltage.

LM393 voltage comparator module

Ⅵ Comparator Applications

6.1 Zero-crossing Comparator 

The zero-crossing comparator is used to detect whether an input value is zero. The principle is using a comparator to compare two input voltages. One of the two input voltages is the reference voltage Vr and the other is the voltage to be measured Vu. Generally, Vr is connected from the non-inverting input terminal, and Vu is connected from the inverting input terminal. According to the result of comparing the input voltage, the forward or reverse saturation voltage is output. When the reference voltage is known, the measured result of the voltage can be obtained. When the reference voltage is zero, it is a zero-crossing comparator.
The zero-crossing comparator has a small measurement error. When the product of the voltage difference between the two input terminals and the open-loop magnification is less than the output threshold, the detector will give a zero value. For example, when the open-loop magnification is 106 and the output threshold is 6v, if the voltage difference between the two input stages is less than 6 microvolts, the detector outputs zero. This can also be considered the uncertainty of measurement.

6.2 Relaxation Oscillator (ROSC)

Comparators can construct relaxation oscillators by using positive feedback and negative feedback. Positive feedback is a Schmitt trigger, which forms a multivibrator. The RC circuit adds negative feedback to it, which causes the circuit to start to oscillate spontaneously, making the entire circuit from a latch to a relaxation oscillator.
Level shifting uses open-drain comparators (such as LM393, TLV3011, and MAX9028) to construct a level shifter to change the signal voltage. Choosing an appropriate pull-up voltage can flexibly get the converted voltage value. For example, use the MAX972 comparator to convert ±5V signals into 3V signals.

6.3 A/D Converter

The function of the comparator is to compare whether an input signal is higher than a given value. So it can convert the input analog signal into a binary digital signal. Almost all digital-to-analog converters (including delta-sigma modulation) contain comparators circuit to quantize the input analog signal.

6.4 Voltage Comparator

The voltage comparator can be regarded as an operational amplifier with an infinite amplification factor. The function of the voltage comparator: compare the magnitude of two voltages (using the high or low level of the output voltage to indicate the magnitude relationship between the two input voltages): When the voltage at the "+" input terminal is higher than the "-" input terminal, the voltage comparator output is high level; when the "+" input terminal voltage is lower than the "-" input terminal, the voltage comparator output is low level.
It can be used as an interface between analog circuits and digital circuits, and can also be used as a waveform generation and conversion circuit. A simple voltage comparator can change the sine wave into a square wave or rectangular wave with the same frequency. The simple voltage comparator has a simple structure and high sensitivity, but its anti-interference ability is poor, so people have to improve it. The improved voltage comparators include: hysteresis comparator and window comparator. Operational amplifiers are used to determine "operational parameters" through feedback loops and input loops, such as magnification. The feedback amount can be part or all of the output current or voltage. The comparator does not need feedback and directly compares the quantity of the two input terminals. If the non-inverting input is greater than the inverted phase, the output is high, otherwise it outputs low. The input of the voltage comparator is a linear quantity, and the output is a switch (high and low level). In typical applications, a linear op amp can sometimes be used to form a voltage comparator without negative feedback.

 

Ⅶ Difference between Comparator and Operational Amplifier

In principle, operational amplifier can be used as comparator without negative feedback. However, because of its high open-loop gain, it can only process signals with very small input differential voltage. Moreover, in this case, the response time of the operational amplifier is much slower than that of the comparator, and it also lacks some special functions, such as hysteresis, internal reference and so on. Comparator usually can not be used as an operational amplifier. Comparator can provide minimal time delay after adjustment, but its frequency response characteristics are limited to some extent. Operational amplifier makes use of the advantage of frequency response correction to become a flexible and versatile device. In addition, many comparators also have internal hysteresis circuit, which can avoid output oscillation, but it can not be used as an op amp.

Ordering & Quality

Photo Mfr. Part # Company Description Package PDF Qty Pricing
(USD)
MMSZ4684T1G MMSZ4684T1G Company:ON Semiconductor Remark:Zener Diodes 3.3V 500mW Package:N/A
N/A
In Stock:On Order
Inquiry
Price:
1+: $0.21000
10+: $0.18300
100+: $0.06300
1000+: $0.04400
3000+: $0.03400
9000+: $0.02900
24000+: $0.02700
45000+: $0.02300
99000+: $0.02100
Inquiry
STW4N150 STW4N150 Company:STMicroelectronics Remark:MOSFET N-channel 1500 V PowerMesh Package:N/A
N/A
In Stock:On Order
Inquiry
Price:
1+: $6.62000
10+: $5.70000
100+: $4.73000
250+: $4.45000
500+: $4.17000
1000+: $3.75000
2500+: $3.61000
Inquiry
SPW20N60S5 SPW20N60S5 Company:Infineon Technologies Remark:MOSFET N-Ch 600V 20A TO247-3 CoolMOS S5 Package:N/A
N/A
In Stock:On Order
Inquiry
Price:
1+: $5.99000
10+: $5.16000
100+: $4.28000
250+: $4.03000
500+: $3.82000
1000+: $3.71000
2500+: $3.59000
Inquiry
BF720T1G BF720T1G Company:ON Semiconductor Remark:Bipolar Transistors - BJT 100mA 300V NPN Package:N/A
N/A
In Stock:On Order
Inquiry
Price:
1+: $0.42000
10+: $0.31100
100+: $0.18100
1000+: $0.12300
2000+: $0.10800
10000+: $0.09700
25000+: $0.09600
50000+: $0.09000
100000+: $0.08900
Inquiry
ULN2004AN ULN2004AN Company:Texas Instruments Remark:Darlington Transistors Hi V & A Darlington Package:N/A
N/A
In Stock:On Order
Inquiry
Price:
1+: $0.65000
10+: $0.53700
100+: $0.39000
250+: $0.37600
500+: $0.32600
1000+: $0.27700
2500+: $0.26000
5000+: $0.23400
10000+: $0.21700
Inquiry
STP80NF55-08 STP80NF55-08 Company:STMicroelectronics Remark:MOSFET N-Ch 55 Volt 80 Amp Package:N/A
N/A
In Stock:On Order
Inquiry
Price:
1+: $2.35000
10+: $1.99000
100+: $1.55000
250+: $1.50000
500+: $1.31000
1000+: $1.12000
2000+: $1.09000
5000+: $1.02000
10000+: $0.98000
Inquiry
FF300R12KE3 FF300R12KE3 Company:Infineon Technologies Remark:IGBT Modules 1200V 300A DUAL Package:N/A
N/A
In Stock:On Order
Inquiry
Price:
1+: $133.04000
5+: $132.57000
10+: $126.74000
20+: $123.54000
50+: $119.55000
100+: $113.74000
Inquiry
DF06S-T DF06S-T Company:Diodes Incorporated Remark:Bridge Rectifiers 1A 600Vrrm 50Ifsm Package:N/A
N/A
In Stock:On Order
Inquiry
Price:
1+: $0.40000
10+: $0.33800
100+: $0.20600
1000+: $0.15900
1500+: $0.13600
Inquiry

Related Articles

What will ON Semiconductor focus on in 2021?

Apogeeweb 7 Jan 2021  325

CatalogⅠ IntroductionⅡ The Layout of the Car MarketⅢ The Layout in the Industrial FieldⅣ The Layout on the Internet of ThingsⅤ ConclusionⅠ IntroductionON Semiconductor: In 2021, it will focus on the a...

Continue reading »

RFID Technology: System, Principle, Classification and Application

Apogeeweb 9 Nov 2018  6087

Warm hints: This article contains about 3000 words and reading time is about 15 min. Summary As one of the key technologies to build the Internet of Things, RFID has attracted much attention because ...

Continue reading »

ESD protection circuit tutorial

Apogeeweb 8 Jan 2018  5904

Warm hints: The word in this article is about 3900 and reading time is about 20 minutes. SummaryIn recent years, with the rapid development of science and technology, the widespread application of mi...

Continue reading »

Different Applications of Magnetic Beads and Inductors in the Circuits of EMI and EMC

Apogeeweb 11 Sep 2018  2590

IntroductionWhat are the functions and characteristics of magnetic beads and inductors in solving the problems of EMI and EMC? First of all, pay attention to the difference between magnetic beads and ...

Continue reading »

Iris Recognition Technology:Principle and Application

Apogeeweb 5 Nov 2018  2360

Warm hints: The word in this article is about 3000 words and reading time is about 15 minutes. SummaryBiometric recognition is the most convenient and safe identification technology at present. It do...

Continue reading »

​From Sand to Chip - Chip Formation Process

Apogeeweb 3 Apr 2018  2510

Warm hints: The word in this article is about 4500 words and reading time is about 25 minutes SummaryThis paper mainly explain the process of chip formation.How did sand become a chip? Before beginni...

Continue reading »

pinglun 0 comment

Leave a Reply

Your email address will not be published.

 
 
   
 
code image
Rating: poor fair good very good excellent

# 0 1 2 3 4 5 6 7 8 9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z