Pyroelectric infrared motion sensor can detect the infrared signals from the person or animals which are moving, and can output the switching signals. So it can be applied to a variety of occasions which need to detect the movement of the human body. Conventional pyroelectric infrared sensors require body pyroelectric infrared detector, professional chip, complex peripheral circuit, so the volume is slightly big, circuit is complex, and reliability is slightly lower. Now we launch this new pyroelectric infrared motion sensor, especially designed for Arduino. An integrated digital body pyroelectric infrared sensor is used, with small size, high reliability, low power consumption, simple peripheral circuit.



Board Overview



Overview of the Detector

The pyroelectric infrared motion sensor integrates a digital integrated body pyroelectric infrared detector whose model is AM412. This detector is a digital intelligent PIR sensor. It interfaces directly with up to two conventional PIR sensors via a high impedance differential input. The PIR signal is converted to a 15 bit digital value on chip. A LED indicates whenever the PIR signal is above the selected threshold. All signal processing is performed digitally. PIR_sequential_en.jpg

Output Characteristic

When the pyroelectric infrared motion sensor detects the movement of the life body within the detection range, the output pin will output high level(3V) and the output led is ON; Without an infrared Pyroelectric signal, the output pin will output low level(0V) and the output led is OFF. Pay attention: Once the IR signal disappears, the output pin will output low level delay roughly 2.3~3 seconds. So we can quickly establish a body motion detection application according to this feature. Note:When the sensor just on power, there will be unstable for a short time. The output level is jittered.


Connection Diagram


Sample Code

Just download the sample code. Move your body to play with the tiny motion sensor.

// #
// # Editor     : Youyou from DFRobot
// # Date       : 04.06.2014
// # E-Mail :

// # Product name: PIR (Motion) Sensor
// # Product SKU : SEN0171
// # Version     : 1.0

// # Description:
// # The sketch for using the PIR Motion sensor with Arduino/Raspberry Pi controller to achieve the human detection feature.

// # Hardware Connection:
// #        PIR Sensor    -> Digital pin 2
// #        Indicator LED -> Digital pin 13
// #

byte sensorPin = 2;
byte indicator = 13;

void setup()

void loop()
  byte state = digitalRead(sensorPin);
  if(state == 1)Serial.println("Somebody is in this area!");
  else if(state == 0)Serial.println("No one!");

Expected Results

When the sensor detects the living movement body within detection range, the output pin will output high voltage of 3V, while the output indicator is lighted.Otherwise,after 2~3s,the output pin will output high voltage of 0V, while the output indicator is extinguished.

Note: When the sensor just on electricity, there will be unstable for a short time, the output terminal will be level shake!


Q&A Some general Arduino Problems/FAQ/Tips
A For any questions, advice or cool ideas to share, please visit the DFRobot Forum.

More Documents

DFshopping_car1.png Get Digital PIR (Motion) Sensor For Arduino from DFRobot Store or DFRobot Distributor.

Turn to the Top