Problems with "not turning on, already on"

I should specify that when I say "manually" turned on, I'm turning the light on in Hubitat. I didn't touch a physical switch.

In my testing, light A was controlled by a Lutron Radio RA2 select switch. Light B was plugged into an Inteset Z-Wave Plus Power Plug.

And to add a bit more, which may be important:

Both lights are turned on by the same rule. When testing, I triggered motion, then turned off light B. I waited until motion was inactive, then again triggered motion. In this scenario, light B did not turn back on.

Maybe it's the manual turning off that isn't registering with Hubitat, so it thinks that both lights are still on?

I'm lost as to what you are testing at this point, and what A and B are. Please show a specific ML instance that is being tested. Do these steps:

Turn on logging in the automation. Turn off all of the lights controlled by the automation. Open the automation and hit Done. Then show a screenshot of the Event Subscriptions from the App Status page. If the automation fails to work as expected, show all of the logs from the automation for the sequence of events leading up to the failure, and then show the Application State portion of the App Status page.

Here is the rule:

I triggered motion, turning on stairway lights and stairway floor lamp. I manually turned off stairway floor lamp via a Hubitat dashboard, waited until all motion sensors were inactive, then triggered motion. Stairway floor lamp did not turn on.

Event subscriptions:

Log:

Application state:

Thanks, I will look into this.

1 Like

A bit of extra info:

-I was able to reproduce this on another rule. That is, with both motion-rule-triggered lights on, turn one off manually and then trigger motion; the light does not turn back on.

-My initial interpretation that it matters whether the light that remains on was triggered by a rule or manually was incorrect. I used a different rule to turn on one of the lights, and the second light turned on appropriately with motion (via the first rule).

-So, the behavior appears to reflect that the "do turn on if already on" function doesn't produce the desired behavior because Hubitat is not registering, for the purposes of the rule, that the manually-turned-off light is actually off. (To be clear, however, it is shown as being off in dashboards and in devices.) In other words, when it says "not turning on, already on," it is saying that both lights are already on (which is not the case).

I have found the bug with this, and fixed it. This fix will be in the next release. Thanks for your patience.

3 Likes

Thank you so much! I appreciate all of your work.

Hi!
I ran into a similar problem and would like to ask a confirmation that the above mentioned fix will resolve my issue as well.
I have a simple test Motion Lighting setup with one motion sensor and one led controller. The light is turned on by the motion sensor and then it is turned off properly after the set delay. Now if I trigger the motion sensor again within a short period of time, then I get a "Not turning on, already on" log message, even if the "Do turn on all even if any already on" setting. There are two problems here:

  1. HE incorrectly thinks the light is on.
  2. HE disregards the "Do turn on all even if any already on" setting.

The logs shows these events clearly:

app:452022-02-13 20:37:30.173 infoMHSC1 was turned off
app:452022-02-13 20:37:28.647 infoNot turning on, already on
app:452022-02-13 20:37:28.642 infoMotion active Aqara Motion Sensor 1
app:452022-02-13 20:37:17.548 infoMHSC1 was turned on
app:452022-02-13 20:37:17.281 infoMHSC1 was turned off
app:452022-02-13 20:37:17.244 infoTurning off lights
app:452022-02-13 20:36:17.230 infoDelaying off for 1 minute
app:452022-02-13 20:36:17.197 infoMotion inactive Aqara Motion Sensor 1
app:452022-02-13 20:35:30.118 infoMHSC1 was turned on
app:452022-02-13 20:35:12.180 infoSetting dimmers [MHSC1] to 50
app:452022-02-13 20:35:12.172 infoMotion active Aqara Motion Sensor 1

Please note in the above log, that HE turns on the light immediately after turning it off. In reality the light does not turn on. After a few seconds there is another log message about turning the light off.

If I activate the motion sensor before that the second "light off" message, then the "not turning on, already on" will occur. If I wait wait for that second off event, then it will work properly, as it can be seen here:

app:452022-02-13 20:48:00.106 infoMHSC1 was turned on
app:452022-02-13 20:47:34.741 infoSetting dimmers [MHSC1] to 50
app:452022-02-13 20:47:34.732 infoMotion active Aqara Motion Sensor 1
app:452022-02-13 20:47:30.194 infoMHSC1 was turned off
app:452022-02-13 20:47:12.610 infoMHSC1 was turned on
app:452022-02-13 20:47:12.288 infoMHSC1 was turned off
app:452022-02-13 20:47:12.252 infoTurning off lights
app:452022-02-13 20:46:12.241 infoDelaying off for 1 minute
app:452022-02-13 20:46:12.211 infoMotion inactive Aqara Motion Sensor 1
app:452022-02-13 20:45:30.134 infoMHSC1 was turned on
app:452022-02-13 20:45:07.186 infoSetting dimmers [MHSC1] to 50
app:452022-02-13 20:45:07.180 infoMotion active Aqara Motion Sensor 1

The wait time before the second "off" message arrives varies between a few seconds up to 20 seconds.

The ML configuration: