Testing A PIR | PIR Motion Sensor - Adafruit Learning System
Maybe your like
- Overview
- How PIRs Work
- Connecting to a PIR
- Testing a PIR
- Using a PIR w/Arduino
- CircuitPython Code
- Example Projects
- Buy a PIR Motion Sensor
- Single page
- Feedback? Corrections?
- Text View
-
PIR (motion) sensor $9.95 Add to Cart
Testing a PIR
Now when the PIR detects motion, the output pin will go "high" to 3.3V and light up the LED!
Once you have the breadboard wired up, insert batteries and wait 30-60 seconds for the PIR to 'stabilize'. During that time the LED may blink a little. Wait until the LED is off and then move around in front of it, waving a hand, etc, to see the LED light up!
Retriggering There's a couple options you may have with your PIR. First up we'll explore the 'Retriggering' option. Once you have the LED blinking, look on the back of the PIR sensor and make sure that the jumper is placed in the L position as shown below.
Now set up the testing board again. You may notice that when connecting up the PIR sensor as above, the LED does not stay on when moving in front of it but actually turns on and off every second or so. That is called "non-retriggering".
Now change the jumper so that it is in the H position. If you set up the test, you will notice that now the LED does stay on the entire time that something is moving. That is called "retriggering".
(The graphs above are from the BISS0001 datasheet, they kinda suck)
For most applications, "retriggering" (jumper in H position as shown below) mode is a little nicer.
If you need to connect the sensor to something edge-triggered, you'll want to set it to "non-retriggering" (jumper in L position). Changing sensitivity The Adafruit PIR has a trimpot on the back for adjusting sensitivity. You can adjust this if your PIR is too sensitive or not sensitive enough - clockwise makes it more sensitive.
Changing Pulse Time and Timeout LengthThere are two 'timeouts' associated with the PIR sensor. One is the "Tx" timeout: how long the LED is lit after it detects movement - this is easy to adjust on Adafruit PIR's because there's a potentiometer. The second is the "Ti" timeout which is how long the LED is guaranteed to be off when there is no movement. This one is not easily changed but if you're handy with a soldering iron it is within reason.First, lets take a look at the BISS datasheet again
On Adafruit PIR sensors, there's a little trim potentiometer labeled TIME. This is a 1 Megaohm adjustable resistor which is added to a 10K series resistor. And C6 is 0.01uF so Tx = 24576 x (10K + Rtime) x 0.01uFIf the Rtime potentiometer is turned all the way down counter-clockwise (to 0 ohms) then
Tx = 24576 x (10K) x 0.01uF = 2.5 seconds (approx)If the Rtime potentiometer is turned all the way up clockwise to 1 Megaohm then
Tx = 24576 x (1010K) x 0.01uF = 250 seconds (approx)If RTime is in the middle, that'd be about 120 seconds (two minutes) so you can tweak it as necessary. For example if you want motion from someone to turn on a fan for a minimum of 1 minute, set the Rtime potentiometer to about 1/4 the way around. For older/other PIR sensors If you have a PIR sensor from somewhere else that does not have a potentiometer adjust, you can trace out the adjustment resistors this way:
Determining R10 and R9 isnt too tough. Unfortunately this PIR sensor is mislabeled (it looks like they swapped R9 R17). You can trace the pins by looking at the BISS001 datasheet and figuring out what pins they are - R10 connects to pin 3 and R9 connects to pin 7. the capacitors are a little tougher to determine, but you can 'reverse engineer' them from timing the sensor and solving!
For example:
Tx is = 24576 * R10 * C6 = ~1.2 seconds R10 = 4.7K and C6 = 10nF
Likewise,
Ti = 24 * R9 * C7 = ~1.2 seconds R9 = 470K and C7 = 0.1uF
You can change the timing by swapping different resistors or capacitors. For a nice tutorial on this, see Keith's PIR hacking page.
Page last edited June 27, 2012
Text editor powered by tinymce.
Connecting to a PIR Using a PIR w/Arduino Related Guides Your browser does not support the video tag. This links to the guide Light of Your Life Wedding Bouquet. Light of Your Life Wedding Bouquet By Erin St Blaine beginner Your browser does not support the video tag. This links to the guide Fog Machine with Motion Sensor and Adafruit IO. Fog Machine with Motion Sensor and Adafruit IO By Erin St Blaine intermediate Calibrating Sensors By Bill Earl beginner Adafruit VL53L1X Time of Flight Distance Sensor By Kattni Rembor beginner IR Breakbeam Sensors By lady ada intermediate Ultrasonic Ruler By Ruiz Brothers beginner Your browser does not support the video tag. This links to the guide Haunted Air Blaster. Haunted Air Blaster By John Park intermediate Adafruit VCNL4020 Proximity and Light Sensor By Liz Clark beginner Your browser does not support the video tag. This links to the guide Raspberry Pi Video Synth with Blinka and Processing. Raspberry Pi Video Synth with Blinka and Processing By Liz Clark beginner Adafruit Proximity Trinkey By Kattni Rembor beginner Adafruit APDS9960 breakout By Justin Cooper beginner LPC824 NeoPixel IR Distance Sensor By Kevin Townsend beginner Your browser does not support the video tag. This links to the guide Track a Turtle with WipperSnapper. Track a Turtle with WipperSnapper By Isaac Wellish beginner HalloWing Jump Scare Trap By John Park beginner Sitcom SFX Door Trigger By James DeVito intermediateCreate Wishlist
× Title Description Close Search SearchCategories
Tag » Arduino Pir Motion Sensor Not Working
-
Troubleshooting PIR Sensor And Sensitivity Adjustment
-
PIR Sensor Not Working - Programming Questions - Arduino Forum
-
PIR Motion Sensor Code Not Working Well - Arduino Forum
-
HC-SR501 PIR Motion Sensor Does NOT Work As Expected! How To ...
-
How To Fix PIR Motion Detector Sensor - YouTube
-
Testing Motion Pir Sensor Is Working Or Not - YouTube
-
Arduino - PIR Sensor Doesn't Work Properly - Stack Overflow
-
Arduino With PIR Motion Sensor - Random Nerd Tutorials
-
PIR Motion Sensor With Arduino In Tinkercad - Instructables
-
Pir-sensor · GitHub Topics
-
How HC-SR501 PIR Sensor Works & How To Interface It With Arduino
-
PIR Motion Sensor Connected To Arduino Sometimes Does Not Detect ...
-
Problem With PIR Motion Sensor - RNT Lab
-
Motion Sensor | Arduino Tutorial
Calibrating Sensors By
Adafruit VL53L1X Time of Flight Distance Sensor By
IR Breakbeam Sensors By
Ultrasonic Ruler By
Adafruit VCNL4020 Proximity and Light Sensor By
Adafruit Proximity Trinkey By
Adafruit APDS9960 breakout By
HalloWing Jump Scare Trap By
Sitcom SFX Door Trigger By