What is PIR sensor
A passive infrared sensor (PIR) is an electronic sensor that measures infrared radiation from objects in its field of view. Often used in PIR-based motion detectors. The PIR device is used in security alarms and automatic lighting applications
PIRs are made of a pyroelectric sensor which has round metal can with a rectangular crystal inside the middle About 7 meters of 120-degree cone can be sensed.
Technical Details
Dimensions:
- Length: 24.03mm/0.94in
- Width: 32.34mm/1.27in
- Screw hole distance: 28mm
- Screw hole diameter: 2mm
- Height (with lens): 24.66mm/0.97in
- Weight: 5.87g/0.2oz
How does it work
All objects with a temperature above Absolute Zero (o Kelvin / -273.15 °C) emit heat energy in the form of infrared radiation, including human bodies. A thing emits more radiation the hotter it is. PIR sensor is specially designed to detect different levels of infrared radiation. It basically consists of two main parts: A Pyroelectric Sensor and A special lens called Fresnel lens which focuses the infrared signals on to the pyroelectric sensor PIR sensor RE200B Datasheet
When the sensor is idle, i.e. there is no movement around the sensor; both slots detect the same amount of infrared radiation, resulting in a zero output signal. However, a warm body, such as a person or animal, first blocks one side of the PIR sensor, which results in a positive differential change between the two halves as the warm body passes by. The sensor sets its output pin high in response to the corresponding pulse of signals.
there is a small IC in this sensor which is called Micro Power PIR Motion Detector IC (BISS0001)
This chip takes the analog output of the pyroelectric sensor and converts it to a digital signal
pin configuration of the PIR sensor
The HC-SR501 PIR sensor module has three pins
- Ground pin and VCC for powering the module -4.V to 12V (+5V recommended)
- output pin which gives high logic level when motion is detected - Digital pulse output high (3.3V) when motion detected
It has two presets
- One for controlling the sensitivity
- the second one is for controlling the time the output signal holds high when an object is detected
there are three more pins in this module
this HC-SR501 sensor module has two trigger modes first one is single trigger mode and the second one is repeating trigger mode so these three pins use to change the trigger modes
Single trigger mode-
In this mode, the output will hold HIGH for the period set by the TIME preset adjustment
As long as it detects movement while in this mode, the sensor will continue to generate a HIGH signal
Testing PIR Sensor
first of all, it's better to make sure that your PIR sensor properly works or is not.
Therefore you should connect the PIR sensor with a LED shown as below
if the sensor works properly LED bulb will on when motion is detected by the sensor
Motion sensitive security light
you can make a simple motion sensor light using the HC-SR501 PIR sensor without Arduino or any microcontroller