0% found this document useful (0 votes)
1K views57 pages

Introduction To Comparator Circuit

A comparator is a circuit that compares two input voltages and outputs a digital high or low signal. It takes two analog input signals and outputs a digital signal based on which input is higher compared to a reference level. Comparators are used to sense when a signal crosses a predefined threshold. They are used in many electronic and instrumentation applications. An op-amp can function as a comparator in open loop mode, outputting either a high or low saturated state depending on the relative voltages of the two analog inputs compared to the reference voltage.

Uploaded by

Nasa McAiken
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1K views57 pages

Introduction To Comparator Circuit

A comparator is a circuit that compares two input voltages and outputs a digital high or low signal. It takes two analog input signals and outputs a digital signal based on which input is higher compared to a reference level. Comparators are used to sense when a signal crosses a predefined threshold. They are used in many electronic and instrumentation applications. An op-amp can function as a comparator in open loop mode, outputting either a high or low saturated state depending on the relative voltages of the two analog inputs compared to the reference voltage.

Uploaded by

Nasa McAiken
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 57

Introduction to Comparator

A comparator is a circuit that compares two input voltages or currents and gives output High or Low
as per input signal. The Output is a digital form according to the input signal compared with the
reference. Basically a comparator is used in electronics to compare the two Analog input signals
given on both input terminals and we get the Digital output as High level or Low level.

Comparator is used to sense the signal of a predefined rich level. If I set a level to sense then I can
use a comparator to sense it when the input signal of this level cross more or below the level,
suddenly the output is changed from Low to high and high to low. The comparators are used for so
many electronics instrumentation for automation and drive different logic circuits.

Comparator with Reference Voltage

A common comparator application is producing an output signal that indicates whether an input signal is above
or below a specified threshold voltage. For example, you might want to manually deactivate one of the
components on a circuit board when its supply voltage drops below 3 V.These types of comparator tasks are
accomplished by generating a reference voltage and using this voltage as one of the inputs to the comparator. If
you need an extremely precise threshold, you can use a voltage-reference IC, but in many cases a resistive
divider is adequate.

 
In this example, resistors are used to create a reference voltage that is equal to V CC/2.

Comparator with Hysteresis

The open-loop comparator topology discussed thus far has a serious limitation: noise will cause the op-amp to
produce spurious output transitions when VDIFF is near 0 V.

When a comparator has only one threshold, noise (represented by the low-amplitude fluctuations
in the green trace) can cause spurious output transitions (as seen in the behavior of the red trace).

 
For example, let’s say that a microcontroller needs to execute a block of code each time a periodic sensor signal
exceeds a threshold voltage. We will use a comparator to generate a signal that initiates the execution of this
code block.

However, when the sensor signal approaches the threshold, small-amplitude, high-frequency variations can
cause the signal to quickly move above and below the threshold. This causes VDIFF to vary between negative
values and positive values, and this in turn leads to multiple output transitions. These transitions are
undesirable because they represent noise behavior rather than the behavior of the “authentic” input signal.

The problem of spurious output transitions is resolved by incorporating hysteresis into the comparator circuit.
The term “hysteresis” refers to the technique of using different thresholds for negative-to-positive transitions
and positive-to-negative transitions. This creates a hysteresis band that extends above and below VDIFF = 0 V.

As shown in the following diagram, we can create different negative-to-positive and positive-to-negative
thresholds by incorporating positive feedback.
 

This diagram demonstrates one method of introducing hysteresis into a comparator circuit.

Difference between operational amplifier (op-amp) and comparator

The symbol of the operational amplifier and comparator are looked the same. But Op-amp is
designed to accept an analog input signal and also give the output Analog signal. But the
Comparator accepts the analog input signals but gives the digital output. Comparators are faster
than the operational amplifier. An op-amp will works as the comparator if using the transistor at the
output.

If the input is applied at the + pin, this is called non-inverting input

If the input is applied at the – pin then this is called the inverting input.
1. Non-inverting mode
If I connect the input voltage at the non-inverting input and set a reference voltage level at inverting
input which is to be sensing. In this circuit, the voltage will compare with the reference. If the applied
voltage is lower than the reference voltage then the output is LOW, and if the applied input voltage is
greater than the reference voltage then the output will HIGH. Here High level means output is
directly connected automatically with VCC and Low means Output is directly connected with Ground.

For example,  if we set the reference voltage at 6v, then when the input voltage increases to 6v then
the output suddenly swings to HIGH and gives the voltage the same as VCC, Otherwise output gives
the LOW or 0v voltage.

Input voltage > Reference Voltage – Output HIGH

Input voltage < Reference Voltage – Output LOW

 
comparat
or circuit diagram

2. Inverting Comparator (Inverting-Mode)


In inverting mode the input voltage is connected with the Inverting terminal and reference voltage is
st at the non-inverting terminal. In this connection, the voltage at the Inverting terminal will be sensed
and compared with the voltage at the non-inverting terminal which is the reference voltage. The
inverting mode comparator works reverse to the non-inverting comparator. Means If the voltage at
Inverting terminal is greater than the Reference voltage then the output will LOW, But If the Input
voltage is Lower than the Reference voltage than the Output Will HIGH. This comparator gives
output Inverted of input.

For example, Reference voltage adjusted at 6v, when the input voltage increases and goes to 6v
then the output will suddenly swing to LOW or 0v. Otherwise, the output will HIGH and give the
voltage the same as VCC.
The LM358 is the very popular comparator ic used for general purposes. This ic has 2 opamp
comparator. LM324 is also a very popular and most using comparator ic. It has quad op-amp
comparator.
 

Op-amp Comparator
The comparator is an electronic decision making circuit that makes use of an operational amplifiers very high
gain in its open-loop state, that is, there is no feedback resistor.

The Op-amp comparator compares one analogue voltage level with another analogue voltage level, or some
preset reference voltage, VREF and produces an output signal based on this voltage comparison. In other words,
the op-amp voltage comparator compares the magnitudes of two voltage inputs and determines which is the
largest of the two.

We have seen in previous tutorials that the operational amplifier can be used with negative feedback to control
the magnitude of its output signal in the linear region performing a variety of different functions. We have also
seen that the standard operational amplifier is characterised by its open-loop gain AO and that its output voltage
is given by the expression: VOUT = AO(V+ – V-) where V+ and V- correspond to the voltages at the non-inverting
and the inverting terminals respectively.

Voltage comparators on the other hand, either use positive feedback or no feedback at all (open-loop mode) to
switch its output between two saturated states, because in the open-loop mode the amplifiers voltage gain is
basically equal to AVO. Then due to this high open loop gain, the output from the comparator swings either fully
to its positive supply rail, +Vcc or fully to its negative supply rail, -Vcc on the application of varying input
signal which passes some preset threshold value.

The open-loop op-amp comparator is an analogue circuit that operates in its non-linear region as changes in the
two analogue inputs, V+ and V- causes it to behave like a digital bistable device as triggering causes it to have
two possible output states, +Vcc or -Vcc. Then we can say that the voltage comparator is essentially a 1-bit
analogue to digital converter, as the input signal is analogue but the output behaves digitally.

Consider the basic op-amp voltage comparator circuit below.

Op-amp Comparator Circuit

With reference to the op-amp comparator circuit above, lets first assume that VIN is less than the DC voltage
level at VREF, ( VIN < VREF ). As the non-inverting (positive) input of the comparator is less than the inverting
(negative) input, the output will be LOW and at the negative supply voltage, -Vcc resulting in a negative
saturation of the output.

If we now increase the input voltage, VIN so that its value is greater than the reference voltage VREF on the
inverting input, the output voltage rapidly switches HIGH towards the positive supply voltage, +Vcc resulting
in a positive saturation of the output. If we reduce again the input voltage VIN, so that it is slightly less than the
reference voltage, the op-amp’s output switches back to its negative saturation voltage acting as a threshold
detector.

