Successfully Fixed Tuya Motion Sensor Delay

Hi everyone, I wanted to share my recent experience with the Tuya ZG-204ZL motion sensor. After setting it up a month ago, I noticed that the delay between detecting motion and triggering the lights was inconsistent. It was quite frustrating, especially during the early mornings when I needed the lights to come on immediately!

After some research and trial and error, I finally found a solution that works perfectly. I adjusted the automation settings to include a wait template and a short delay before turning on the lights. Here’s how I did it:

yaml
choose:

  • conditions:
    • condition: trigger
      id: motion_detected
      sequence:
    • wait_template: “{{ states(‘sensor.my_tuya_illuminance’) | int < 950 }}”
      continue_on_timeout: true
    • delay: milliseconds: 500
    • action: light.turn_on
      data: {}
      target:
      entity_id: light.mylamp
  • conditions:
    • condition: trigger
      id: no_motion
      sequence:
    • action: light.turn_off
      data: {}
      target:
      entity_id: light.mylamp

This setup ensures that the lights turn on almost instantly when motion is detected, and they turn off after the motion stops. I’m really happy with how it works now!

I’d love to hear if anyone else has similar issues or if there are even better solutions out there. It’s amazing how a small tweak can make such a big difference in functionality!

Thanks to everyone in the community for the support and resources. Keep sharing your tips and tricks! :+1: