Chain PIR is a pyroelectric passive infrared motion sensing node in the M5Stack Chain series. It integrates a pyroelectric infrared sensor and a programmable RGB LED. It is suitable for human activity detection, smart home automation, security alarms, and other applications.
| Item | Information |
|---|---|
| Expansion module | Chain PIR (U225) |
| Main functions | Provides passive infrared motion detection data |
| Communication interface | Chain Bus / UART |
| ESPHome components | m5_chain_base, m5_chain_pir (external components) |
| ESPHome version requirement | 2026.9.0 or later |
uart:
- id: chain_uart_right
tx_pin: GPIO6
rx_pin: GPIO5
baud_rate: 115200
- id: chain_uart_left
tx_pin: GPIO47
rx_pin: GPIO48
baud_rate: 115200 external_components:
- source: github://m5stack/esphome@feat-m5-chain
components: [m5_chain_base, m5_chain_pir]
refresh: 0s m5_chain_pir:
id: chain_pir
uart_id: chain_uart_right
chain_index: 1
update_interval: 250ms Set the correct index according to the actual position of the Chain.
binary_sensor:
- platform: m5_chain_pir
m5_chain_pir_id: chain_pir
name: "Chain PIR Detection" output:
- platform: m5_chain_pir
id: chain_pir_red
m5_chain_pir_id: chain_pir
channel: rgb_red
- platform: m5_chain_pir
id: chain_pir_green
m5_chain_pir_id: chain_pir
channel: rgb_green
- platform: m5_chain_pir
id: chain_pir_blue
m5_chain_pir_id: chain_pir
channel: rgb_blue
light:
- platform: rgb
name: "Chain PIR Light"
red: chain_pir_red
green: chain_pir_green
blue: chain_pir_blue After the Chain PIR expansion module is connected, you can view the corresponding Binary Sensor and Light entities on the device page:
Dashboard card example
