Electronics Design AU
Sensors

How Do PIR Motion Sensors Work, and How Do You Design Them Into a Product?

Last updated 9 July 2026 · 8 min read

Direct Answer

A PIR (passive infrared) motion sensor detects movement by sensing changes in incident infrared radiation, not by emitting anything itself. A pyroelectric crystal generates a small transient voltage whenever the infrared flux falling on it changes; a multi-faceted Fresnel lens in front of the sensor splits the field of view into several narrow detection zones, so a warm body moving across the lens sweeps in and out of those zones and produces an alternating signal that a stationary heat source (a wall, a lamp) does not. Most designs use a dual- or quad-element sensor wired in a differential configuration specifically to cancel slow common-mode drift (ambient temperature change, sunlight heating the case) while still responding to the fast differential signal a moving body creates. The classic implementation pairs a pyroelectric element with the BISS0001 (or an equivalent) analog controller IC, which handles amplification, comparator thresholding, and a retriggerable or non-retriggerable output timer — producing a simple digital HIGH/LOW motion output an MCU can read directly, with no signal processing required on the firmware side.

Detailed Explanation

PIR sensors are one of the most common and lowest-cost motion-sensing components in embedded products — lighting controllers, security systems, occupancy-triggered devices — yet the site has no dedicated coverage of how they actually work or what catches designers out. This page covers the sensing principle, the standard analog front-end architecture, and the false-trigger and range limitations that matter for a real product design.

How a PIR Sensor Detects Motion

"Passive" means the sensor does not emit any energy of its own — unlike an ultrasonic or Time-of-Flight distance sensor, which actively emits a signal and measures its return, a PIR sensor only observes the infrared radiation already present in its environment. Every object above absolute zero radiates infrared energy; a human body radiates strongly in the 8–14 µm band due to its surface temperature.

The sensing element is a pyroelectric crystal (commonly lithium tantalate or a PZT-based ceramic) that generates a small transient voltage across its faces whenever the infrared flux incident on it changes — it does not respond to a constant, unchanging infrared level at all, only to a change in that level. A single pyroelectric element facing an unobstructed scene would only fire once, briefly, whenever anything in view changed temperature or moved into a completely different position — not useful on its own for continuous motion detection across a wide field of view.

The Fresnel Lens Creates Multiple Detection Zones

The multi-faceted plastic lens in front of a PIR sensor is a Fresnel lens, and its role is not simply to focus light — it splits the sensor's field of view into several narrow, alternating detection zones (visible as the segmented dome or flat-faceted window on almost every PIR module). As a warm body moves across the sensor's field of view, it passes in and out of these zones in sequence, so the pyroelectric element sees a repeating rise-and-fall pattern rather than a single step change. This alternating signal is what a moving body produces that a stationary heat source does not, and it is the basis of the differential detection described below. The lens's facet pattern and focal geometry set the sensor's detection range and angular coverage — a lens designed for a narrow, long-range corridor pattern and one designed for a wide-angle ceiling-mounted pattern are not interchangeable, and swapping one part's lens for another changes the coverage pattern.

Dual-Element Differential Sensing

