Repeat until only fires 2 times


#1

Can someone help me out with my piston, and maybe even make it more efficient? I want to have a very basic home alarm system with what I have. The issue I’m having right now is that the Repeat Until loop only runs a maximum of 2 times, even though the until condition is NOT met.

I’m using ActionTiles, 2 door sensors, IFTT, SmartThings, and WebCoRE. Here is the order of events.

  1. I ‘arm’ the system by turning on a switch on ActionTiles. That triggers a SmartThings virtual switch to be turned on. When that SmartThings switch is on, I set a variable in WebCoRE to ‘On’.
  2. There is another SmartThings virtual switch that tracks the door sensor. When the door opens that virtual switch is set to ‘On’. When that virtual switch is ‘On’ then a WebCoRE variable is set to ‘Open’.
  3. Now I would like my Amazon Alexa to speak a command in a loop until the alarm is disarmed.

Any ideas why it’s only running 2 times?


#2

Alexa cannot handle a new command every 10 milliseconds…
Try adding a 30 second WAIT right after the SPEAK command.


#3

Looks like that worked, thanks! Any idea why a 30 second delay works, but a 10 second doesn’t?


#4

She doesn’t like it when we nag her, LOL


#5

Amazon has been rate limiting the endpoint recently and my Echo Speaks commands/responses have struggled with the delays.


#6

Hmm… I might just go back to the way I had it before if the delays are going to be long. Before this I had 5 SmartThings virtual switches and 7 automations that would turn the switches on and off in a pattern that would mimic the do until loop. Alexa was able to speak 3 times, play an alert sound, and then restart every 3 seconds. I didn’t like that solution because 7 automations for one job was ridiculous and there was a compounding timing issue. If that ran for greater than ~3 minutes the routines would catch up to one another because of the time it took Alexa to do the actions. Then the virtual switches would get caught in a scenario that wouldn’t trigger the loop to keep on going. I guess it is what it is for a homebrewed solution.


#7

@WCmore has a Process that you might be interested in. I may have to give it a try myself.