Amplifying Voltage Change about a non-zero mean

Discussion in 'General Electronics Chat' started by Jorn, Feb 21, 2011.

  1. Jorn

    Thread Starter New Member

    Feb 21, 2011

    I have a passive infrared sensor (PIR), typically used in motion detectors, connected to an opamp. The PIR signal fluctuates about 0.7V. The opamp output, v1, is 0.7V + the derivative of the PIR's signal. When there's no motion in front of the PIR, v1 = 0.7V. When there's motion, v1 is greater or less than 0.7V. How do I amplify (v1 - 0.7V)? In other words, I want to amplify any difference from the base voltage of 0.7V when nothing is moving.

    I've tried using another opamp with v1 in one terminal and something close to 0.7V that I generate with a voltage divider, but since I need to amplify the difference 100 fold, if the voltage divider is slightly off, the slight error gets magnified 100 times and the opamp hits a rail. I've also tried standard motion detector circuits that use two opamps, but the second opamp ends up producing the 2nd derivative of the PIR signal.

    Thanks in advance for your help.
  2. kkazem

    Active Member

    Jul 23, 2009
    Here is a circuit using a single-supply op-amp that should work great and the best part is that it uses the output of the PIR itself for the 0.7V reference (after a low-pass filter), so it will always track the PIR output as it changes slowly over time and temperature, but it will ignore the fast changes that take place when it is sensing a motion.

    Notice that I called out an LM358 (same as MC 1458), but any number of single supply op-amp types can be used. A really good one by On Semi is MC33072, which has superior characteristics to most similar single-supply op-amps.

    I've attached the schematic, with notes in a PDF file. If you have questions, feel free to ask me and I'll be glad to help. I'm not sure that your differentiator was a workable circuit. Try the one in my circuit. Although I didn't have time to do any SPICE runs or to breadboard it, you can do that. I highly recommend doing SPICE analysis first, which will give you great insight into your circuit operation. By changing values and looking at the results, you'll see the effect that changing various components has.

    Good luck,
    Kamran Kazem
    Jorn likes this.
  3. eblc1388

    Senior Member

    Nov 28, 2008
    Oh dear.

    A circuit with positive feedback? :confused:

    Jorn likes this.
  4. Jorn

    Thread Starter New Member

    Feb 21, 2011
    Thanks, eblc and kkazem. I'm a novice, so it may take me time to try your solutions, but I'll let you know how it turns out.
  5. sage.radachowsky


    May 11, 2010
    Yeah, kkazem's circuit is going to spin out of control... positive feedback... the output will rail immediately.

    The basic idea has merit -- to use the output of the sensor through a low-pass as the reference. But you would want to use that as one leg of a diff amp... not as it's used in this circuit.

    However, I think the simplest and most correct answer is to construct the original differentiator circuit correctly -- that is, set the "+" input to ground, so the output will center around ground.

    Here is the basic circuit and theory:

    However, a real-world implementation requires some roll-off to prevent oscillation. Take a look at page 3 of this classic app note from National Semi:

    Figure 6 has the circuit you want. You will need to adjust the R and C values for your application. For motion sensing, you will want to sense very slow changes, probably up to 10 Hz, yet you want to roll-off at rather low frequencies, probably 100 Hz. That's my guess for your application.

    (I am assuming that the op amp has + and - power inputs... with the - being less than ground.)
    Jorn likes this.
  6. Jorn

    Thread Starter New Member

    Feb 21, 2011
    Thanks, sage.radachowsky. The pdf was helpful.