Devices not always turn on (or off) when commanded in rules

Is it common for devices to sometimes not turn on(or off) when used within Rule Machine and Room Lighting app?

Originally, I thought it was something to do with my Z-wave devices but I recently added some Zigbee devices and I'm having the same issues. Most of the time, the rules work fine. But sometimes, there will be a device that won't turn on or off. It is not always the same device.

I have one rule that I added a repeat to check to make sure the devices turned on and that seems to be working. It is a rule that turns on my garage and workbench lights when the inside garage door is opened. Since adding the repeats to see if both lights turned on, everything seems to be working OK with the one rule. Do I need to add that to all my rules? That can't be done with Room Lighting apps so should I forget about using that app?

BTW, just checked and noticed that I have an outside light that didn't turn off at dawn that is controlled by the Room Lighting app. ;(.

Kenny

I would say that it's not common for devices to not respond if you have a good mesh. I will say, though, that if my hub has been running for 3+ weeks I'll see one particular device start to lag and miss on/off. That's my clue to reboot the hub and that seems to fix my issue.

The usual advice is to post your logs demonstrating the issue. Also, check you Z-Wave health by looking at the communication speed and make sure you don't have any ghost nodes. You can post an image of your Z-Wave setting page for others to review and help point out issues. Make sure you have repeaters in your mesh for both Z-Wave and Zigbee.

Now to your rule itself. Your ending action for your IF-THEN and Repeats should be at the same indent level. For your first Repeat you should move the END-REP to after the END-IF. For the second Repeat you should add both and END-IF and an END-REP.

To add to what @pseudonym said above, the culprit is typically the devices, though it can sometimes be that the rule is trying to do too much at the same time, or is being run multiple times at once (ex.: 2 doors open at exactly the same time).

I have found that a few of my non-standard (not supported, though they do mostly work) don’t always respond to commands. In those cases, like you, I setup repeat actions. In one case in particular, I also setup an illuminance sensor to confirm that a light has turned on or off, and that it what stops the reoccurrence.

I originally thought it was the Z-mesh problem but couldn't find anything wrong...no ghost, good communication, low noise, and all devices connecting directly to the hub with no jumps. That is the reason I added some Zigbee devices specifically replacing the workbench outlet switch that controls the workbench light. That is the rule that runs the most often throughout the day since it triggers when we go into the garage and also when we notice lights not being triggered when the door is opened.

It never seems to be one particular device that is having a problem. For example, we have 6 outside lights that turn on at dusk and off at dawn. I have probably seen each device at one time not turn on or off. I run that automation from the Room Lighting app. I will probably end up moving them to Rule Machine so I can use the repeat action to check if they were actually turned on or off.

I feel like I spent a lot of time trying to troubleshoot the issue instead of enjoying the new flexibility the Hubitat was supposed to give me over the Qolsys alarm panel with its z-wave automation. I'm starting to wonder if maybe it is the hub that is bad.

Thanks for the suggestion about the error in the rule. I swapped the first END-REP and END-IF lines. I'm having an issue since Hubitat doesn't seem to want to end END-IF on the repeat but did add the END-REP. Very weird.

Kenny

As @Sebastien pointed out, the rule may be trying to do too much if the six outside lights are in the same rule. Rule Machine can meter the on/off commands, Room Lighting may as well but I'm not sure. I find 50 milliseconds to work well in my rules where I'm controlling seven to nine Zigbee devices. If that's something you want to try, it can found under Run Custom Actions. You set the metering but don't set any parameters.

1 Like

Thanks. I will try metering to see if it works. I don't see away to use metering in the room lighting app.

I was able to add metering by creating a "Group and Scenes" for the lights and then using that group in the room lighting app.

I hope this works.

I just noticed that an outdoor light (using a Zooz ZEN76 switch) that is controlled by a Webcore Piston had not been turned off. When I looked at the device in the Hubitat app, it showed that it was off (even though it was actually on) and there was no event showing it had been turned off after being turned on by the piston early this morning. The piston log showed that the piston had run, but that it had skipped the off command for that switch because it was already off. When I looked at the switch, the LED was off, showing that the switch was actually on.
So clearly, the switch had received the "On" command early this morning and turned on, but somehow, the hub was not informed that the switch actually turned on. I don't know if this is because of a message back from switch to the hub being dropped by the network, the switch not sending a required message, or the hub receiving the message but not updating the switch state properly. Thinking about adding a refresh in the piston to make sure that the current status is updated properly and then a double-check of state to make sure each device is in the proper state. Probably won't bother unless it continues to be a problem.
The current Z-Wave routing shows that the ZEN76 has one hop through another Zooz switch from the hub and is connected at 54.4 kbps.