Then we can see that the op-amp voltage comparator is a device whose output is dependant on the value of the
input voltage, VIN with respect to some DC voltage level as the output is HIGH when the voltage on the non-
inverting input is greater than the voltage on the inverting input, and LOW when the non-inverting input is less
than the inverting input voltage. This condition is true regardless of whether the input signal is connected to the
inverting or the non-inverting input of the comparator.
We can also see that the value of the output voltage is completely dependent on the op-amps power supply
voltage. In theory due to the op-amps high open-loop gain the magnitude of its output voltage could be infinite
in both directions, (±∞). However practically, and for obvious reasons it is limited by the op-amps supply rails
giving VOUT = +Vcc or VOUT = -Vcc.

We said before that the basic op-amp comparator produces a positive or negative voltage output by comparing
its input voltage against some preset DC reference voltage. Generally, a resistive voltage divider is used to set
the input reference voltage of a comparator, but a battery source, zener diode or potentiometer for a variable
reference voltage can all be used as shown.

Comparator Reference Voltages

In theory the comparators reference voltage can be set to be anywhere between 0v and the supply voltage but
there are practical limitations on the actual voltage range depending on the op-amp comparator being device
used.
Positive and Negative Voltage Comparators

A basic op-amp comparator circuit can be used to detect either a positive or a negative going input voltage
depending upon which input of the operational amplifier we connect the fixed reference voltage source and the
input voltage too. In the examples above we have used the inverting input to set the reference voltage with the
input voltage connected to the non-inverting input.

But equally we could connect the inputs of the comparator the other way around inverting the output signal to
that shown above. Then an op-amp comparator can be configured to operate in what is called an inverting or a
non-inverting configuration.

Positive Voltage Comparator

The basic configuration for the positive voltage comparator, also known as a non-inverting comparator circuit
detects when the input signal, VIN is ABOVE or more positive than the reference voltage, VREF producing an
output at VOUT which is HIGH as shown.

Non-inverting Comparator Circuit

In this non-inverting configuration, the reference voltage is connected to the inverting input of the operational
amplifier with the input signal connected to the non-inverting input. To keep things simple, we have assumed
that the two resistors forming the potential divider network are equal and: R1 = R2 = R. This will produce a
fixed reference voltage which is one half that of the supply voltage, that is Vcc/2, while the input voltage is
variable from zero to the supply voltage.
When VIN is greater than VREF, the op-amp comparators output will saturate towards the positive supply rail, Vcc.
When VIN is less than VREF the op-amp comparators output will change state and saturate at the negative supply
rail, 0v as shown.

Negative Voltage Comparator

The basic configuration for the negative voltage comparator, also known as an inverting comparator circuit
detects when the input signal, VIN is BELOW or more negative than the reference voltage, VREF producing an
output at VOUT which is HIGH as shown.

Inverting Comparator Circuit

In the inverting configuration, which is the opposite of the positive configuration above, the reference voltage
is connected to the non-inverting input of the operational amplifier while the input signal is connected to the
inverting input. Then when VIN is less than VREF the op-amp comparators output will saturate towards the
positive supply rail, Vcc.

Likewise the reverse is true, when VIN is greater than VREF, the op-amp comparators output will change state and
saturate towards the negative supply rail, 0v.

Then depending upon which op-amp inputs we use for the signal and the reference voltage, we can produce an
inverting or non-inverting output. We can take this idea of detecting either a negative or positive going signal
one step further by combining the two op-amp comparator circuits above to produce a window comparator
circuit.

Window Comparator

A Window Comparator is basically the inverting and the non-inverting comparators above combined into a
single comparator stage. The window comparator detects input voltage levels that are within a specific band or
window of voltages, instead of indicating whether a voltage is greater or less than some preset or fixed voltage
reference point.
This time, instead of having just one reference voltage value, a window comparator will have two reference
voltages implemented by a pair of voltage comparators. One which triggers an op-amp comparator on
detection of some upper voltage threshold, VREF(UPPER) and one which triggers an op-amp comparator on detection
of a lower voltage threshold level, VREF(LOWER). Then the voltage levels between these two upper and lower
reference voltages is called the “window”, hence its name.

Using our idea above of a voltage divider network, if we now use three equal value resistors so that
R1 = R2 = R3 = R we can create a very simple window comparator circuit as shown. Also as the resistive values
are all equal, the voltage drops across each resistor will also be equal at one-third the supply voltage, 1/3Vcc.
So for ease in this simple window comparator example, we can set the upper reference voltage to 2/3Vcc and
the lower reference voltage to 1/3Vcc.

Consider the window comparator circuit below.

Window Comparator Circuit

The inital switching condition of the circuit is the open-collector output of op-amp A1 “OFF” with the open-
collector output of op-amp A2, “ON” (sinking current) so VOUT is equal to 0V.

When VIN is below the lower voltage level, VREF(LOWER) which equates to 1/3Vcc, VOUT will be LOW. When VIN
exceeds this 1/3Vcc lower voltage level, the first op-amp comparator detects this and switches its open-
collector output HIGH. This means that both op-amps have their outputs HIGH at the same time. No current
flows through the pull-up resistor RL so VOUT is equal to Vcc.

As VIN continues to increase it passes the upper voltage level, VREF(UPPER) at 2/3Vcc. At this point the second op-
amp comparator detects this and switches its output LOW and VOUT becomes equal to 0V.
Then the difference between VREF(UPPER) and VREF(LOWER) (which is 2/3Vccc – 1/3Vcc in this example) creates the
switching window for the positive going signal.

Lets now assume that VIN is at its maximum value and equal to Vcc. As VIN decreases it passes the upper voltage
level VREF(UPPER) of the second op-amp comparator which switches the output HIGH. As VIN continues to decrease
it passes the lower voltage level, VREF(LOWER) of the first op-amp comparator once again switching the output
LOW.

Then the difference between VREF(UPPER) and VREF(LOWER) creates the window for the negative going signal. So we
can see that as VIN passes above or passes below the upper and lower reference levels set by the two op-amp
comparators, the output signal VOUT will be HIGH or LOW.

In this simple example we have set the upper trip level at 2/3Vcc and the lower trip level at 1/3Vcc (because
we used three equal value resistors), but can be any values we choose by adjusting the input thresholds. As a
result, the window width can be customized for a given application.

If we used a dual power supply and set the upper and lower trip levels to say ±10 volts and VIN was a sinusoidal
waveform, then we could use this window comparator circuit as a zero crossing detector of the sine wave
which would produce an output, HIGH or LOW every time the sine wave crossed the zero volts line from
positive to negative or negative to positive.

We can take this idea of detecting voltage levels further by connecting a number of different op-amp
comparators together with them all using a common input signal, but with each comparator using a different
reference voltage set by our now familiar voltage divider network across the supply. Consider the voltage level
detector circuit below.
Comparator Voltage Level Detector

As above, the voltage divider network provides a set of reference voltages for the individual op-amp
comparator circuits. To produce the four reference voltages will require five resistors. The junction at the
bottom pair of resistors will produce a reference voltage that is one-fifth the supply voltage, 1/5Vcc using equal
value resistors. The second pair 2/5Vcc, a third pair 3/5Vcc and so on, with these reference voltages increasing
by a fixed amount of one-fifth (1/5) towards 5/5Vcc which is actually Vcc.

