Skip to content

ZBMINIR2: Cannot distinguish S2/PIR input events from relay state changes - both reported as action: on/off #11780

@tr1pp4

Description

@tr1pp4

Description

When using the ZBMINIR2 with an external switch/PIR on the S2 input, the device
reports action: on and action: off both when:

  1. The S2 input is triggered (e.g. by a PIR sensor)
  2. The relay is switched externally via Zigbee (e.g. by Home Assistant)

This makes it impossible to distinguish a real physical S2 event from a
software-triggered relay change.

Problem in practice

When building automations where multiple ZBMINIR2 devices trigger each other
(e.g. path lighting where any PIR should activate all lights), switching one
device via Home Assistant causes all other devices to also report action: on
— even though their S2/PIR input was never triggered.

Expected behavior

S2 input events and relay state changes should be reported as separate action
types, for example:

  • action: s2_on / action: s2_off for real S2 input events
  • action: relay_on / action: relay_off for software-triggered changes

Or alternatively, relay state changes triggered externally should not generate
an action event at all.

Device info

  • Model: ZBMINIR2 (Sonoff)
  • Firmware: 1.0.8 / 20251127
  • Zigbee2MQTT version: current
  • detach_relay_mode: false
  • external_trigger_mode: following(off)

MQTT evidence

PIR triggered (correct):
{"action":"on", "state":"ON", "detach_relay_mode":false, ...}

Relay switched externally by HA (should NOT produce action event):
{"action":"on", "state":"ON", "detach_relay_mode":false, ...}

Both messages are identical — no way to distinguish them.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions