Second movement doesn't trigger the motion sensor automation

Hi guys,

How does motion sensor should react on automation?

I thought after an motion is detected and the automation is triggered, it should be triggered again after another motion is registered? Is this the outcome I should be expecting?

If this is the case, they don’t “retrigger” when detected new movement after the first movement is registered. Hopefully you understand what I meant. Any ideas?

Screenshot is as follows. Sensor is Tuya PIR with ZHA.

I would have to see the YAML of the automation.
Go to “Developers Tools”, States, and filter on your entity.
Have someone walk near the sensor and notice what the state of the entity is. Also, how long after they leave the vicinity of the sensor does the state change again?

1 Like

Post your automation in YAML format so we can see how you have designed it to work.

Thanks for the suggestion, I’ll report back once I get back home later today

alias: Room Presence (MBR)
description: Set scenario what the bed led will do based on the time and illuminance value
trigger:
  - platform: state
    entity_id:
      - binary_sensor.master_bedroom_motion_sensor
    to: "on"
condition: []
action:
  - delay:
      hours: 0
      minutes: 0
      seconds: 0
      milliseconds: 500
  - choose:
      - conditions:
          - condition: and
            conditions:
              - condition: numeric_state
                entity_id: sensor.master_bedroom_illuminance
                below: 1000
              - condition: time
                after: "16:00:00"
                before: "21:00:00"
        sequence:
          - service: light.turn_on
            target:
              device_id:
                - 0b3617c3abb6ed537b68bd9f4af1a5ec
            data:
              brightness_pct: 30
          - delay:
              hours: 0
              minutes: 0
              seconds: 30
              milliseconds: 0
          - service: light.turn_off
            target:
              device_id:
                - 0b3617c3abb6ed537b68bd9f4af1a5ec
            data: {}
        alias: Presence Before Bedtime
      - conditions:
          - condition: and
            conditions:
              - condition: numeric_state
                entity_id: sensor.master_bedroom_illuminance
                below: 1000
              - condition: time
                after: "21:00:00"
                before: "16:00:00"
        sequence:
          - service: light.turn_on
            target:
              device_id:
                - 0b3617c3abb6ed537b68bd9f4af1a5ec
            data:
              brightness_pct: 1
          - delay:
              hours: 0
              minutes: 0
              seconds: 15
              milliseconds: 0
          - service: light.turn_off
            target:
              device_id:
                - 0b3617c3abb6ed537b68bd9f4af1a5ec
            data: {}
        alias: Presence After Bedtime
      - conditions:
          - condition: and
            conditions:
              - condition: numeric_state
                entity_id: sensor.master_bedroom_illuminance
                above: 750
        sequence:
          - type: turn_off
            device_id: 0b3617c3abb6ed537b68bd9f4af1a5ec
            entity_id: d18fff0c8ed868f5b04a5cf7fd6f1787
            domain: light
        alias: LED Strip Off
mode: single

This uses sensor group to combine 3 sensors.

YAML posted. cheers

I’ve found the solution. Changing the mode from single to restart fixed the issue. Check the timeline below for details.