As the common input voltage increases, the output of each op-amp comparator circuit switches in turn thereby
turning OFF the connected LED starting with the lower comparator, A4 and upwards towards A1 as the input
voltage increases. So by setting the values of the resistors in the voltage divider network, the comparators can
be configured to detect any voltage level. One good example of the use of voltage level detection and
indication would be for a battery condition monitor by reversing the LED’s and connecting them to 0V
(ground) instead of VCC.
Also by increasing the number of op-amp comparators in the set, more trigger points can be created. So for
example, if we had eight op-amp comparators in the chain and fed the output of each comparator to an 8-to-3
line Digital Encoder, we could make a very simple analogue-to-digital converter, (ADC) that would convert
the analogue input signal into a 3-bit binary code (0-to-7).

Op-amp Comparator with Positive Feedback

We have seen here that operational amplifiers can be configured to operate as comparators in their open-loop
mode, and this is fine if the input signal varies rapidly or is not too noisy. However if the input signal, VIN is
slow to change or electrical noise is present, then the op-amp comparator may oscillate switching its output
back and forth between the two saturation states, +Vcc and -Vcc as the input signal hovers around the reference
voltage, VREF level. One way to overcome this problem and to avoid the op-amp from oscillating is to provide
positive feedback around the comparator.

As its name implies, positive feedback is a technique for feeding back a part or fraction of the output signal
that is in phase to the non-inverting input of the op-amp via a potential divider set up by two resistors with the
amount of feedback being proportional to their ratio.

The use of positive feedback around an op-amp comparator means that once the output is triggered into
saturation at either level, there must be a significant change to the input signal VIN before the output switches
back to the original saturation point. This difference between the two switching points is called hysteresis
producing what is commonly called a Schmitt trigger circuit. Consider the inverting comparator circuit below.

Inverting Op-amp Comparator with Hysteresis

For the inverting comparator circuit above, VIN is applied to the inverting input of the op-amp. Resistors R1 and
R2 form a voltage divider network across the comparator providing the positive feedback with part of the
output voltage appearing at the non-inverting input. The amount of feedback to the non-inverting input is
determined by the resistive ratio of the two resistors used and which is given as:
Voltage Divider Equation

Where: β (beta) can be used to indicate the feedback fraction.

When the input signal is less than the reference voltage, VIN < VREF, the output voltage will be HIGH, VOH and
equal to the positive saturation voltage. As the output is HIGH and positive, the value of the reference voltage
on the non-inverting input will be approximately equal to: +β*V called the Upper Trip Point or UTP.

As the input signal, VIN increases it becomes equal too this upper trip point voltage, VUTP level at the non-
inverting input. This causes the comparators output to change state becoming LOW, VOL and equal to the
negative saturation voltage as before.

But the difference this time is that a second trip point voltage value is created because a negative voltage now
appears at the non-inverting input which is equal to: -β*V as a result of the negative saturation voltage at the
output. Then the input signal must now fall below this second voltage level, called the Lower Trip Point or
LTP for the voltage comparators output to change or switch back to its original positive state.

So we can see that when the output changes state, the reference voltage at the non-inverting input also changes
creating two different reference voltage values and two different switching points. One point being called the
Upper Trip Point (UTP), while the other is called the Lower Trip Point (LTP). The difference between these two
trip points is known as Hysteresis.

The amount of hysteresis is determined by the feedback fraction, β of the output voltage fed back to the non-
inverting input. The advantage of positive feedback is that the resulting comparator Schmitt trigger circuit is
immune to erratic triggering caused by noise or slowly changing input signals within the hysteresis band
producing a cleaner output signal as the op-amp comparators output is only triggered once.

So for positive output voltages, VREF = +β*Vcc, but for negative output voltages, VREF = -β*Vcc. Then we can say
that the amount of voltage hysteresis will be given as:
We can also produce a non-inverting op-amp comparator circuit with built in hysteresis by changing the input
and reference terminals as shown:

Non-inverting Op-amp Comparator with Hysteresis

Note that the arrows on the hysteresis graph indicate the direction of switching at the upper and lower trip
points.

Comparator Example No1

An operational amplifier is to be used with positive feedback to produce a Schmitt trigger circuit. If resistor,
R1 = 10kΩ and resistor, R2 = 90kΩ, what will be the values of the upper and lower switching points of the
reference voltage and the width of the hysteresis if the op-amp is connected to a dual ±10v power supply.

Given: R1 = 10kΩ, R2 = 90kΩ. Power supply +Vcc = 10v and -Vcc = 10v.

Feedback Fraction:

Upper Voltage Trip Point, VUTP


Lower Voltage Trip Point, VLTP

Hysteresis width:

Then the reference voltage VREF, switches between +1V and -1V as the output saturates from one level to the
other. Hopefully we can see from this simple example that the width of this hysteresis, 2 volts in total, can be
made larger or smaller simply by adjusting the voltage divider ratio of the feedback resistors R1 and R2.

The Voltage Comparator

Although we can use operational amplifiers such as the 741 as a basic comparator circuit, the problem with this
is that op-amps are only optimised for linear operation. That is where the input terminals are at virtually the
same voltage level and its output stage is designed to produce a linear output voltage that is not saturated for
long periods of time. Also standard operational amplifiers are designed to be used in closed-loop applications
with negative feedback from its output to its inverting input.

A dedicated voltage comparator on the other hand is a non-linear device that allows for heavy saturation, due
to its very high gain, when the input signals differs by a relatively small amount. The difference between an
op-amp comparator and a voltage comparator is in the output stage as a standard op-amp has an output stage
that is optimized for linear operation, while the output stage of a voltage comparator is optimized for
continuous saturated operation as it is always intended to be close to one supply rail or the other and not in
between.

Commercial comparators such as the LM311 single comparator, the LM339 quad comparator or the LM393
dual differential comparator, are voltage comparators which come in a standard IC package operating from a
single or dual supply. These dedicated voltage comparators are designed for the sole purpose of switching the
output very quickly from one saturated state the another as the transistors used for a voltage comparators
output stage are generally switching transistors.

Since voltage comparators convert a linear input signal into a digital output signal, they are commonly used to
connect two dissimilar electrical signals with different supply or reference voltages. As a result the output stage
of the voltage comparator is generally configured as a single open collector (or Drain) transistor switch with
open or closed states rather than actual output voltages as shown.

Voltage Comparator Circuit

Here, the open collector output from the voltage comparator is connected to a voltage source via a single pull-
up resistor (and an LED for indication) which pulls the single output high to the power supply. When the
output switch is HIGH it creates a high impedance path, therefore no current flows as VOUT = Vcc.

When the comparator changes state and the output switch is LOW, it creates a low impedance path to ground
and current flows through the pull-up resistor (and LED) causing a voltage drop across itself with the output
being pulled to the lower supply level, ground in this case.

Then we can see that there is very little difference between the schematic symbol of an op-amp comparator and
a voltage comparator or their internal circuits. The main difference is in the output stage with the open
collector or drain configuration is useful for driving relays, lamps, etc. By driving a transistor from the output
allows for a greater switching current capacity than that of the comparators output alone.

Op-amp Comparator Summary

In this tutorial about the Op-amp Comparator we have seen that a comparator circuit is basically an
operational amplifier without feedback, that is, the op-amp is used in its open-loop configuration, and when the
input voltage, VIN exceeds a preset reference voltage, VREF, the output changes state.
Due to the very high open-loop gain of the operational amplifier, using it with positive feedback or even with
no feedback at all causes the output to saturate to its supply rail producing one of two distinct output voltages
depending on the relative values of its two inputs. This bistable behaviour is non-linear and forms the basis of
op-amp comparator and Schmitt trigger circuits.

The output stages of dedicated comparators, such as the single LM311, the dual LM393 or the quad LM339 are
designed to operate in their saturation regions allowing these voltage comparator circuits to be widely used in
analogue-to-digital converter applications and for various types of voltage level detection circuits.

