I have a button that triggers a script for bedtime to turn off all lights, and, if pressed again, checks to see if all lights are off and if so, turns a few (like the bathroom light) on.

My problem is one or two of the lights (connected via Zigbee2Mqtt) are often powered off at the switch on the lamp, meaning HA still sees them as “on” until the power is restored and they can be turned “off” via the app. The lights cannot be turned “off” (in HA) manually.

Is there any good solution for detecting when a light goes missing and turning it “off” in HA?

  • James R Kirk@startrek.websiteOP
    link
    fedilink
    English
    arrow-up
    3
    ·
    edit-2
    12 hours ago

    If they don’t have power, they drop from the network or mesh.

    That’s the problem, they don’t drop, the entity remains in a zombie state. Is there really no way to test if a device is still connected or not?

    EDIT: Or just manually set an entity to “off”?