Motion Lighting not working 100%

@bravenel

Need assistance on this ML rule I have setup for the bathroom. Using (2) motion sensors and also dimming per mode to a certain level. The biggest thing I need to do is if someone overrides the dimming level with the switch that it stays that way and then shuts off after a delay of 2 minutes. This seemed to work all day yesterday but last evening the light would not shut off. Below is the ML rule.

Turn on Enable Logging, and the take a look at the Logs for the app. It will state what it is doing, including why it is not turning off. I'd be very curious if this problem is repeatable. Override has been a very prickly problem. We've made some changes to how it works attempting to overcome these issues, but it may still have issues in some circumstances. So, if you could do this logging it would help.

I have it turned on. Wish we had a way to select certain devices/rules/apps we could hold onto logs for longer than the buffer. Would greatly assist in troubleshooting these issues. Especially at 3am.

1 Like

I just leave a tab with the Logs page open all of the time. It's easy to go back and see anything. That tab only comes to the front when needed, and I refresh it to start over fairly frequently, when I'm working on something and don't care about the past anymore.

1 Like

Are the devices in your motion lighting app Alexa child devices or the dimmer's themselves?

Nope

@bravenel

Here are some logs with the above config. Stays at 100% but then switches to 3% even though there is continued motion.

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:14:08.943 pm[info](http://10.0.2.38/installedapp/configure/1712)Override initiated by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:13:53.159 pm[info](http://10.0.2.38/installedapp/configure/1712)Override initiated by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:13:51.008 pm[info](http://10.0.2.38/installedapp/configure/1712)Not turning on:

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:13:50.975 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion active Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:13:38.337 pm[info](http://10.0.2.38/installedapp/configure/1712)Delaying off for 2 minutes

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:13:38.066 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion inactive Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:11:37.279 pm[info](http://10.0.2.38/installedapp/configure/1712)Not turning off: motion active

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:10:06.213 pm[info](http://10.0.2.38/installedapp/configure/1712)Override initiated by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:10:03.176 pm[info](http://10.0.2.38/installedapp/configure/1712)Override initiated by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:09:48.703 pm[info](http://10.0.2.38/installedapp/configure/1712)Override initiated by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:09:47.451 pm[info](http://10.0.2.38/installedapp/configure/1712)Not turning on:

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:09:47.409 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion active Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:09:37.220 pm[info](http://10.0.2.38/installedapp/configure/1712)Delaying off for 2 minutes

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:09:37.172 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion inactive Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:06:37.254 pm[info](http://10.0.2.38/installedapp/configure/1712)Override initiated by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:06:34.620 pm[info](http://10.0.2.38/installedapp/configure/1712)Override initiated by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:06:33.344 pm[info](http://10.0.2.38/installedapp/configure/1712)Not turning on:

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:06:33.282 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion active Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:06:07.209 pm[info](http://10.0.2.38/installedapp/configure/1712)Not turning off: motion still active

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:06:07.191 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion inactive Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:03:18.470 pm[info](http://10.0.2.38/installedapp/configure/1712)Override initiated by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:03:15.275 pm[info](http://10.0.2.38/installedapp/configure/1712)Override initiated by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:03:13.956 pm[info](http://10.0.2.38/installedapp/configure/1712)Setting dimmers [Master Bathroom] to 3

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:03:13.918 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion active Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:03:06.071 pm[info](http://10.0.2.38/installedapp/configure/1712)Not turning off: motion still active

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:03:06.054 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion inactive Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 11:00:23.231 pm[info](http://10.0.2.38/installedapp/configure/1712)Not turning off: motion active

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:58:32.019 pm[info](http://10.0.2.38/installedapp/configure/1712)Setting dimmers [Master Bathroom] to 100

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:58:31.994 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion active Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:58:23.171 pm[info](http://10.0.2.38/installedapp/configure/1712)Delaying off for 2 minutes

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:58:23.113 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion inactive Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:58:09.358 pm[info](http://10.0.2.38/installedapp/configure/1712)Setting dimmers [Master Bathroom] to 100

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:58:09.323 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion active Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:57:34.168 pm[info](http://10.0.2.38/installedapp/configure/1712)Delaying off for 2 minutes

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:57:34.104 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion inactive Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:56:58.306 pm[info](http://10.0.2.38/installedapp/configure/1712)Setting dimmers [Master Bathroom] to 100

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:56:58.281 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion active Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:56:44.343 pm[info](http://10.0.2.38/installedapp/configure/1712)Override ended by Master Bathroom

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:56:42.614 pm[info](http://10.0.2.38/installedapp/configure/1712)Turning off

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:54:42.563 pm[info](http://10.0.2.38/installedapp/configure/1712)Delaying off for 2 minutes

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:54:42.531 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion inactive Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:51:09.726 pm[info](http://10.0.2.38/installedapp/configure/1712)Setting dimmers [Master Bathroom] to 100

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:51:09.668 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion active Motion Sensor - Master Bathroom - Zooz

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:50:53.841 pm[info](http://10.0.2.38/installedapp/configure/1712)Not turning off: motion still active

[app:1712](http://10.0.2.38/logs/past#app1712)2019-01-07 10:50:53.817 pm[info](http://10.0.2.38/installedapp/configure/1712)Motion inactive Motion Sensor - Master Bathroom - Zooz

It would really help if you could explain where you think it is failing, what are the circumstances, what did it not do it should have done, or what did it do that it should not have done. and support that from the specific instance of log information. As it is, I don't have the context that you do, and it's very difficult to attempt to construct it mentally.

@bravenel

Ok so here is the scenario:

  • ML is set based on Mode to set lights that are activated by motion
  • After 2 minutes of no motion the lights shutoff
  • IF the dimmer level changes then keep dimmer level the same but turn off when no motion after 2 minutes

What is happening:

  • ML is setting lights at correct levels based on Mode and activates with motion
  • ML is allowing the dimmer to change levels based on user input
  • ML is keeping the dimmer level for 2 minutes BUT then turning back to mode setting and THEN if no motion 2 minutes later shutting light off

This is the issue. ML is doing something hokey with the dimmer level verses just keeping it the same until there is no motion and then just turn off lights.

OK, thanks. I will investigate.

1 Like

Is it fair to say that what you're seeing is that override isn't being maintained, or perhaps not even established? What release are you running? Could you do an experiment, get ML to turn the lights on, adjust them as you describe, and then look at App Status page. I want to know the value of a state variable called (drumroll) "override".

@bravenel

I will give this a try after I get back from vacation. Next week same time...same bat channel.

So I did this and the override goes true. Currently running 2.0.4.118.

Now the delay off doesn’t seem to work. I have it set for 2 minutes and going on 5 minutes without motion. After I did the override.

@bravenel

Ok so the issue is now with delay off. As after removing the delay off from ML and then creating a simple RM to delay cancel when no motion I now have the desired results needed.

Still a big though in ML.

Are you saying that the bug is this: With Override for Level Only, if the level is changed the lights don't turn off after the time is up? If so, I'm not able to reproduce this behavior.

With these settings, If the dimmer level is changed, after motion goes inactive, motion active during the delay period does not change the level. After the delay is over, the lights turn off.

Correct. The delay doesn’t turn off lights.

That's weird. I've tested this with two different instances of Motion Lighting, and both work as expected.

Reviewing this thread, there seem to have been a number of different issues you were having.

These comments were over an extended period of time. Were all of these with the first ML instance you posted at the top?

Unfortunately, trying to dig into something like this in this forum is quite difficult, especially over an extended period of time.

@bravenel

I am not gonna lie I tend to try to troubleshoot these issues in multiple directions.

Ok so here is where I am at. My suspicions is this is a combination of Delay Off and the Mode levels.

Current ML for Master Bathroom - notice even though I have the Delay off for 2 minutes in ML it never works. RM rule below is handling this issue. BUT since 2.0.4.118 I do not have the override issue like before. So that is good!

Inside the ML Rule:


And current RM Rule for Master Bathroom:

Anyways my current setup works without issues BUT I am trying to contribute back as I believe this should all work just inside of ML.

This is tantamount to saying the Motion Lighting's most basic feature, turning lights off after motion inactive and a delay, doesn't work. I have 20+ instances of Motion Lighting installed, all similar to yours or variations of yours, and they all work.

So something else must be going on.

One thing that could cause this is if your lights are reporting an intermediate dimmer level while ramping up. If this is the case, override will malfunction. Disable override, and then it will work.

Motion Lighting is going to get a new feature to allow for two different modes of override initiation: physical switch or level change. Level change (how it works now) is incompatible with lights that report level during ramp, as it takes that report as a dimmer level change.