The erratic switching behaviour of an open-loop comparator can be easily overcome by adding positive
feedback between the output and input of the comparator. With positive feedback, the circuit has hysteresis
with the output switching occurring between two different switching points, UTP and LTP.

Op-amp window comparators are a type of voltage comparator circuit which uses two op-amp comparators to
produce a two-state output that indicates whether or not the input voltage is within a particular range or
window of values by using two reference voltages. An upper reference voltage and a lower reference voltage.

While operational amplifiers and comparators may look similar, they are very different and designed to be used
in different applications as an op-amp may be used as a comparator, a voltage comparator can not be used as an
op-amp due to its non-linear output stage.

We know from previous tutorials that an operational amplifier is an analogue device with a differential
analogue input and an analogue output and if operated in its open-loop configuration its output acts like a
comparator output. But dedicated voltage comparators (LM311, LM393, LM339) are widely available which
will perform much better than a standard op-amp comparator.

 Practical Example#1

1) When the inverting pin (-) is applied a fixed voltage reference, and the non-inverting (+) input pin is
subjected to an altering sensing volatge, the output of the opamp remains 0V or negative as long as the (+) pin
voltage stays below the (-) refernce pin voltage level.

Alternately as soon as the (+) pin volatge goes higher than the (-) voltage, the output quickly turns positive
supply DC level.

Example#2

1) Conversely, when the non-inverting pin (+) is applied a fixed voltage reference, and the inverting (-) input
pin is subjected to an altering sensing voltage, the output of the opamp remains supply DC level or positive as
long as the (-) pin voltage stays below the (+) refernce pin voltage level.

Alternately as soon as the (-) pin voltage goes higher than the (+) voltage, the output quickly turns negative or
switches OFF to 0V.
Basic Comparator Working

The circuit in the below figure operates in a relatively straightforward manner: The combination of R2 and
Zener diode D1 produces a fixed reference voltage (VREF). It is applied straight to the op-non-inverting amp's
input terminal, pin 3. Via the current limiting resistor R1, the input or test voltage VIN is connected to the
inverting input terminal (pin 2). When VIN is less than VREF, the op amp output is high (to positive
saturation), but when VIN is greater than VREF, the output is low (to negative saturation).

Op amp Comparator with High Voltage Input

As shown in the below figure, using a VOLTAGE DIVIDER, we can utilize a voltage comparator to provide
high-value, variable voltage triggering. There is no regenerative switching in this circuit.
Op Amp Comparator with High Value Input, Regenerative Switching

The next circuit, like the previous one, provides high-value, variable-voltage input switching (0 to 150 V). It
has regenerative switching capabilities.
Op Amp Comparator as Over Current Indicator

When the load current reaches a value defined by R6, the output turns high to indicate an over current
situation. By inverting the connections to IC1's pins 2 and 3, the output will go low to indicate an over-current
situation.
The diagram below demonstrates how a comparator circuit may be configured to operate as an over-current
switch, producing a high output when the load current exceeds a given value - which you can set using
potentiometer R6. Current sensing resistor RX is set such that it drops around 100 millivolts at the appropriate
trip point. As a result, a fixed reference voltage equal to 1/2 the supply voltage is provided to pin 3 of the op
amp through the voltage divider comprised of R3 and R4. Pin 2 receives a similar but current-dependent
voltage through Rx, R1, R6, and R2.

In fact, the two sets of components form a Wheatstone bridge, with one side supplying pin 3 and the other
supplying pin 2, and the op-amp serving as a bridge-balance detector. As a result, the circuit's trip points are
unaffected by fluctuations in supply voltage but are very sensitive to changes in load current.
Op amp Oscillator Circuits
The high-gain and wide passband of operational amplifier (op amp) ICs makes it possible for these units to
work like an oscillator within a wide range of frequency. The op amp oscillates immediately as soon as a
feedback is employed across its noninverting input and tweaked to the appropriate amplitude. The IC becomes
particularly important in resistance-capacitance-tuned oscillators, because its total gain becomes perfectly
suitable to offset the attenuation of the RC network.

Additionally, the double input of the differential IC enables not only positive feedback (for oscillation), but
additionally allows the negative feedback in a few circuits (for enhancing the output waveform).

1) Basic Working

A square-wave output can be easily generated by forcing an op amp to oscillate. The below indicated circuit
combines a Schmitt trigger and an integrator. Consider the following scenario: the output is high, and C1 is
charged through R3. Because of the resistor divider circuit R1, R2, the voltage at position 'A' is +0.9 V. As
soon as the voltage at B gets higher than this, the op amp's output becomes negative (low).
As a result, R3 discharges C1. Once the voltage on C1 falls below -0.9 V, the process is reversed, and the op
amp output returns to its high state. As a result, the circuit oscillates, creating a square wave with a voltage
range of +10V to -10y. The voltage fluctuations on C1 can be used to determine the working frequency of the
op amp oscillator. This is the collapsed portion of an exponential charge/discharge waveform, but we'll
disregard it and pretend it's linear (which it almost is). The frequency may be calculated using the following
formula:

F = I / ΔV x C

where I represents the charging current (about 100 A), ΔV represents the charge over C1 (3.6 V), and C
represents the capacitance in Farads.

The above design uses a dual supply for the operation, for a single supply operation, we can apply the
following configuration:

In the following paragraphs we will further learn about seven op amp IC oscillators, with three RC
configurations, three LC configurations, and one crystal set up. These are very common op amp oscillator
circuits which could be applied with pretty much any high-gain operational-amplifier IC.

Since any op amp can be used in these configurations, the precise pin numbers aren't specified, except from the
standard pins like the inverting input, noninverting input, input ground (common), and output.
The voltage supply pinouts are not indicated, considering that these (Vcc and Vee pinouts) can change with the
specific IC. Wherever feasible, the maximum functional working details is provided for all these basic
configurations.

2) TWIN-T RC AF OSCILLATOR

The first figure below illustrates the a resistance-capacitance tuned AF op amp oscillator twin-T null network.
This is implemented through the RC network of C1-C2-C3-R2-R3-R4, which decides the frequency level of
the output.

The op amp IC needs to have a voltage gain of 60 dB. This set up is basically an intensely tuned af amplifier
on which a positive feedback is introduced so that it begins oscillating.
The twin-T network is introduced in the negative-feedback loop, and since it works like a null network it helps
in eliminating a particular frequency (fr) through the negative feedback. The IC gain gets terminated
appropriately at all other frequencies, while fr is conveniently transmitted forward. In this oscillator network,
the following formulas can be used for the calculations:

 C1 = C2 = 1/2 C3
 R2 = R3 = 2R4

 fr = 1 / (2πR2C1)

In the above formula,


C's will be in farads,
R's will be in ohms,
and the unit of fr will be in hertz.

Coupling capacitor C4 blocks the DC current, and offers a high capacitance with respect to the capacitors C1,
C2, and C3. It consequently doesn't have an effect on fr.

Resistor R1 offers a high resistance, based on the IC's input impedance, and helps to decrease loading of the
twin-T network through the IC input circuit.

The inclusion of positive feedback, by means of the signal divider R5-R6, results in this very sharply tuned
amplifier to oscillate with the frequency fr. When the potentiometer R6 is adjusted to the level where the circuit
merely starts to oscillate, output-signal distortion is found to be minimal.

The op amp oscillator circuit could be made to work like a continuously tunable oscillator (e.g., from 20 Hz to
20 kHz) simply by replacing the resistors R2, R3, R4 with a 3-ganged potentiometer, and selecting capacitors
C1, C2, and C3 in trios to adjust the bands.

Output control could be accomplished through a potentiometer which may be configured either to the output or
introduced between stages of the IC.
3) PHASE-SHIFT RC AF OSCILLATOR

