i am just starting to configure my lights to use motion but i am noticing some weirdness that i cant quite put my finger on what is the true cause, i figured id ask incase you know if its happend before basically this is happening to various lights switches in the house i am using mostly TS110E 1 channel/2channel dimmers.
basically my issue is i find that sometimes when the blueprint tells the light to turn on, z2m (rather HA) marks the input as "ON" but no lights actually come on. if i use the physical switch it comes on and does not change the device switch state (even though everything thinks its on, the physical switch will then change the state as expected for following state changes when this happens), if i change the brightness in z2m or home assistant it comes on, if i turn it off and then on it will come on in z2m or home assistant.
its weird if i "Reset" the state via the above then the motion works for a while until eventually getting back in this state of being "On" without being on
No but it looks like a communication problem or a bug within you lights.
Are you using a group? I only say this because I see "Office & Stove Lights" as your selected entity input. If your using a group then try and select the entities instead of the group to see if that helps/works.
All your settings look good and the blueprint wont be causing this.
Are there any best practices for using a combination of a PIR and mmWave for the trigger?
Ideally I would like the PIR to be the trigger but then mmWave to maintain. Iβve found when using the mmWave as the trigger there are too many false positives but when the PIR is used then itβs not as effective at maintaining.
as a quick update incase its ever raised again, im working around the issue with the switches by using the dimming feature of the blueprint, this means that aslong as its turned off via the timeout then the brightness is never the same.
sadly if its turned off at the switch it acts as an override if you will as the brightness will be the same meaning it wont auto turn on
i will need to play with lux adjustments as i think this is cause more brightness variance reducing the liklyhood of this happening even further
You can do this but it gets into really advance trigger template binary sensors. You need to know how to create a trigger template binary sensor and in the FAQ you will find more information on this.
PIR Trigger + mmWave Maintain Occupancy Sensor
This trigger-based template binary sensor combines a PIR motion sensor and an mmWave presence sensor to create a more reliable occupancy sensor.
How it works
PIR motion sensor > Triggers occupancy ON.
mmWave presence sensor > Maintains occupancy while presence is detected.
mmWave alone cannot trigger occupancy ON, helping to reduce false positives.
Occupancy turns OFF only when:
The PIR sensor is OFF, and
The mmWave sensor is OFF
You need to update the binary_sensor.pir_sensor with your PIR sensor entity ID and the binary_sensor.mmwave_sensor with your mmWave sensor entity ID. The Advance Room Occupancy Sensor change to what you would like to call this binary sensor.
template:
- triggers:
# PIR turns occupancy ON
- trigger: state
entity_id: binary_sensor.pir_sensor
to: "on"
id: pir_on
# PIR turns occupancy OFF
- trigger: state
entity_id: binary_sensor.pir_sensor
to: "off"
id: pir_off
# mmWave turns occupancy OFF
- trigger: state
entity_id: binary_sensor.mmwave_sensor
to: "off"
id: mmwave_off
binary_sensor:
- name: Advance Room Occupancy Sensor
state: >
{% if trigger.id == 'pir_on' %}
true
{% elif trigger.id in ['pir_off', 'mmwave_off']
and is_state('binary_sensor.pir_sensor', 'off')
and is_state('binary_sensor.mmwave_sensor', 'off') %}
false
{% else %}
true
{% endif %}
Once you create this trigger template binary sensor you would use it in the trigger input only.
Hope this helps you.
Let us know how you go and if it all works then I will add it to the FAQ sensors.
No, it doesn't do this but you have some settings that are not correct. Thanks for your YAML as it helps me help you.
In both Dim Before OFF (normal lights and night lights) your missing the Dim Before OFF - Toggle Helper you need 2 toggle helpers and they can only be used in the one input. Add them in and you see it works.
I'm limited to what Home Assistant provides. There is currently no way to make inputs become required based on a selected option. Even if I mark an input as required, the entire section won't collapse. It's not how I would design it, but this is the way Home Assistant handles it.
I have some lights controlled by a motion detector and it works great.
But when we have some guest, I would like to use the bypass functionnality but I don't find my desired switch.
I have installed a physical switch (Aqara wireless H1) connected using z2mqtt and all I find when I search this device is :
Hi Charles, thanks for your kind words... your welcome.
You should be able to see all your HA entities... as there are no restriction (filters) on your selection. Have a look at what your switch is called and then search for this as currently your searching for cuisine interrupteur and it may be filtered out.
The bypass entity must be a switch with an ON and OFF state. The automation checks these states to determine whether the bypass is active. A button cannot be used because buttons do not maintain an ON or OFF state; they only generate an event, so the automation cannot determine whether the bypass should remain enabled or disabled.
All bypass options disable the automation when the bypass is turned ON. You can choose what happens to the light when the bypass is enabled by selecting option 1, 2, or 3.
Ok thanks so that's why I do not see it.
So I guess I need to create a new toggle and another automation to switcj the new toggle when I press on my switch.
In my case I want to be able to turn the light ON (or keep it ON if it was already the case) until I press on another switch to disable the bypass (so another toggle I suppose).
But I not sure if I can do that, it seems it only a delay can disable the bypass.
Do you confirm ?
EDIT : I'm dumb
After testing, I just need the first toggle and when I switch OFF, it automaticaly disable the bypass....
Thanks
I have two zigbee smart relays, named Garage 1 and 2, in a light group named Garage Lights.
I have a zigbee tilt sensor on the garage door, when it's off, the main door is closed. I do not yet have a sensor on the "people" door. (My garage is a fully separate building from my house)
I have several occupancy sensors inside the garage, both motion and mmwave radar detectors.
I have those detectors all grouped into a binary group named Occupancy, and when it is on, it has detected some form of occupancy.
Now. I have the group for the lights set as the Light to be affected, the sensor is the occupancy group, with a 3 minute delay there, and I have the bypass set for the garage door, with a 30 minute delay, as I want the lights on if the garage is open, but if it stays open for more than 30 minutes without occupancy detected then turn off.
Now, I just looked, and one of my garage lights is on, the other is off, it's been on for 29 minutes and the garage door is closed.
What gives here?
Edit to add: I had it working better, but without the 30 minute delay (just left it on no matter how long the door was open) when I had it set up using several different automations, but switched to this blueprint to add that final bit and to consolidate some automations.
It did finally turn off after 30 minutes, but 30 minutes after the door was -closed-
Might be just a miss with the light command. I have one light, Tuya interface I think, that will occasionally miss a command. I just added two commands to turn the light on in the automation, and two to turn it off. With a small delay between each. Not an elegant solution but it works.