Arrival Presence isn't working


#1

This Piston is supposed to turn on the garage door opener when either of us come home or if we are home and we open the house garage door, in both cases, it should turn off in 5 mins.

The house garage door works fine, the arrival presence doesn’t seem to work hardly at all for me and usually works for my wife

Any thoughts?

Rick


#2

Other than the way the code is laid out, to me it should work. I imported it and rearranged it a bit, see if it works any better. Do you have any virtual presence device you can test with?


#3

Thanks Eibyer,

I’ll give this a go. My wife will be home in about 15 mins so it will be tested then

No, I don’t have any virtual presence devices yet
Rick


#4

Well, nothing happened when my wife came home

Her device shows she left at 5:29am and arrived at 2:52pm so I know that’s working

Rick


#5

I’ll give it a try, back in a few.

Edit: My test worked… I changed to 15 seconds only so I can verify the timer.

Minimal Logs...
9/1/2017, 3:06:23 PM +501ms
+1ms	╔Received event [Home].time = 1504303584483 with a delay of -983ms
+456ms	╚Event processed successfully (455ms)
9/1/2017, 3:06:09 PM +237ms
+1ms	╔Received event [sim Presence].presence = present with a delay of 117ms
+257ms	║Setting up scheduled job for Fri, Sep 1 2017 @ 3:06:24 PM MST (in 14.991s)
+273ms	╚Event processed successfully (273ms)


Medium Log so you can see the turn on/off
9/1/2017, 3:09:07 PM +447ms
+0ms	╔Received event [Home].time = 1504303748498 with a delay of -1052ms
+150ms	║Runtime (36986 bytes) successfully initialized in 59ms (v0.2.0e5.20170812) (149ms)
+152ms	║╔Execution stage started
+201ms	║║Executed [sim SW1].off (28ms)
+243ms	║╚Execution stage complete. (92ms)
+252ms	╚Event processed successfully (253ms)
9/1/2017, 3:08:53 PM +272ms
+1ms	╔Received event [sim Presence].presence = present with a delay of 104ms
+147ms	║Runtime (36999 bytes) successfully initialized in 59ms (v0.2.0e5.20170812) (145ms)
+149ms	║╔Execution stage started
+217ms	║║Executed [sim SW1].on (34ms)
+224ms	║║Executed virtual command [sim SW1].wait (1ms)
+225ms	║║Requesting a wake up for Fri, Sep 1 2017 @ 3:09:08 PM MST (in 15.0s)
+234ms	║╚Execution stage complete. (86ms)
+237ms	║Setting up scheduled job for Fri, Sep 1 2017 @ 3:09:08 PM MST (in 14.99s)
+255ms	╚Event processed successfully (255ms)

#6

Looks like this is a false alarm, I read my wife’s recent device activity from yesterday not today. Let me get that working and try it again

Thanks
Rick


#7

Here’s another version thanks to @bangali :slight_smile: ,always optimizing :stuck_out_tongue:


#8

I really like this one :slight_smile:

Thanks a ton for all the help
Rick