The phase-shift form of tuned resistance-capacitance audio frequency oscillator are popular for their extremely
low harmonic distortion. In this form of oscillator, RC tuning is achieved through a 180-degree phase-shift
network configured within the feedback loop of an inverting amplifier.
The network consequently generates the precise signal phase rotation for the oscillation. Fig. 2 above
demonstrates the configuration for a phase-shift-type IC oscillator. In this set up, the phase shift network
includes 3 RC legs in cascade pattern which are identical to each other: C1-R2, C2-R3, and C3-R4.

In this network , C1 = C2 = C3, and R2 = R3 = R4. All of these legs brings about a 60 degrees of phase shift.
The frequency level where the entire shift gets to 180 degrees can be determined through the below given
formula:

fr= 1/ (10.88R2C1)

To be able to offset the built in attenuation of the RC system, the op amp's gain must be around 40 dB. The op
amp's noninverting input isn't utilized in this configuration, as it is delivered back to the ground by means of
the resistor R1 ( which can be around 1000 ohms).

This op amp oscillator circuit could be turned into a continuously tunable type in the range of 20 Hz to 20 kHz,
simply by replacing resistors R2, R3, R4, with a 3-gang potentiometer, and by switching the capacitors C1, C2,
and C3 in trios, in order to select the bands.

But, the circuit's attenuation increases as the values of the resistances is reduced, and this situation could lead
to the output-signal amplitude going down very fast with frequency, and oscillation may simply stop if R2, R3,
and R4 are adjusted to lower values with the high frequencies.

Output control could be provided through a potentiometer which could be either connected to the output of the
op amp oscillator circuit or introduced between the stages of the op amp.

4) WIEN-BRIDGE RC AF OSCILLATOR

We have so far learned that the resistance-capacitance-tuned audio frequency oscillators involve 3 resistances
and 3 capacitances for the tuning process. However, the op amp oscillator circuit displayed in Fig. 3 below
requires just a couple of resistances (R1 and R2) and a pair of capacitances (C1 and C2) for the same tuning
facility.
The C1-C2-R1-R2 network forms the 50 % of a Wien bridge network which, just like the twin-T network in
Fig. 3-1, is sensitive to the frequency. The RC configuration is attached inside the positive-feedback link (on
the noninverting input terminal). In this configuration, C1= C2, R1 = R2, and the frequency response can be
determined using the below given equation:

fr = 1 / (2πR1C1)

In the above equation,


fr will be in hertz,
R1 will be in ohms,
C1 will be in farads

The resistors R3, and R4 does the job of providing the negative feedback (that works like a a signal voltage
divider) to the inverting input terminal. This negative feedback helps to reduce the output-signal distortion;
but, it should be implemented with the right proportion (by appropriately adjusting R3 and R4). This is
important to ensure that it doesn't terminate the positive feedback leading to the elimination of the oscillation.

This form of op amp oscillator circuits could be easily turned into a continuously tunable oscillator in the range
of 20 Hz to 1 MHz, simply by replacing the resistors R1, and R2 with a dual-gang potentiometer, and by
ensuring that the capacitors C1 and C2 are switched in pairs in order to adjust frequency bands.

The tuning of the oscillator circuit can be implemented over a large frequency range, but, its output-signal
amplitude might show a varying tendency with response to the frequency.
Nevertheless this varying tendency of the amplitude could be decreased using an appropriately dimensioned
nonlinear resistor, for instance a thermistor, varistor, or double-ended zener diode, hooked up in between point
"X" and ground. Controlling the output of the oscillator can be executed through a potentiometer which may be
either incorporated into the output or placed between the stages of the IC.

5) TRANSFORMER-FEEDBACK AF OSCILLATOR

Fig. 4 below displays the a basic af oscillator configuration where a small audio transformer (T1) is used for
providing both the feedback and the tuning which forces the op amp to work like an oscillator. Any low-gain
op amp IC could work effectively in this configuration.

In this oscillator set up, transformer T1 provides the positive feedback to the non-inverting input of the op amp.
T1 transformer can be any form of small transformer. The frequency of oscillation can be calculated through
the capacitance C1 and the inductance (L) of the L1 transformer winding. The below given formulas can be
used for the Fig. 3-4:

 C1 = 1 / (4π2F2L)
 L = 1 / (4π2F2C1)

 fr = 1 / (2π √LC1)

In the above formula,


fr is measured in hertz,
L is measured in henrys,
C1 is measured in farads

It is crucial to ensure that the connection of the transformer winding with the circuit is phased correctly for
sustaining the oscillation. However if you find oscillations not working because of wrong transformer winding
connections, you may need only one winding of the transformer to be reversed, that's all.

Resistors R1 and R2 do the job of applying the negative feedback, through a signal-voltage divider, to the
inverting input terminal. This negative feedback helps to minimize output-signal distortion; but, this must be
applied in a properly balanced manner (by suitably adjusting R1 and R2).

This is important to ensure that it doesn't suppress the positive feedback and as a result destroys the oscillation.
The output can be controlled through a potentiometer which may be in two ways either to the output or placed
between the IC stages.

6) TRANSFORMER-FEEDBACK RF OSCILLATOR

The radio-frequency or the RF oscillator circuit indicated below in Fig. 5 is identical to the transformer-
feedback af oscillator explained in the previous section, except that in this particular rf oscillator, positive
feedback for the oscillation and tuning are supplied through an air-core transformer, L1-L2. Any low-gain IC
could work effectively in this circuit.
In this op amp oscillator circuit set up, the noninverting input of the op amp gets the positive feedback by
means of the inductors L1-L2 together. (L1 can be the winding of the transformer that consists of higher
number of turns, while L2 can approximately have one-quarter of the turns in L1. L2 winding needs to be
wound closely to the L2 winding, however this coupling does not need to be tightly wound. The oscillation
frequency fr can be calculated through the values of the capacitor C1 and the inductor L1.

This frequency fr can be determined through formulas as given below:

 C1 = 1 / (4π2F2L)
 L1 = 1 / (4π2F2C1)

 fr = 1 / (2π √L1C1)

In the above equation, the unit of C1 is picofarads, unit of L1 is in microhenrys, and the unit of fr is in
megahertz.

It is crucial to connect the transformer winding with the right phasing in order to start the oscillation. That said,
if you find the oscillations not happening, because of a wrong winding connection, you would only require just
one winding ends to be reversed, that's all.

R1 and R2 performs the role of applying the negative feedback to the inverting input terminal of the op amp,
by forming a signal-voltage divider. This negative feedback helps to stabilizes the working of the op amp
oscillator and minimizes the output-signal distortion.

But, this negative feedback needs to be correctly balanced by appropriately adjusting the values of R1 and R2.
This is important to ensure that it doesn't terminate the positive feedback and in the course destroys the
oscillation.

The variable capacitor C1 can be used for getting a continuous tuning of the oscillator. In order to get a larger
range of adjustment, L1 and L2 could be modified as pairs for selecting the frequency bands.

7) USING AF/RF OSCILLATOR TOGETHER

The Fig. 6 shown below exhibits an oscillator configuration that, which uses plug-in type inductors and
capacitors, for producing both audio-frequency or radio-frequency signals through a diverse range of
frequency.
In this op amp oscillator set up, the positive and negative feedback are used both together. The tuned circuit
built using the L1, C1 parts connected in the negative-feedback loop decides the oscillation frequency of the
circuit. Since the L1, C1 works like a wavetrap, this tuned stage of the circuit eliminates its resonant frequency,
fr, from the feedback loop.

The op amp consequently behaves like a sharply tuned amplifier, becomes responsible for transmitting the
frequency fr. However, its gain gets terminated at all other frequencies. The positive feedback, provided by the
resistors R1 and R2 which are configured like a signal voltage divider, subsequently enables the op amp to
oscillate at frequency fr.

