Make flow for security with button

I want to buy a simple button or an aqara cube button to do scenes of unlocking the alarm when I come home.

Do you think I can create consecutive flows for the button and say
in this period of time the 3 flows are executed
flow 1 = 1 button press
Flow 2 = shake the cube
Flow 3 = rotate the cube 180 degrees

deactivate alarm monitoring?

If so, do you have any flows to offer me?
I find it hard to use the logic app for even longer time for Flows.
Thank you

Do you mean that you only want to deactivate the alarm if you perform the three steps shortly after one another?

If so, I would use a number variable which is set to 0 at start. Also, install a timer app (chronograph, countdown timer or something similar)
Then the following flows:
if one button press then start timer for 10 secs and set variable to 1
if cube shaken and variable is 1 set variable to 2 else set variable to 0
if cube is rotated 180 and variable is 2 then deactivate alarm and set variable to 0 else set variable to 0
if timer ends set variable to 0

Any other actions on the cube should also set the variable to 0.
That way you have 10 secs to do the three things in the right order.


Waw big thanks. I close this thread.