Post Go back to editing

AD822 Output on Multisim Simulator

Hi!

My name is Claudio, I'm a hobbyist and this is the first time I'm writing in this forum.
I have realized with a simulation program (Multisim) a circuit that uses an operation amplifier AD822. I was trying to get a circuit that would have this output:
VCC (+5V) when the difference between inputs exceeds + 20mV
VEE (-5V) when the input difference is less than -20mV
0V when the difference between the inputs is between -20mV and + 20mV
I would like to make a comparator with three states.
Playing with the values of feedback and input resistances, I managed to get my purpose on the simulator.
When the input difference is between a few mV, output is almost zero volt.
On the simulator this work well ( You see in the oscilloscope the central part between 15mS and 30ms where the output assumes a value close to zero).
Is it a valid configuration?
I built the circuit.
The condition in which the output should be close to zero volt however does not work; I get a fast and continuous variation between + 5V and -5V.

What am I doing wrong? Is it possible that the simulation is not true?
attachments.zip
  • Hi Claudio,

    Your circuit is a Voltage Subtractor that follows this equation:

    Vo = VINP + {(R5/R8)(VINP - VINN)} = VINP + 196.1(VDIFF)

    It could only perform as a "comparator", HI-LO at certain VDIFF levels where the output will swing to either positive or negative rail. However, there will be voltage levels where the input is linear, where it follows the said equation. So to put it simply, the output will not settle to only VEE, VCC, and ZERO but at certain input levels, the output will transition between VEE to VCC until the output swings to either supply rail.

    Regards. 

  • Hi Claudio,

    Let me check on that. I'll get backto you when I found one.

    Regards.

  • Thanks for your kind response.

    Even though I'm OT in this thread, I wonder if I can get what I want ("ternary" comparator) with a simple circuit.
  • Hi Claudio,

    How about implementing a window comparator (see diagram below)?  The window comparator will give you a logic output representing the 3-states you are looking for.  From there, you can then use tristable logic devices or just discrete CMOS transistors to get your desired output voltages.  

    Please use caution when attempting to use opamps as comparators.  In your case, I suggest using a dedicated comparator.  

    I recommend taking a look at AN-849 for more explanation.  

    Let us know if that makes sense.

    Dave

  • Hi Daverowe,

     

    Thanks for your kind response.
    I do not know the tristable logic devices. Are they "special" device or can I use normal (bistable) device?
    In your picture, the output AND gate can it work with negative voltage?
    The Windows comparator have itself a ternary (tristable) output?
    Excuse for my basic question, but I do not know well the analogic electronics.
  • Allow me to clarify.  The original image I posted with the two comparators and the AND gate was to illustrate a window comparator.  It provides three logic outputs that represent the three states you are looking to detect.  That circuit does not output the +5V, 0V and -5V.  You would need to implement that separately.  There are many ways.

    Perhaps something like this diagram shown below might work for you.  The switches shown are ADG1636.  You'll need the resistors to be sufficiently large to limit the current.

  • @Daverowe:

    Thank you for the reply!
    I try to implement it now
  • @Daverowe:

    If my input signal is differential signal (the input voltage is from two point and not from a point and earth), how could I run the circuit?

    There is an IC that performs the function of two an-849?

  • Ok, now I am simulating the circuit, using the AD822 as differential  to single-signal converter.


    I have changed the value of the feedback resistor, so I have an amplification.

    The full circuit is attached.

    I use an AD633 to multiply two sinusoidal signals between them. If the beat is zero (if a spectral component of the first signal is also present in the second), I get an increase in the DC.

    To check if this increase exists, I block the DC with a capacitor and I put the difference into AD822.

    Simulation works very well.
    (The red signal is input differential signal, with scale of 50mV/Div - the blue signal is AD822 output with scale of 5V/Div)
    That's what I want to get.


    But ... can I make it or simulation is too simplified? Will it really work?