Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] Help .. opamp comparator circuit...

Status
Not open for further replies.

Shreehari

Member level 4
Joined
Jun 18, 2010
Messages
68
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,288
Location
mangalore
Activity points
1,735
I am constructing opamp comparator circuit uing single opamp741.simply by giving two different DC volatges to Inverting and nonInverting input.

Here I had biased the opamp ith 0v and by +5v(V- and V+).It was giving +4.5 V for high and +1.5V for low.But as per the circuit it should swing between 0V (low)and +5v(high) right?
Now I had shorted both inverting and noninverting input and connected to ground.But it is giving +4.5V,In my opinion it should be 0v right?

My question is my OPAMP working correctly?if so give justification.
If I want to to have swing between 0V and 5V then what should I do?
Please Reply it urgently
 

If you force inverting and noninverting inputs to different voltages you will break the op-amp.
 

When connecting a 741 to a 5V single supply, then the output voltages you're measuring are not uncommon. A 741 can never fully reach its supply rail on its output, becuase of the design of the output circuit of the opamp. You can find the minimum and maximum output voltage in the datasheet under 'Output voltage swing'. This output voltage swing depends on the output load. The heavier the load, the more limited the output voltage swing becomes. If you really need to reach 0V and 5V on the output, you'll either have to supply the 741 with a symmetrical power supply (let's + and - 7V or so, depending on the load), or you'll need to find another type of opamp. This is a so called opamp with a rail-to-rail output. Additionally, please note that not all opamps can handle large diferences between the voltage applied to the inverting and non-inverting input. This parameter is called the differential mode input voltage range and can also be found in most datasheets.
My advise is not to use a opamp if your trying to build a comparator, because they are not intended for it. You'd better use a 'true' comparator IC, such as the LM2903. These kind op ICs are specifically designed to handle large differences between the input voltages and can produce 'rail-to-rail' output voltages. Please note that the LM2903 has an open collector, so a pullup resistor on the output is needed. Comparators with a push-pull outputs are also available.

By the way, applying the same voltage to both the inverting and non-inverting inputs, puts the output in an undefined state (either low or high). This accounts for both opamp and comparator ICs. The output of a comparator circuit always 'chooses' a side, depending on the offset voltage (also found in datasheet). The offset voltage causes on of the inputs (you never know which) to be slightly higher than the other, even when connected to each other. When this higher voltage is present on the non-inverting (+) input, than the output becomes high. When the offset causes the inverting (-) input to be slightly higher, than the output becomes low.

Hopes this helps you a little...
 
Thank u very much Alexvw..u had given a brilliant answer...

---------- Post added at 07:33 ---------- Previous post was at 07:18 ----------

but how I can swing the output voltages between 0v and 5V when the supply is +7V and -7V...Because it should show -7V fo low and +7V for high right?

---------- Post added at 07:35 ---------- Previous post was at 07:33 ----------

why input resistance matters?
 

Hi Shreehari,

independent on supply and output swing questiuons - an opamp exhibits good comparator properties only in case of a moderate positive feedback. But, be aware that this is connected with hysteresis effects (threshold differs somewhat for up and down switching actions).
 
so you meant to say 741 is not good for comparator actions..So i will use LM 339,But is this an open collector output..how to choose resistance value to add?
 

That depends on what you connect on the output of the comparator and you're power consumption requirements. If you're just connecting to a CMOS or TTL, than somewhere between 4k7 and 47k should do. Generally, a lower resistance value will increase immunity against electromagnatic disturbances. However, when you connect a circuit to it with a low input impedance, the output voltage will not be getting high enough (Ohm's law). Secondly, a pull up resistor with a low value will increase power consumption.

An opamp can never fully reach the supply rail on it's output (both for low and high), because of the design of the linear output amplier circuit. As you might know, electronics are never 'ideal' and always have losses/voltage drops. A comparator just has a simple 'switch' at the output (usually also a transistor or FET). For a open collector output, the output is left open when the voltage on the + input is higher than on the - input. When - is higher than +, than the output is shorted to GND. For a push-pull comparator, the output is connected to the + supply voltage when the + is higher than - input and connected to GND (or the - supply) when the - input is higher than the + input.
 
Thank u alexvw...again your explanation really good..is there is any need to connect the pull up resistor to ground?as one end is connected to +Vcc ...
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top