Guarantee delivery of event from trigger


#1

1) Give a description of the problem
I have 2 pistons to control a water recirculation pump. Last night, the trigger to shut the pump off fired properly, but z-wave seems to have dropped the command. Since this was a timer based trigger (switch stays on for x seconds), it never fired again and the pump continued to run potentially forever. I need a way to guarantee that the pump will be shutoff.

In the ST forum several users have informed me that neither z-wave nor ST guarantee message delivery and execution.

2) What is the expected behavior?
I want the pump to come on and shutoff again after 70 seconds when it detects motion in one of 2 places, and the existing hot water temp is less than 86F.

3) What is happening/not happening?
some events are being dropped at the smartthings or z-wave layer and do not get re-executed by webcore when using a trigger.

**4)
These two pistons are my attempt to remedy the situation using a global status flag for the pump state. My hope is that the trigger to shutoff the pump will fire after 70 seconds, but if that doesn’t succeed, the follow up safety condition will retry the action until true.

I’m confused however about the behavior of a piston which contains both triggers and conditions. While the logic looks sane to me here, I have no clue how WebCoRE is actually going to interpret the second piston.

If I could figure out how to switch on the boolean state of a piston I could use that instead of my global var. I can’t quite figure out how to use the state of another piston in a conditional.


#2

Well damn, that didn’t work. My off piston sent the off command twice, but neither were received by the switch for some MOTHEREFFING reason. If I would have left it running longer perhaps it would have tried again? It doesn’t seem like it.

12/27/2017, 11:45:23 AM +371ms
+1ms â•”Received event [Home].time = 1514403923806 with a delay of -435ms
+170ms â•‘RunTime Analysis CS > 26ms > PS > 70ms > PE > 74ms > CE
+173ms â•‘Runtime (41372 bytes) successfully initialized in 70ms (v0.2.100.20171211) (171ms)
+174ms â•‘â•”Execution stage started
+182ms ║║Cancelling condition #4’s schedules…
+183ms â•‘â•‘Condition #4 evaluated true (2ms)
+184ms ║║Cancelling condition #1’s schedules…
+185ms â•‘â•‘Condition group #1 evaluated true (state changed) (4ms)
+188ms ║║Cancelling statement #7’s schedules…
+193ms â•‘â•‘Executed virtual command setVariable (2ms)
+196ms ║║Cancelling statement #2’s schedules…
+215ms â•‘â•‘Executed physical command [Hot Water].off() (16ms)
+216ms â•‘â•‘Executed [Hot Water].off (17ms)
+220ms ║║Cancelling statement #5’s schedules…
+242ms â•‘â•‘Executed virtual command writeToFuelStream (12ms)
+253ms â•‘â•‘Comparison (enum) on is_not (string) off = true (2ms)
+255ms â•‘â•‘Condition #12 evaluated true (9ms)
+260ms â•‘â•‘Comparison (boolean) false is (boolean) false = true (2ms)
+262ms ║║Cancelling condition #13’s schedules…
+263ms â•‘â•‘Condition #13 evaluated true (8ms)
+264ms ║║Cancelling condition #9’s schedules…
+265ms â•‘â•‘Condition group #9 evaluated true (state changed) (20ms)
+268ms ║║Cancelling statement #10’s schedules…
+284ms â•‘â•‘Executed physical command [Hot Water].off() (13ms)
+284ms â•‘â•‘Executed [Hot Water].off (15ms)
+288ms ║╚Execution stage complete. (114ms)
+289ms ╚Event processed successfully (289ms)


#3

Responding to commands from the ST app?


#4

It seems to, yes. I mean I’m able to shutoff the switch by hand from the app but then again most of the time it shuts off via my piston too…

I’m just surprised that the piston didn’t continually send off commands while it was still true. I guess I can code in a loop to do that.


#5

Yeah, that’s what I do with the locks, send lock command every X seconds until it reports locked.


#6

I guess I have a z-wave network issue. I’m a bit surprised by that. This device is z-wave plus, and while it’s at the far end of the house, in the basement, it’s really not that far.

I’ve rebuilt my network a couple of times to no avail. Finally just went out and bought another ge z-wave plus receptacle to replace an iris zigbee module that’s about 20 ft away. Hopefully that’ll make the z-wave mesh down in the basement more reliable.

I always seem to find a use for a spare iris receptacle…