Alarm Sensor · PIR · Smart Home Security

How a PIR Motion Sensor Actually Works: Pyroelectric Sensing, Fresnel Lenses and False-Alarm Control

Published 2026-10-19 · 9 min read · By Shenan Yangguang engineering

A PIR is the workhorse of intrusion detection, yet most of its reliability is decided before a single line of firmware runs — in the pyroelectric element, the lens and the placement. Here is what actually determines whether it catches the right movement and ignores the wrong one.

Key takeaways

  • A PIR detects changing infrared (heat), not motion itself.
  • Dual pyroelectric elements wired in opposition reject steady heat.
  • The Fresnel lens — not the chip — sets coverage, range and blind spots.
  • False alarms are controlled by lens, firmware and placement together.
  • The factory should tune and measure detection, not buy it as a black box.

What a PIR sensor is, in one sentence

A PIR (passive infrared) motion sensor detects human movement by measuring changes in infrared radiation — heat — across the passive pyroelectric elements in its field of view, without emitting any signal of its own. It is passive because it listens for heat, rather than bouncing energy off a target. That single property shapes everything else: a PIR sees warm bodies moving against a cooler background, which is exactly what an intruder or a person walking a hallway presents, and exactly what a stationary object or a temperature swing does not.

The pyroelectric heart of the device

A pyroelectric sensor element is a crystal that generates a tiny voltage when its temperature changes, so when infrared from a moving warm body sweeps across it, the voltage rises and falls and that signal becomes motion. Two elements wired in opposition cancel steady heat and amplify change, which is what lets the sensor ignore a warm wall and notice a passing person. The dual-element, opposite-wiring design is the reason a PIR is resistant to gradual temperature drift. A slowly warming room heats both elements together and cancels; a person crossing the view heats them in sequence and produces the characteristic positive-then-negative pulse pair the firmware watches for.

Why the signal is a pulse pair, not a level

The firmware is not looking for a high voltage; it is looking for the alternating polarity that only a moving edge across the two elements produces. A static warm object, or slow ambient drift, drives both elements the same way and is rejected. This is the core trick that makes a PIR useful indoors, where everything is warm relative to an outdoor sensor — and it is why the detection logic starts at the physics, not at the radio.

The Fresnel lens that shapes the view

A Fresnel lens is the moulded plastic lens that sits in front of the pyroelectric element and divides the field of view into multiple detection zones, focusing infrared from each zone onto the sensor so that movement from one zone to the next produces a clear signal. The lens, not the element, decides coverage shape and range. A wide-angle lens covers a room from a corner; a curtain or long-range lens covers a hallway or a window row. Choosing the lens is a product decision, and getting it wrong is the most common cause of it misses movement or it triggers from the street.

How lens zones create a detection pattern

Each facet of the Fresnel lens projects a small zone; where a person walks across the boundary between zones, the signal pulses. The aggregate of those zones forms the sensor's detection pattern — the familiar fan or curtain drawn on the box. The factory tunes this pattern by lens selection and placement, and validates it on a test rig rather than estimating it. We cover the pairing of PIR with door contact sensors for intrusion in our article on door and window contact sensors with PIR detectors.

What causes false alarms, and how they are controlled

A false alarm in a PIR is any trigger that is not the human motion the device is meant to report — and the usual causes are rapid temperature changes, pets, air currents moving warm air, and direct sunlight or heaters entering the view. Controlling them is a combination of lens choice, firmware logic and placement, not a single switch. The brand that expects a sensitivity dial to solve all of them will be disappointed; the real work is in the design.

Pet immunity by design

Pet immunity is achieved by limiting the detection zones to human torso height and tuning sensitivity so a small animal crossing low in the view does not produce a signal above threshold. It is a trade-off: aggressive pet immunity can also reduce sensitivity to a child or a crouching intruder, so the setting must match the use case rather than be maximised by default. We set the pet-immunity profile per product and document it, instead of shipping one universal high sensitivity.

