Time-delayed events not occurring


#1

1) Give a description of the problem
A single piston that controls the actions of 3 exhaust fans works sporadically.

2) What is the expected behavior?
When any one of the fans is manually turned on, the piston turns itself off after 10 minutes.

3) What is happening/not happening?
It APPEARS, that if one of the fans is on when another fan is turned on, the second fan never gets turned off. Do I need a separate piston for each fan? Maybe asynchronous execution?

**4) Post a Green Snapshot of the piston


#2

It (sort of) makes sense. When a second fan is turned on the $currentEventDevice changes, execution jumps back to the with…, and the Turn off command never executes for the first fan.
Here’s some code that should handle the situation, including logging each fan that is turned off: (ignore the “Contact Sensor 1” value for MyFans. I don’t have a Switch 24, Switch 23, or Switch 1, which is what the value should be for your use.)
The only caveat now is that, when you turn on a second or third fan, all fans that are currently on will turn off 10 minutes from now, regardless of how long they’ve been on.


#3

Thanks for the thought, but not really what I am looking for. With three kids the fans would stay on indefinitely with that setup. Unfortunately I bricked my WebCore instance trying to set up a weather tile piston so it will be a bit before I can get back in and see what other options there are other than individual pistons.


#4

Some people tend to shy away from creating multiple pistons, but in all actuality, it is often helpful to streamline the events passing thru your hub.


#5

I agree with @WCmore, you won’t have any issues if you have a piston for each device.

In theory you could get it working by enabling piston execution parallelism (access the piston settings by clicking on the title of the piston whilst editing, then the cog symbol).

You will probably also need to change the task cancellation policy to never. (click on with, then the cog symbol).

But still better to run multiple pistons.

Edit: are you sure your devices report physical vs programmatic events? most don’t, and the ones that do give erroneous results when communicating through the mesh. The feature is as good as useless.


#6

Bricked seems a bit extreme… what have you tried?

  • clean up and rebuild data cache?
  • hard refresh of your browser?
  • different browser?

Do not jump the gun and delete webCoRE… there is nearly always a workaround, at the very least there is a way to recover your piston restore codes!!


#7

Can’t get to any of my pistons or any of the features of WebCore any more. I get the "There was a problem loading the Dashboard Data…’ error and a blank dashboard, along with the following error in the live log:
physicalgraph.exception.StateCharacterLimitExceededException: State cannot be greater than 100000.0 characters
I have all my pistons backed up (not very many to begin with - Tesla API items being the most complex) so may just go nuclear.


#8

Go to the webCoRE app within the ST app > settings > clean up and rebuild data cache.

Then hold Ctrl whilst clicking the refresh button on your browser (hard refresh)… usually works.

Another thing to try is to change your password via webCoRE in the ST app… should force a logout and allow you to retry.


#9

Cleanup and rebuid worked. Thanks!