Passive IR (PIR) sensor modules provide motion detection and control to smart home and building systems.

John Blyler

March 9, 2021

4 Min Read
AdobeStock_329694694_1540-800.jpeg
Adobe Stock

Detecting and measuring movement is an essential element for many industrial and commercial IoT applications – from lighting and security to assisted driving.  Motion detection systems consist of a sensor, signal conditioning electronics, and control circuitry to perform some action related to the detection.

There are a variety of motion sensors, but this article will focus on one of the most common types, i.e., passive infrared (PIR) sensors. These sensors are used to detect IR radiation, for example from humans and other warm-blooded mammals. PIR sensors are used commonly in occupancy determination, alarms, and security systems.

IR Motion Sensing

PIR sensors rely on infrared radiation (IR) to detect the presence of heat-emitting beings as opposed to inanimate objects (e.g., as with ultrasonic sensors). Typically, a pyroelectric sensor measures the average temperature of the surrounding environment, but this measurement is not particularly useful when trying to track motion.

Amazon-PIR-Modules.jpg

HC-SR501 PIR motion detection sensors.

Instead, PIR motion sensors consist of pyroelectric sensors that have been split into two halves, which then serve as a type of differential signal system. The two halves measure the environment and are connected such that they cancel each other out when balanced. When an IR source like a human body passes the sensor, there is an imbalance between the two sensors, and therefore the output of the sensor changes. If one half sees more or less IR radiation than the other, the output will swing high or low.

Related:How to Build a Better In-Vehicle Connectivity System

A PIR sensor is typically connected to – or part of – a motion detection module that determines when motion has occurred. Additionally, a microcontroller might be included in the design to enable software customization to allow additional features, such as the capability to provide custom LED sequences, to ignore incoming signals under certain conditions, and to further process the data.

Build a Better Motion Control System

Detecting motion is one thing; using it to control a system or industrial process is another. A microprocessor platform is often needed to achieve the control part of the motion equation, such as operating fans, lights, or other electronics.

To be clear: a microprocessor or microcontroller is not needed to detect motion as the sensor could connect directly to a PIR module. However, connecting a module to the processor or controller of your choice has a number of advantages including customizing output actions, removing incoming signals under certain conditions, and providing a basis for further data processing.

Related:How to Build a Better Sensor Characterization System

PIR-Block-Diagram_jb_org_250.png

PIR Motion Sensor Platform

Including a processor or controller in the product design greatly enhances the flexibility of the systems via software. A simple configuration would have a PIR sensor module input to a microprocessor or microcontroller whose output controls “something,” say the turning on and off of an LED.  For example, the LED could flash with every PIR detection or every time someone walks by. Naturally, a more practical example would have the processor or controller (or even the PIR itself) turn on lights when someone enters a darkened room.

The software for such an operation is simple. When the PIR output goes high, indicating a detection, then the LED output goes high to run on the light. Making the PIR output a variable enables setting the detection to a certain level, e.g., waiting until X number of people walk by before turning on the LED.

From the previous example, it’s possible to create an occupancy sensor based on a processor or controller-based PIR system. This determination can be used to increase illumination in certain areas and turn-off lights in areas with no occupants thus saving on energy costs.

Another way to count occupancy is with a computer vision, based upon CMOS imaging sensors, a low-power microprocessor, and algorithmic technologies. In these scenarios, lights can be automatically turned on, brighten, or dimmed depending upon the number of people in a configurable area. But that’s a topic for a future article.

John Blyler is a Design News senior editor, covering the electronics and advanced manufacturing spaces. With a BS in Engineering Physics and an MS in Electrical Engineering, he has years of hardware-software-network systems experience as an editor and engineer within the advanced manufacturing, IoT and semiconductor industries. John has co-authored books related to system engineering and electronics for IEEE, Wiley, and Elsevier.

About the Author(s)

John Blyler

John Blyler is a former Design News senior editor, covering the electronics and advanced manufacturing spaces. With a BS in Engineering Physics and an MS in Electrical Engineering, he has years of hardware-software-network systems experience as an engineer and editor within the advanced manufacturing, IoT and semiconductor industries. John has co-authored books related to RF design, system engineering and electronics for IEEE, Wiley, and Elsevier. John currently serves as a standard’s editor for Accellera-IEEE. He has been an affiliate professor at Portland State Univ and a lecturer at UC-Irvine.

Sign up for the Design News Daily newsletter.

You May Also Like