The parameters in this circuit can be calculated using the following given formulas:
Using a high value capacitance and inductance together enables the generation of audio frequencies, whereas
using lower values of capacitance and inductance enables the production of radio frequencies.

The strength at which the oscillation takes place is determined by the the adjustment of positive-feedback
potentiometer R2. Therefore the R2 allows controlling the level of output-signal amplitude. The circuit can
work using a number of different op amps.

Considering that output-coupling capacitor C2 is required to generate both low and high frequencies, its value
must be suitably adjusted to some intermediate value, for example it can be 0.01 µF, unless of course the user
is prepared to change this capacitor in addition to L1 and C1.

8) CRYSTAL-CONTROLLED RF OSCILLATOR

The below given Fig. 7 demonstrates an op amp based a crystal-controlled RF oscillator circuit that can work
without the need of any tuning. This configuration can operate with multistage op amp circuits with various
sensitivity levels. Having said that,it is advised to make use of medium and high-gain op amps.

In this configuration, the crystal (XTAL) works like an exceptionally high-Q bandpass filter within the op
amps's positive-feedback loop. The positive-feedback current transferred through the crystal, builds up a
voltage drop around resistor R2, which is utilized on the op amp's noninverting input pin of the IC.
This finally forces the circuity to oscillate with the crystal frequency. Capacitor C1 is utilized simply for
blocking the DC content, through a capacitance whose value specifically selected for low reactance at the
crystal frequency.

The input ground of the op amp which is common ground is connected directly to the circuit ground, as
indicated in the diagram. The circuit can be also seen having a negative-feedback loop, created using the
resistors R1 and R3, which constitues a signal voltage divider network.

Negative-feedback current flowing by means of this resistive divider causes a voltage drop to appear across
resistor R1, which is supplied to the op amp's inverting input pin.

It may be important to adjust the amplitude of this voltage by appropriately setting up the values of the
resistors R1 and R3. This ensures that the positive feedback does not gets terminated, eventually killing the
oscillation.

The use of the negative feedback helps to enhance stability of this op amp oscillator circuit and also helps to
minimize the output-signal distortion. Nevertheless, this could be totally furnished only when a high harmonic
output is needed, for example, in many of the transmitter type circuit applications

DETECTORS
A detector, or radiation transducer, is any device that converts an amount of radiation into some other
measurable phenomenon. Ultimately, most of these other measurable phenomena will be tied to an electrical
signal.

There are two main types of detectors: photon detectors and thermal detectors. All detectors have similar
characteristics:

 The output of a detector must respond to changes in the incident light intensity. The ability to respond
is expressed by quantities such as responsivity, sensitivity, and dynamic range.
 The output of a detector must respond quickly to quick changes in incident light intensity. This can be
quantified by a detector time constant.
 A detector must have a minimal dark signal (also called dark current if current is the measurable of the
detector). The dark signal is the signal when no light impinges on the detector.
 A detector must have an acceptable level of noise. Noise is unwanted signal from any source other than
the signal of interest.

Peak Detector
Definition: Peak detector circuits are used to determine the peak (maximum) value of an input signal. It
stores the peak value of input voltages for infinite time duration until it comes to reset condition. The peak
detector circuit utilizes its property of following the highest value of an input signal and storing it.

Rectifier circuits usually provide an output in proportion to the average value of the input. However, some
application requires measurement of the peak value of the signal. Thus, peak detectors are used.

Usually, the peak of non-sinusoidal waveforms is measured using a peak detector. As traditional ac voltmeter
cannot measure the peak of such signals.

Circuit Working of Peak detector

The figure below shows the circuit of a basic positive peak detector-

It consists of a diode and capacitor along with an op-amp as shown above. The circuit does not require any
complex component in order to determine the peak of the input waveform.

Working Principle

The working principle of the circuit is such that, the peak of the input waveform is followed and stored in
terms of voltage in the capacitor.

By the time on moving further, if the circuit detects a higher peak, the new peak value is stored in the capacitor
until it is discharged.
The capacitor employed in the circuit is charged through the diode by the applied input signal. The small
voltage drop across the diode is ignored and the capacitor is charged up to the highest peak of the applied input
signal.

Let us consider initially the capacitor is charged to voltage Vc. The diode employed in the circuit gets forward
biased when the applied input voltage Vin exceeds the capacitor voltage Vc. Thereby allowing the circuit to
behave as a voltage follower. The output voltage follows the applied input voltage until Vin is more than Vc.

As the input voltage Vin reduces below the value of capacitive voltage Vc, it causes the diode to get reverse
biased. In such condition, the capacitor retains the value until the input again exceeds the value stored in the
capacitor.

The figure below shows the output voltage waveform for an applied input signal.

As we can see in the waveform shown above, at time t1, the circuit misses the peak of the input signal as it is
less than the previous peak of the input signal. Thereby allowing the capacitor to hold the value of the
previously occurred peak.

As it is a positive peak detector, one can also construct a negative peak detector circuit, that will hold the
lowest or most negative signal voltage. This is basically done by reversing the polarities of the diode in the
circuit.
Improvement in peak detector circuit

The figure below shows the circuit of an improved peak detector. It is used to buffer the source of the signal
from that of the capacitor.

As we can see the circuit is comprised of 2 Op-amps. However, the basic circuit of the peak detector contains
only one Op-amp. A high impedance load is offered by the op-amp A1 to the source. While op-amp A2
performs buffering action in between the load and capacitor.

The same basic principle is applied in this circuit also. The voltage at the output side is the similar as the peak
of the input signal stored in the capacitor.

Its working is such that, as the input voltage becomes higher than the charge stored on the capacitor, it charges
itself with the new higher value of input signal.

However, for a smaller value of the input, the capacitor sticks to the previous higher value. The diode D2
employed here restricts the output of op-amp A1 from reaching negative saturation.

This basically provides an improvement in the recovery time of op-amp A1 at the condition of attaining a
higher peak than the previous. The two resistances serve as the path for the bias current of input to A1.

To prevent the effect of the offset voltage, the value of the two resistances R1 and R2 are kept equal.

The necessary frequency compensation must be given to op-amp A1 in order to have stability against
oscillations.
Applications of Peak detector
1. It is used in the analysis of spectral and mass spectrometer.
2. Peak detector finds its application in destructive testing.

3. It is used for instrumentation measurement, mostly in amplitude modulated wave communication.

4. It widely finds applications in sound measuring instruments.

Zero Crossing Detector


Definition: An op-amp detector that has the ability to detect the change from positive to negative or negative to
a positive level of a sinusoidal waveform is known as a zero crossing detector. More specifically, we can say
that it detects the zero crossing of the applied ac signal.

It is basically a voltage comparator whose output changes when the input signal crosses the zero of the
reference voltage level. Thus it is named so.

It is also known to be a square wave generator as the applied input signal is converted into a square wave by
the zero crossing detector.

Circuit Diagram of Zero Crossing Detector

The figure below represents the circuit of a zero crossing detector using inverting op-amp:
Here, the input signal Vi is provided to the inverting terminal of the op-amp while the non-inverting terminal is
grounded by making use of two resistors R1 and R2.

As we can see that analog input signal is provided at the inverting terminal of the op-amp. Thus, the waveform
of the signal at the output will hold reverse polarity. This we will discuss under working of the detector.

Working of Zero Crossing Detector

As we have already discussed that it detects the point where the input signal crosses zero of the reference
voltage level. For every crossing, the saturation level of the output signal changes from one to another.

Let us consider the circuit given above in order to understand the working.

As we have already mentioned that the reference level is set at 0 and applied at the non-inverting terminal of
the op-amp. The sine wave applied at the inverting terminal of the op-amp is compared with the reference level
each time the phase of the wave changes either from positive to negative or negative to positive.