Nearly all PIR sensors used in products use two (or four) pyroelectric elements wired in series opposition, rather than a single element. This differential arrangement exists specifically to reject common-mode signals: slow, uniform temperature drift (ambient temperature change, the sensor's own case heating in sunlight) affects both elements equally and cancels out, while a body moving across the Fresnel lens's zones excites the two elements at different times, producing a genuine differential signal that survives the cancellation. This is the same common-mode-rejection principle used in signal conditioning for other sensor types, applied to a thermal sensing element instead of a resistive or capacitive one.

The Analog Front End: Amplification, Threshold, and Output Timing

The pyroelectric element's raw output is a few millivolts at most, far too small and noisy to drive a digital input directly. The standard implementation — used in the HC-SR501 and most similar low-cost modules — pairs the sensor with the BISS0001 (or a functionally equivalent controller IC from another manufacturer), which integrates:

  • A high-gain amplifier stage for the raw pyroelectric signal.
  • A comparator that thresholds the amplified signal against a reference, converting an analog blip into a clean digital edge.
  • A retriggerable or non-retriggerable output one-shot timer, set by an external RC network (commonly exposed as a potentiometer on hobbyist modules), that holds the digital output active for a configurable period after a detection so the output doesn't chatter on and off during continuous motion.

Because this entire chain is handled in analog hardware, the digital output pin an MCU reads is a simple HIGH/LOW motion flag — no signal processing, filtering, or ADC sampling is required in firmware, which is a major reason PIR modules are popular in simple embedded designs.

Design Considerations

  • Warm-up time after power-on. The pyroelectric element and analog front end need a settling period after power is first applied, during which the output can be unreliable or falsely triggered — commonly in the tens-of-seconds range on typical low-cost modules, though this varies by part and should be confirmed against the specific module's own documentation. Firmware must ignore the sensor for this window after every power-up, which matters for any design that power-gates the sensor between measurements to save energy.
  • Detection depends on a temperature differential, not just motion. A PIR sensor detects the difference between a moving object's apparent temperature and the background it moves across — a person whose skin temperature is close to a hot ambient background (a warm room, direct summer sun on the sensor) produces a weaker differential signal and can be detected at a shorter range than the same sensor achieves in a cooler environment. This is a physical limitation of the sensing principle, not a defect, and should be accounted for when specifying detection range for an outdoor or high-ambient-temperature application.
  • Retriggerable vs. non-retriggerable output mode matters for the use case. In non-retriggerable mode, the output timer starts on the first detection and holds for a fixed period regardless of continued motion; in retriggerable mode, continued motion keeps extending the timer, and the output only goes low after motion stops for the full timeout period. Lighting-control applications almost always want retriggerable mode (so the light doesn't switch off mid-occupancy); simple event-counting applications may want non-retriggerable mode instead.
  • Low idle current suits battery and wake-on-motion designs. Because the analog front end does all the signal processing, an MCU can leave a PIR sensor's digital output wired to a GPIO configured as an interrupt source and remain in a low-power sleep state — such as an ESP32 deep-sleep mode — until motion actually occurs, waking only on the sensor's output edge rather than polling continuously.
  • Fresnel lens selection sets range and coverage pattern, and is not universally swappable. A lens optimised for a wide-angle, short-range ceiling mount and one optimised for a narrow, long-range corridor produce very different coverage patterns from the same underlying pyroelectric element — confirm the lens supplied with a module or part matches the product's intended mounting geometry and range rather than assuming all PIR lenses are interchangeable.

Common Mistakes

  • Treating a false-trigger-prone environment as a component defect. HVAC vents, direct sunlight through a window, curtains moving in a draft, and even car headlights sweeping across a window can all produce genuine PIR false triggers because they represent a real, rapid infrared flux change — no amount of part selection eliminates this; the fix is sensor placement, lens/zone selection, and requiring multiple trigger events in firmware before acting on a detection.
  • Ignoring the warm-up period in a power-gated design. A design that switches the PIR sensor's power on only when needed (to save energy) and immediately trusts its output on the very first read will see spurious detections during the settling window — always add a firmware-enforced ignore period after every power-up.
  • Assuming PIR provides presence detection. Because the sensor only responds to change, a stationary occupant eventually produces no signal and the sensor behaves as if the room is empty — a design that actually needs to know someone is present (not just that someone recently moved) needs a different or additional sensing technology, such as mmWave radar or a Time-of-Flight sensor, or a deliberate re-trigger/heartbeat mechanism layered on top of the PIR event.
  • Confusing PIR with capacitive proximity or touch sensing. PIR senses infrared radiation changes at a distance and works only for actual motion of a thermal source; it is unrelated in principle, range, and failure mode to capacitive touch sensing, which senses a nearby dielectric object through electric-field coupling at contact or near-contact range.

For products that combine a PIR motion sensor with other sensing modalities, power management, and firmware, Zeus Design's engineering team provides full sensor-to-firmware product design support.

Frequently Asked Questions

Can a PIR sensor detect a person who is standing still?
Not reliably. A PIR sensor only produces a signal when the infrared flux across its Fresnel lens zones changes, which requires relative motion between the warm body and the sensor's field of view. A person standing completely still eventually stops producing a differential signal and the sensor's output returns to its idle state, even though the person is still present — this is why PIR-based lighting and security systems appear to 'time out' on a stationary occupant. Applications that need true presence detection (not just motion) typically combine a PIR sensor with a mmWave radar or a scheduled re-trigger from another sensor, rather than relying on PIR alone.
Why does my PIR sensor false-trigger when the heating or air conditioning turns on?
PIR sensors respond to any rapid change in infrared flux across their detection zones, and a sudden burst of warm or cold air moving across the sensor's field of view — from an HVAC vent, a heater, or even a curtain moved by a draft — can produce a differential signal that looks electrically identical to a person walking past. This is a fundamental limitation of the sensing principle, not a fault in a specific part. Mitigations include physically aiming the sensor away from vents and windows, fitting a lens with a narrower or more targeted zone pattern, and in software, requiring a minimum number of trigger events within a time window before acting on a detection rather than responding to the first pulse.
Why does a PIR sensor need a warm-up time after power-on?
The pyroelectric element and its analog front end need time to reach thermal and electrical equilibrium after power is first applied — many common modules (including HC-SR501-class boards built around the BISS0001 controller) specify a stabilisation period, commonly in the tens-of-seconds range per the module's own documentation, during which the output can be erratic or falsely triggered. Firmware should ignore the sensor's output for a fixed warm-up window after every power-on or wake event rather than treating the first reading as valid, and this warm-up requirement should be accounted for in any duty-cycled or intermittently-powered design where the sensor is switched off between measurements to save power.

References

Related Questions

Related Forum Discussions