Thermal and environmental rejection

Sunlight through a window, a heater cycling on, or a draft carrying warm air can all mimic motion. Firmware rejects single pulses, requires a minimum pulse count and uses the dual-element polarity pattern to distinguish a real crossing from a thermal event; enclosure design keeps the sensor away from heat sources. These are the details a brand only notices after field complaints, which is why they are designed in from the prototype.

PIR in a Matter security product

In a Matter security line, the PIR is one endpoint whose Occupancy Sensing cluster reports occupancy state to controllers, while the local detection, lens and firmware remain the factory's own engineering. Matter standardises what the sensor reports; it does not dictate how the sensor senses. That separation is the point: a brand gets an interoperable occupancy report without handing the core sensing IP to a module vendor. Connectivity is integrated as a standard CSA-certified Matter connectivity module, a purchased component like any other, while the pyroelectric stage, lens and detection firmware are our own.

Power, range and the battery budget

A PIR is normally a battery device, and its power draw is dominated by how often it wakes to evaluate signal and how it radios results. Lens and sensitivity choices affect how much processing each wake needs, but the dominant cost is the radio — which is why many security PIRs use a low-power radio such as Matter over Thread rather than Wi-Fi. The radio choice and its effect on the power budget are covered in our article on Matter over Thread versus Wi-Fi for alarm sensors. The detection side and the radio side have to be designed together, because a thrifty sensor stage is wasted if the radio wakes too often.

Factory stance — we tune detection, not just assemble

Shenan Yangguang designs the schematic, builds the prototypes, writes the detection firmware, cooperates on certification and runs mass production — so the lens pattern, the dual-element wiring and the false-alarm logic are engineered as one product. A PIR bought as a black-box module and bolted to a board inherits someone else's detection pattern; building it ourselves means the coverage on the box is the coverage we measured, not a hope. We validate each lens and firmware combination on a test range before tooling locks, and we keep the measurement record as part of the product file.

Placement is half the product

Even a well-designed PIR fails if mounted wrong: aimed at a heater, placed where pets roam at torso height, or angled so sunlight sweeps the lens. We document recommended mounting height, avoidance of heat sources and the coverage pattern per lens, because the last step of does it work is the installer, not the factory. Good documentation turns a capable sensor into a reliable alarm, and we treat the installation guide as part of the deliverable rather than an afterthought.

Frequently asked

What does PIR stand for and how does it detect motion?

PIR stands for passive infrared. The sensor measures changes in infrared (heat) across pyroelectric elements as a warm body moves through its view; it emits nothing itself. Dual elements wired in opposition cancel steady heat and amplify change, which is what lets it ignore a warm wall and notice a person.

Why does lens choice matter more than the sensor chip?

The Fresnel lens divides the field of view into detection zones and focuses infrared onto the element, so it sets coverage shape, range and blind spots. The same element behind different lenses yields very different products; lens selection is the main lever for range and false-alarm performance.

What causes PIR false alarms?

The usual causes are rapid temperature changes, pets, warm air currents, and sunlight or heaters entering the view. They are controlled by lens choice, firmware pulse-counting and placement — not by a single sensitivity switch.

Can a PIR tell a person from a pet?

Partly. Pet immunity limits detection zones to human torso height and tunes threshold so a low animal stays below it, but it is a trade-off that can also reduce sensitivity to a child or crouching intruder. The setting should match the use case.

How does a PIR fit into a Matter product?

The PIR reports occupancy through the Occupancy Sensing cluster while the sensing, lens and firmware stay the factory's own. Matter standardises the report, not the physics; connectivity is a standard CSA-certified module we integrate.

Tuning a PIR for your coverage and false-alarm target?

Send your mounting height, room shape and pet-immunity requirement. We tune the lens and firmware on a test range and hand you measured coverage, not a guess.

Request a Quote