Firstly, when positive half of the sinusoidal signal appears at the input. Then the op-amp comparator compares
the reference voltage level with the peak level of the applied signal
And we know the reference level is 0, thus

So, we will have

Secondly, in case of the negative half of the sinusoidal signal, the op-amp comparator again compares the
reference voltage level with the peak of the applied signal.

As this time the circuit is dealing with negative half of the signal, thus the peak will have a negative polarity.

Again

Thus,

So, we get

In this way, the zero crossing detector detects the change in the level of the applied signal.

Input and Output Waveform

From the beginning, we are mentioning that a zero crossing detector is also known to be a square wave
generator. As the output of the window comparator is nothing but a square wave.

Let us now have a look at the input and output waveform of a zero crossing detector:
As we have recently discussed that V0 for the positive half of the applied signal is – Vsat,

This is the reason why we have achieved negative half of the square wave at the output when positive half of
the sinusoidal signal is applied. While V0 for the negative half of the sinusoidal signal is + Vsat,

Thus positive half of the square wave is obtained at the output for the negative half of the sinusoidal signal.
This is clearly shown in the waveform representation.

So, on observing the output waveform we can say that the output reflects the presence of input signal above or
below the reference level i.e., 0 volts.
Applications of Zero Crossing Detector

Zero crossing detectors widely find applications in electronics circuits mainly for switching purpose and in
phase locked loop. Also, these are used in frequency counters and in phase meters.

It can also be used as phase meters, as it can be used to measure the phase angle between two voltage applied
at its terminals.

CURRENT SENSOR
A current sensor circuit is a circuit that can measure the current flowing through it.

Current sensor circuits are used extensively in systems such as battery management systems in order to detect
the current to monitor for overcurrent, a short circuit, and the state of charge of the battery system. This keeps
the system safe and can protect the system from devastating, dangerous conditions such as fires.
Current sense amplifiers
A current sense amplifier is a differential amplifier providing an analog output voltage proportional to the
current flowing into a load connected on its input.

Current sensing solutions add valuable safety and protection features to system designs. They provide
information to control current in power systems and avoid overheating and short circuits. Current sensing is
also an essential part of energy metering to ensure power-efficiency and minimize environmental impact.

Key features

The main features of ST's portfolio of current sensing ICs ensure robustness and application safety:

 -20 to +70 V line monitoring


 Bidirectional or unidirectional current measurement

 Integrated solutions for faster design time and reduced bill of materials

o Integrated EMI filters

o Pin selectable gain

o Shutdown function

 Robust devices that do not require external protection

 Automotive-grade qualified

 High-voltage

Tolerance to high voltage ranges and protection mechanisms to handle negative voltage are essential in high-
power systems such as batteries in electric vehicles. Our current sense amplifiers can work in high voltage
applications avoiding additional external protections components and simplifying the final schematic.

Precision / high-accuracy

Using a precision current sense amplifier allows designers to measure small voltage drops across shunt
resistors with minimal error. Small shunt resistors values are necessary to minimize the power dissipation.
Thanks to highly accurate current measurements, precision current sense amplifiers offer a better efficiency
and thermal performance.
Current sense amplifiers

A current sense amplifier is a special purpose integrated circuit differential amplifier that is designed to sense
the voltage developed across a current shunt and output a voltage proportional to the measured current. The
voltage across the current sense resistor is typically in the range of 1 to 100 millivolts, but may ride on the
nominal buss voltage potential. The CSA is designed to have a high common mode rejection ratio (CMRR) to
eliminate the buss voltage from the output. These devices are designed to handle common mode voltages in
excess of their own supply voltage.

The simplified schematic of a current sense amplifier in Figure 2 shows a typical differential amplifier with
inverting and non-inverting inputs and a single output.

Figure 2: The simplified schematic of a typical current sense amplifier. The gain is set by the ratios of resistors
R2 to R1 and R4 to R3. (Image source: Digi-Key Electronics)

The resistor values set the gain of the CSA. The structure is symmetrical with R1 = R3 and R2 = R4. The gain
is determined by the ratio of R2 to R1 and R4 to R3. In a typical CSA implementation such as the high
performance Texas Instruments INA210CIDCKR, R2 and R4 are 1 megohm, and R1 and R3 are 5 kilohms for a
gain of 200 volts/volt. The gain accuracy for this version of the amplifier is 0.5%. The rated supply voltage for
this IC is from 2.7 to 26 volts, but the maximum common mode input voltage is -3 to 26 volts, regardless of
the supply voltage. This is the key distinguishing characteristic of the CSA. The input offset voltage is only 35
microvolts and the CMRR is typically 140 dB.

Depending upon the application, a more economical CSA choice might be the Texas Instruments
INA180B3IDBVR. This CSA has an identical common mode input voltage range, and is available with gains of
20, 50, 100, and 200 volts/volt. Gain accuracy is 1% and the CMRR is 100 dB with an input offset voltage of
100 microvolts.

Current sensing configurations

There are two current sensing topologies; high side and low side sensing. The high side configuration places
the sense resistor between the voltage source and the load, while low side sensing places the shunt between the
load and ground (Figure 3).

Figure 3: High side sensing places the shunt (RSENSE) between the source and the load, while low side sensing
places it between the load and ground. (Image source: Digi-Key Electronics)

Low side sensing is ground referenced and has a low input common mode voltage. This makes it easier on the
current monitoring amplifier and related circuitry, which usually translates into lower cost.

The disadvantages on the low side connection is that it lifts the load above ground. Current flowing through the
shunt resistor raises or lowers the system reference level as current values vary. This can lead to problems in a
control loop. Also, short circuits to ground of the voltage bus around the shunt resistor are not detectable in this
circuit configuration.

The advantages of the high side topology are that the load and the system reference are fixed at ground
independent of the monitored current, and bus shorts to ground are easily detected.

On the down side, there is a common mode voltage close to the bus voltage at the input of the measuring
circuit. In addition to stressing the current sense amplifier, in some applications it may also require that the
CSA output level be shifted down to near the system reference level.

The issues related to high side sensing have prompted the development of many families of CSAs. The
INA180 and INA210 are both new CSAs that can handle common mode voltages of from -3 to 26 volts,
independent of their supply voltages. They are intended for applications such as motor control, battery
monitoring, and power management, among others. Applications with higher bus voltages can use other CSAs
that offer input common mode voltage ranges up to 80 volts. For higher voltages, CSAs require either the use
of external components to isolate the amplifier from the common mode voltage, or the use of isolated
amplifiers.

Selecting the sense resistor value

The value of the sense resistor is set to guarantee that the voltage drop across the resistor over the expected bus
current range is well above the CSA voltage offset and any additive vertical noise. The power rating of the
sense resistor will be determined by the maximum bus current and maximum voltage drop.

Consider as an example a 12 volt bus expected to carry a maximum of 2 amps. If the INA210 CSA is used, the
voltage drop across the shunt should be greater than the maximum offset voltage of 35 microvolts.

The common mode rejection ratio is in the range of 105 to 140 dB. Using the lower value (105 dB), the 12 volt
bus potential (the common mode voltage), will be attenuated to approximately 67 microvolts. This will appear
as an offset voltage at the CSA output, multiplied by the amplifier’s gain. This common mode residue offset is
not due to the current being measured, and in this case the residue is not problematic because it is less than 1%
of the measured value.

The sense resistor value must be chosen to assure a voltage drop much greater than the offset voltage. For a 2
volt unipolar swing at the output of the INA210, which has a gain of 200, the input should be 10 millivolts.
This is significantly greater than the input voltage offset or the common mode residue that was specified. At a
nominal maximum current of 2 amps, the sense resistor value should be 5 milliohm. The power rating of the
shunt should be at least twice the nominal expected maximum power dissipation of 20 milliwatts.
Difference between Current Sense Amplifier and Normal Amplifier

