Parallax PIR sensor stuck in loop

Discussion in 'The Projects Forum' started by jockcoupzero, Dec 20, 2009.

  1. jockcoupzero

    Thread Starter New Member

    Dec 20, 2009
    Hi everyone,

    Hope someone can help with this. I have a parallax PIR sensor powered by a six volt power supply. I allow the sensor to acclimate to the room for about two minutes. The trigger voltage is running through pin 1 and 2 of optocoupler (the controling side) which works a 555 timer circuit on the other side and a motor. The 555 side of the circuit works great. The PIR side is acting odd.
    Every time the device triggers it gets stuck of a loop of triggering then two seconds off then triggering again. It can sit idle indefinately but after it triggers once it becomes stuck in a loop of re-triggering.
    If i hook the trigger output to a LED it works as designed - the PIR triggers and then goes back to the low state until motion is detected again. However if i hook it up to the optocoupler it goes right back into a loop.
    My thought is that when the device triggers it causes the voltage to the PIR to drop below 3.5 volts (which it the min. required to run the sensor) and then it triggers automatically when as it tries to learn the room agian.
    Also i should mention it i turn it on cold while connected to the optocoupler it gets stuck in a loop as well.
    I am not sure if I should use a higher power source like 9volts and a zener diode voltage regulator set up or if there is something i am completely missing...


    J. S.
  2. jockcoupzero

    Thread Starter New Member

    Dec 20, 2009
    I decided to attach a diagram of the circuit
  3. BMorse

    Senior Member

    Sep 26, 2009
    for one, the power to the PIR is supposed to be 3.3 to 5 volts, you are powering it with 6 volts, which may not be good for the sensor since max voltage is 5. and since you have it connected to a 6 volt supply, the output is going to be around the same voltage when the active high output turns on, so you are feeding 5 to 6 volts directly into the LED in the optocoupler, I would not be surprised if you already damaged the optocoupler. You will need a 470 or 330 ohm resistor in series with the output to the optocoupler.

    also add a Pull down resistor to the output of the PIR, try 10K, if using it in active high mode, or use a pullup if using active low mode (from your circuit I am assuming active high mode.).....

    Are you powering the motor off of the same supply as the device? If you are, then why use the optocoupler? These are used to isolate 2 circuits from each other.
  4. jockcoupzero

    Thread Starter New Member

    Dec 20, 2009
    Thanks for the reply, I will try your suggestions but first some clarifications.

    The output voltage I read going to the optocoupler is about 3.2 volts. The optocoupler is being used to isolate two circuits on two different power supplies. The optocoupler is still functional - if i test the it with a battery everything functions as designed. One thing I failed to mention is that I have a toggle switch with an integrated LED connected that is causes a voltage drop so that the power input to the PIR is about 4.7 volts when meassured.

    The PIR circuit does work when not attached to the optocoupler just fine. The circuit attached to the other side of the optocoupler works also when tested alone.

    The problem is when I attach the output of the PIR to the optocoupler the device triggers (which triggers the circuit on the other side) but then it falls into a loop of constant retriggering every two sesonds. If I instead attach the PIR output to an LED the system stablizes and returns to a normal state where it operates as designed.
  5. Bernard

    AAC Fanatic!

    Aug 7, 2008
    I had the same problem a few months ago using a KC7783 PIR driving into 9.1K ,a 555, transistor & 10W bulb. Worked fine on bench supply, but when PO used his 12V batterey circuit oscillated. Added an outboard 5V zenor regulator for PIR, problem solved. PIR does not like shifts in supply V. What are the specs for optocoupler?
  6. jockcoupzero

    Thread Starter New Member

    Dec 20, 2009
  7. Otaku

    Active Member

    Nov 19, 2008
    The Parallax PIR has two operating modes, I think. One mode keeps the output high (~3.3VDC) as long as it sees a moving heat source. The other mode "flickers" the output 2-3 times after registering a heat source. The modes can be changed with the on-board jumper. I have also seen variability in the behavior of the PIR unless using a 5VDC supply. A 7805 will solve that problem.