thank you
I definitely went wrong there I think I had the variable set to 5 originally and maybe when the button had been pushed it may have added another 5 on and the rule says to not run when the button had been pushed 5 times so that may have prevented the rule from running and prevented it from resetting back to 0 as already past 5. I made the button value 0 this Morning hopefully that's fixed it.
I have a rule to open a door with one press so I tried 2 and 3 presses of the button and got this, I think it may be working
that's odd, the button didn't seem to react in anyway with tests tonight, I am lost again.
the alarm notifications didn't stop on return either? I am using life 360 with stats there may be a bug with that as I had 2 homes on there at one time so I can change it to the Hubitat tracker as that's definitely working correctly. Hopefully that will sort out the main rule, I can re build this tonight.
Some of my other working rules had become glitchy recently, I have been trying to get experimental and have downloaded a lot of unnecessary drivers and had tried getting a few different apps running that our half done. Would this cause any problems? All other working rules our running ok at the moment
Everything I have done has been done with your lead I am just a student to this, I will have a play with the button rule tonight to see if I have done anything wrong there
not getting any logs from the magic button rule, I think I may have corrupted the system again? Is it time to backup and soft reset again lol?
I reset the hub, and changed the first srt line of the actions a Little it seems to work now.
will test again tomorrow
no its stopping working again, tried to start the main rule again thinking it wouldn't fire up but in the middle of the night when we our both at home and my mums asleep the speakers came on not good I will be in the bad books lol
the rule should cancel if we our at home shouldn't it?
for some reason the variable is counting instead of the rule, and its not reseting and the alarm won't turn off now even when present?
It should be "<= 5". Having it set to "= 5" will mean the notification will only happen when the variable is at 5. If it's not at 5, then the notification won't run. So you probably want to change that back.
The real issue is your rule for updating the variable needs to be changed as well. You have it set to change the variable to "5+1" on button press. So your variable will always either be 0 or 6. I think you just want it to be:
Trigger: "Button press"
Action:
Variable +1
Wait for even: elapsed time 1 minute
Set variable back to 0
I have a variable for math at 5 in there is that ok, I changed the reset for the timer to 10 seconds too as that long enough to push the button 5 times and a minute is too long if the button was pushed too many's times and to have to wait for it to reset while the alarm is running. Do you think this will be ok
do I need the math variable in there ?
that don't look good
changed the main rule back to this with the <= I also change the variable to the magic button that's counting in the variables
That looks solid now.
thank you again for your help you all our really amazing
I will give it a trail run tomorrow I can't risk waking my mum up again lol
if this is working I am going to try and build a rule for a few panic buttons with just a simple long press to start it. I had spoke to click and send I think it was and they can send a message to any number so would be good for emergencies, I don't think there is a driver on Hubitat but I think Its possible to write it in to something else and use a virtual switch from Hubitat to start the rule
still not working lol, the button does nothing to cancel the rule, and it doesn't even matter if we our not present, as soon as I turn it on it starts and I can't turn it off unless I pause the rule manually. When I originally started making the rule I had a else in there after the button do you think its due to this
that's how it was at first, I think I might use bit of this with the improved new rule with the repeating working, I think this might get the presence sorted so it at least turns off. then its just the button to work out still
Can you enable logging for the button rule and verify that the count is actually increasing when you hit the button?
I missed it, but your while condition in the main rule needs to be
while (variable <= 5 AND presence sensors are not present) repeat
That will stop the repeat cycle once the presence returns.
thanks I will do this now, and find the logs for the button, I think login is enabled but just a separate rule
There's 5 conditions in that screenshot...could you be more specific? It looks like you have some leftover conditions from when you were toying with the rule before. The first and last condition are the same.