LoopStringLoopString
All Posts
Motion & presence sensors compared, reed/PIR to mmWave radar
Buyer's Guides6 min read1,220 words

Door, Contact & Motion Sensors: From Reed Switches to mmWave Radar — The Complete Quality-Tier Buyer's Guide

By LoopString Team


Quick picks by tier. Hobby → a reed magnetic contact (door) + a PIR module like the HC-SR501 (motion). Maker/Prosumer → a quality dual-tech PIR or a ToF presence sensor (VL53L0X). Commercial → an mmWave radar presence sensor (LD2410 and similar) for true occupancy, plus an IP67 sealed contact for doors. Hardened industrial / audited → a coded-magnet safety interlock (Pilz, Schmersal) or industrial occupancy sensor. Why each wins is below — but if you just need a name, start there.

The thing that actually bites you: motion is not presence

The defining mistake in occupancy sensing is treating a PIR — a motion detector — as a presence detector. A passive-infrared sensor fires on the change in heat across its field, so a person sitting still at a desk vanishes from it within seconds, lights drop, and everyone learns to wave at the ceiling. Worse, PIR false-triggers on the things that also move heat: an HVAC register kicking on, a sunbeam tracking across the floor, a pet. If your question is "is someone in the room?", a PIR answers a different question ("did something warm just move?") and gets it wrong both ways.

The modern fix is cheap now: mmWave (24/60 GHz) radar detects micro-movements — even breathing — so it holds a stationary occupant, sees through thin plastic enclosures, and ignores air currents. Modules cost a few dollars. For short-range "is the spot occupied", time-of-flight (ToF) does it optically.

Doors have their own trap: a hobby reed switch is easy to defeat with a stray magnet, sticks over time, and — critically — isn't sealed. In a cold room or wash-down area, condensation and spray kill an unsealed contact, so cold-chain door-open logging needs an IP67 sealed contact. And a guard door on a machine isn't a monitoring problem at all — it's a safety problem that demands a coded-magnet safety switch wired into a safety relay, not a reed on a GPIO.

So the real question isn't "did something move?" — it's "do I need motion, presence, or a tamper-proof safety contact — and will it survive the environment it lives in?"

The decision axes

  • Motion vs presence — PIR/microwave motion (detects change) vs mmWave/ToF presence (detects a stationary person). The defining choice.
  • Door state vs occupancy — a contact (open/closed) is a different job from room occupancy; some deployments need both.
  • Environment & sealing — dry office vs cold-store condensation, wash-down spray, dust; drives IP rating and contact type.
  • Tamper resistance & safety rating — ordinary reed (defeatable) vs coded-magnet safety switch for machine guarding (PLe / SIL).
  • False-trigger immunity — PIR trips on HVAC drafts, sun, and pets; dual-tech (PIR + microwave) and radar are far more selective.
  • Range & field of view — PIR coverage cones, ToF short-range spot, radar zone/distance gating.
  • Interface — GPIO digital → I²C/UART module → dry-contact relay → safety relay / industrial bus.

Tier

Device

Type

Detects

Stationary presence?

False-trigger immunity

Sealing / rating

Interface

Price (USD)

Best for

Hobby

Reed contact + PIR (HC-SR501)

Magnetic reed / passive IR

Door open/close; gross motion

No (PIR)

Low (drafts/sun/pets)

Unsealed

GPIO

$1–5

Hobby alarm, closet light, door log

Prosumer

Dual-tech PIR / ToF (VL53L0X)

PIR+microwave / time-of-flight

Motion / spot presence

Spot only (ToF)

Better (dual-tech)

Indoor

GPIO / I²C

$5–30

Reliable motion/occupancy, lighting

Commercial

mmWave radar presence + IP67 contact

24/60 GHz radar / sealed contact

Stationary occupancy; door

Yes

High

IP67 (contact)

UART / GPIO

$5–150

True occupancy, cold-store door

Industrial

Coded-magnet safety interlock (Pilz, Schmersal)

