← back to catalog
// motion

HC-SR501 (PIR)

Passive infrared motion detector

€2.80
avg eur
no image
Digital
Pins
3
Specs
4
Libraries
1
Protocols
1
// wiring → esp32 devkit v1
3V3
EN
GPIO36 VP
GPIO39 VN
GPIO34
GPIO35
GPIO32
GPIO33
GPIO25
GPIO26
GPIO27
GPIO14
GPIO12
GND
GND
OUT
GPIO13
ESP32
WROOM-32
devkit v1
USB
VIN 5V
VCC
GND
GPIO23
GPIO22 SCL
GPIO1 TX0
GPIO3 RX0
GPIO21 SDA
GPIO19 MISO
GPIO18 SCK
GPIO5 SS
GPIO17 TX2
GPIO16 RX2
GPIO4
GPIO2
GPIO15
sensor pin (left)
sensor pin (right)
unused
// pinout → esp32
Sensor Pin ESP32 Connection
VCC 5V (VIN)
OUT GPIO 13
GND GND
// technical specs
Range 3–7 m
Angle ~110°
Delay adjustable 0.3s–5min
Voltage 5–20V (has reg)
// github libraries
// notes & warnings
OUT is 3.3V — safe. Two trim pots: sensitivity + delay. Set jumper to repeatable mode for retriggering.
// related sensors · motion
Submitted by caio.ricciuti@outlook.com · Apr 26, 2026