#Automations that could potentially trigger over and over again what is the best way to handle it ?

1 messages · Page 1 of 1 (latest)

wet gate
#

Is having the automation turn itself off than on again best ? Maybe just increasing the amount of traces the automation saves

I tried the first option with mixed results I saw a few times were the automation never completely ran so it just sat disabled but for the most part it was fine

I only just switched over to increasing the trace count. I can see this working but just feels kinda hacky and though I see if there is a proper way or something I am missing

Thanks! Using built in HA automation if that was not clear

pine sail
#

Is it supposed to be triggering repeatedly? If not, I would suggest setting up better triggers

wet gate
#

its based off motion

#

Really no way I can stop it from triggering over and over.

pine sail
#

Plenty of ways you can do that.
If you set the motion sensor to hold on for (e.g.) 5 minutes, it won't constantly turn off and on again repeatedly as any motion within 5 minutes of the last motion will just make it stay on longer, and staying on doesn't trigger a state change

wet gate
#

thanks I will have to give that a test

#

Having a looking at the motion sensor light blueprint HA provides it looks like they add in a wait for trigger step. I think that would be required in order for your suggestion to work

pine sail
#

It is not required

wet gate
#

Hmmmm even the blueprint will Generate traces over and over again

pine sail
#

It's a change to the sensor, not the automation

wet gate
#

I was hoping to not have more than 1 trace per automation run.

pine sail
#

It will never generate more than 1 trace per trigger

#

It literally cannot

wet gate
#

by default the automation will hold 5 traces... So if you trigger your automation it will create a trace. IF the automation is triggered again while its in a wait or say a loop a new trace will be created

#

so after 5 you will lose the Original trace so you can debug if something goes wrong. THe automation itself will still work but again you wont SEE the trace

pine sail
#

So stop it triggering so much...

wet gate
#

you can increase the amount of traces or disable the automation. that is what I found so far. Was hoping for more suggestions

#

as of this second I am using the built in HA provided blueprint for motion based lights and it does what I Described

#

how would you like me to NOT trigger it if I am moving about the room lol

pine sail
#

As I already described.
By having the sensor stay on for more than a fraction of a second, the state of the sensor doesn't flicker on/off repeatedly causing multiple triggers

wet gate
#

I don't think what you're saying works

#

Maybe the HA blueprint is setup in a outdated way. I don't know

pine sail
#

Again, it's a change to make to your sensor, not to the automation

wet gate
#

Motion sensors will always change their state

#

Can you even adjust the rate for a hue sensor

pine sail
#

Go to the device page and see what options you have

wet gate
#

Yeah maybe in the hue app ui google says but I think that just turns down the Sensitivity

#

Seeing as I can't stop it from triggering as I walk around the room do you have another sugguestion than

pine sail
#

No. Until you try a single thing I've already suggested, I'm not going to give you others.

wet gate
#

Your request is to change the trigger so it doesn't trigger as often. I want to know the best way to handle a automation that tirggers often NOT how to stop it from triggering over and over

#

This is a hue sensor not some homebrew esp thing. I will be limited in what I can do with the sesnor it self

pine sail
#

Take a screenshot of the device page

#

It should have a timeout setting you can just control

wet gate
#

it does not

#

Under configuration you have light sensor enabled and motion sensor enabled

pine sail
#

How are you connecting to it. Occupancy timeout is visible in both zha and z2m

wet gate
#

its a hue bridge

pine sail
#

Can you change it in the hue app then?

wet gate
#

Yeah maybe in the hue app ui google says but I think that just turns down the Sensitivity

pine sail
#

Sensitivity and timeout are different parameters

wet gate
#

Correct

#

So no then

pine sail
#

Shame

wet gate
#

I don't have zigbee anyway. Hue creates its only network which uses zigbee as a backend but I don't run my own or have any standalone zigbee stuff

#

I am not looking to change anything on my motion sensor anyway. I am not looking to change the trigger. Just seeing if there is a better way to handle all the triggering

pine sail
#

No

#

If its constantly triggering and you want traces, you need to increase the amount of stored traces

#

The only other option is reducing the number of triggers. Either modify the device settings (which apparently Philips hides from you) or make an intermediate helper to process the flickering data from the sensor and trigger off that instead

raw thorn
#

create a new template occupancy binary_sensor (helper). It should turn on with the motion sensor and turn off after - say - 5 minutes of inactivity. Then trigger your automation based on that rather than the motion sensor

wet gate
#

I will have a look at the helper. Having all these traces is not a major deal just wanted to see if there was a better way. I was also Disabling and enabling the automation as an example but like I stayed it wasn't always 100%

#

Thanks for the helper idea guys!