Coded-magnet safety switch

Guard-door state

n/a

n/a (tamper-proof)

Sealed, rated

Safety relay / PLC

$100–500+

Machine guarding, audited safety

Walking up the ladder

Hobby — reed contact + PIR module (HC-SR501) ($1–5). A magnetic reed tells you a door or window is open; a PIR flags gross motion for a hobby alarm or auto-light. Cheap, instant, and everywhere — just remember the PIR can't hold a still person and the reed isn't sealed or tamper-proof. Stop here if it's a hobby project, a closet light, or a low-stakes "did the door open" log.

Maker/Prosumer — dual-tech PIR or ToF presence (VL53L0X) ($5–30). A dual-technology sensor (PIR + microwave, both must agree) slashes false trips from drafts and sun; a ToF sensor gives reliable short-range "is this spot occupied" and even rough distance. Stop here if you want dependable motion/occupancy for lighting or a small space without industrial demands.

Commercial — mmWave radar presence + IP67 sealed contact ($5–150). mmWave radar (LD2410, Seeed 24 GHz, 60 GHz parts) is the upgrade that actually answers "is someone in the room" — it holds stationary people, reports zones/distance, and hides behind plastic. Pair it with an IP67 magnetic or inductive proximity contact for doors that face condensation or wash-down. Stop here if you need true occupancy, or cold-store/wash-down door logging that survives the environment.

Hardened industrial — coded-magnet safety interlock or industrial occupancy ($100–500+). Machine-guard doors use coded-magnet safety switches (Pilz, Schmersal, Euchner) wired into a safety relay or safety PLC to a rated category (PLe / SIL), tamper-resistant by design; industrial occupancy/presence sensors bring sealed housings and long life. You need this tier if the contact protects a person from a machine or must satisfy a safety auditor — a hobby reed is never acceptable there.

Interface & wiring notes (per tier)

  • Reed / contact (GPIO): dry contact into a GPIO with a pull-up; debounce in software. For security, a supervised (end-of-line resistor) loop detects a cut/shorted wire — a plain reed doesn't.
  • PIR (GPIO): give it its warm-up/settle time, set sensitivity and hold-time pots deliberately, and keep it away from HVAC vents, windows, and heat sources to cut false trips.
  • mmWave radar (UART / GPIO): configure detection distance and sensitivity zones; mount per the antenna pattern and keep large moving metal (fans) out of the zone. Reads over UART or as a simple presence GPIO.
  • Safety interlock (safety relay): this does not go to a Pi GPIO as the safety function — it wires into a rated safety relay/PLC. The Pi can read a monitoring contact for logging, but the safety circuit stands on its own.

A note on the safety boundary: monitoring and safety are different jobs. LoopString and a Pi are perfect for logging door-open events, occupancy, and cold-chain compliance — but a machine-guarding safety function must live in a rated safety circuit (safety relay / safety PLC), not in application software on a general-purpose computer. Use the Pi to record it, never to be it.

How LoopString reads every tier — in one dashboard

Here's the part that makes the whole ladder moot from a software standpoint: a Raspberry Pi running LoopString's Node-RED templates reads a $1 reed switch and a commercial mmWave occupancy sensor into the exact same dashboard — same live state, same door-open and occupancy alerts, same cold-chain compliance log. You can prototype with a PIR and move up to radar presence (or add an IP67 contact for the freezer door) without touching your dashboards or alert rules. Pick the tier your job actually needs using the table above, wire it to a Pi, and see every open and occupancy event at app.loopstring.io.

Useful next reads: the Raspberry Pi automation guide, the Raspberry Pi industrial monitoring guide, and the MQTT sensor dashboard overview.

Frequently asked questions

Because a PIR detects motion, not presence — it fires on the change in heat across its field, so a stationary person disappears from it within seconds. For 'is someone in the room' use an mmWave radar presence sensor, which detects micro-movements and even breathing and holds a still occupant, or a ToF sensor for short-range spot occupancy.