Normal amplifiers and current sense amplifiers have different specifications and they are made for specific things.
There are many types of Op-Amps, you can read this article to know the popular Op-Amps IC and their applications.
Normal amplifiers could not amplify a very small amount of voltage and have low CMRR. On the other hand, precision
current-sense amplifiers could detect and amplify a very small amount of voltages as well as the CMRR is relatively
high.

For the normal differential amplifiers or standard operational amplifiers, the power source is connected between two
power supply rails (Vcc and Vee) and the amplifiers can only operate on the signals that lie behind the power rails or
have common ground paths. An outside voltage of the used power rail could trigger the internal ESD protection diodes
if an external voltage is applied into the input pin of the standard amplifier and could cause a large current to flow.

But, current sense amplifiers are designed in a way that despite the low-voltage power rail (such as Vcc = 3.3 V and V =
0V), the amplifier can withstand a much higher pin voltage than the supplied Vcc. The amplifiers use an excellent
power path protocol for its operation. Whenever the input voltage is lower than the VCC, the amplifier changes its
input supply and gets powered from the input voltages.

Common Mode Voltage and CMRR

Common mode voltage is an important parameter for both normal amplifiers and current sense amplifiers. The
common-mode voltage is the average voltage which is applied across the two inputs of the amplifier. This Voltage is so
much important because the op-amp has limited capabilities to differentiate and produce output based on the
common-mode voltage. A normal op-amp supports a small range of common-mode voltage that is not suitable for the
precision level current sensing operations. But in the case of current sense amplifiers, the common-mode voltage
ranges much wider than the actual supply voltage of the amplifier. For example, in the case of the current sense
amplifier, INA240 is capable of supporting a common-mode voltage between -4 V to +80 V while running on supply as
low as 2.7 V. 

On the other hand, CMRR, the common-mode rejection ratio (CMRR) is the ratio of differential gain, and the common-
mode gain. In the case of an ideal op-amp, the CMRR is infinite, but in practical circuits, it ranges typically 80 to 100 dB.
The high CMRR denotes how much of the common-mode signal will reflect on the measurement. Thus, for a current
sense amplifier, it is an important parameter as it will reflect the very low common-mode signal across the output, thus
creating the possibilities to open up a wide range of current sensing capabilities. Current sense amplifiers have high
CMRR and it could sense small common-mode signals. CMRR is also responsible for reducing noise on the current sense
lines.

How to Design a Circuit using Current Sense Amplifier IC

Suppose a design with a 12V 1A line, where a high current sensing circuit needs to be used. In such a case, a current
sense circuit can be built using current sense amplifiers. But before proceeding with the circuit, one needs to select a
current sense amplifier for this purpose.

Since the maximum current rating is 1A, and no specified load is described, a current sense amplifier needs to be
selected that works with 12V supply and could sense more than the 1A of the current rating. As discussed, one needs to
select something for the low-level side or high-level side. In this case, a high side current sensing can be used for
detecting a fault or proper short circuit condition. However, low side current sensing can also work. We will discuss the
difference between these both later in this article.

Since the load could be capacitive or inductive, inrush current could occur, thus a low-value resistor can be used with a
dedicated current sense amplifier. For this circuit, LT6108 can be used since it works with 2.7V to 60V. The CMRR of this
amplifier is also very high, up to 125dB. Therefore, this amplifier could work in 12V supply as well as it could detect very
low current flow.

The above current sense amplifier circuit is build using LT6108. The 0.1 Ohms resistor is the sense resistor that could
produce a voltage drop during the current flow through the resistor. On the other hand, the IRF9640 is the switching
MOSFET that is controlled by the 2N2700 MOSFET. The amplifier could shut off the switching MOSFET for a pre-set
value. In the above circuit, a trip point is created across 250mA. Thus the amplifier will shut off the load MOSFET if the
current flow through the resistor crosses more than 250mA. However, for a trip voltage above 1A, the targeted value
can be set by the voltage divider across the INC pin of the current sense amplifier. The Vout at OUTA pin of the current
sense amplifier can be used to check the current flow rating through the current sense resistor.

The above circuit can also be constructed using another current sense amplifier that uses a wide range of supply
voltage more than 12V and could accept the input irrespective of the supply voltage.

Types of Current Sensing ICs with Application Circuit  

Low Side Current Sense

As discussed previously, a shunt resistor is used to sense the current, and depending on the shunt resistor placement,
the current sense technique varies. A low side current measurement uses the. Due to this, the GND path of the active
load is created in such a way that whenever the load current returns to the GND, it always flows through the shunt
resistor. In the below images, low side current measurement circuits are shown.

The above circuits are practical examples of the Low side current sensing technique. The left image is using the
INA181Current Sense Amplifier from Texas Instruments and providing the output to an ADC that will provide the data
in I2C protocol. The right image is using the AD8202 Current Sense Amplifier from Analog Devices. It is sensing Low side
current of an inductive load.

 
Advantages:

The advantages of Low side current measurements are, it is simple to implement because the sense voltage across the
current shunt resistor is in the GND referenced. In this configuration, a low voltage current sense amplifier can be used
due to the small voltage drop across the shunt resistor. Also, due to the low sensed voltage, common-mode rejection
can be ignored.

Disadvantages:

The major disadvantage of the low side current measurement is that the load gets offset from the ground-referenced.
This happens due to the series placement of a shunt resistor in the ground plane. Due to the broken ground reference,
this situation can become problematic in a short circuit situation between load and the ground as the shunt resistor
unable to detect very high current flow through the load circuit.

High Side Current Sense

Same as Low side current sense, a high side current measurement uses the same current shunt resistor but the
placement takes place between the power source and the active load. In the below images, high current sense
amplifier circuits are shown.

The above circuits are practical examples of the High side current sensing technique. The left image is using INA240
from Texas Instruments and providing the output to an ADC that will provide the data in I2C protocol. The right image is
using LT6100 from Analog Devices. It is sensing High side current along with a fuse of a load.
 

Advantages:

High side current measurements have two advantages over low side measurements. First, It overrides the drawbacks of
low side current sensing that is unable to detect load short circuit with the ground. Due to the placement of a shunt
resistor in the power plain, it can easily detect the short circuit in load and ground.

Second, in this circuit, the load is placed in a proper ground referenced and the differential input from the shunt
resistor could detect exact load current without additional effort if ADC conversion is used.

Disadvantages:

But the high side current measurement technique requires high common-mode rejection because the small voltage
that is developed across the current shunt resistor is below the load supply voltage.

Bidirectional Current Sense

A bidirectional current sense circuit uses a simple shunt resistor but the amplifier needs capabilities to sense a wide
range of common-mode voltages. The bidirectional current sense technique is a little bit complex than the Low and
High side sensing. There are different ways to sense bidirectional currents. In some cases, such as the above image
where two current sense amplifiers INA300 are connected in a way that will detect the current flow in both ways by
anyone of the current sense amplifiers. The circuit requires Reverse polarity protection along with a switching
technique that will switch the amplifier output depending on the polarity of the circuit.

Other ways to detect the bidirectional current is to use an input voltage for a reference, then the amplifier senses the
drop voltage across the sense resistor and compares it with the reference voltage. If the drop voltage is above the
known reference voltage, it is in one direction while the drop voltage below the known reference voltage is in the
opposite direction.

Isolated Current Sense

Isolated current sensing technique uses proper CT transformer or hall effect induction that produces a proportional
voltage in a transformer tap when current flows through another tap of the transformer.

The above image is another practical example of the current sense amplifier using the isolated current transformer. It
uses popular current sensing amplifier INA199 from Texas Instruments.

You might also like