Basic Multi Light/Motion/Condition with Motion Lighting App

So I think this will work for 90% of my needs in this one room...

Scenario:

Two motion sensors, one outside the room and one in. Outside one may not be needed anymore with the seriously quick activation on this hub.

Two GE Link light bulbs in an always on fixture.

A virtual switch for a yet to be created power monitoring device that will switch on at 125watts, and off under that. When this switch is on, I'm in the office (on my computer) and will prevent the automation from turning off.

Dimmer set to various levels for the three primary modes.

Now the one thing I can't do with this, create a virtual switch Mike's Office Light, to toggle this to use in Alexa

Without using RM, is this possible?

Also, with the "Disable off" option, if that switch turns off, will the motion countdown restart?

Your observation about Alexa is correct. I have this other app that I’ve used for that, and it creates a virtual device that you give the Alexa name for. I actually use that with Motion Lighting --> so your idea is a good one, and I’ll look to add that feature.

Disable off doesn’t reset the timer. It just stops it from turning off the lights.

1 Like

I like this Alexa idea of yours! So, it could be as simple as add name for Alexa. In effect, Alexa just overrides everything else in the app.

“Alexa, set office to 40”, or “Alexa, turn off office…”

2 Likes

Hey, I’ve implemented Alexa support in Motion Lighting and Mode Lighting. Will be in next release.

Thanks for the suggestion!

Don’t forget to add the created virtual device to the Alexa App and tell her to “discover devices”.

1 Like

@bravenel, I’m getting this error when creating a simple new rule after the firmware update:

app:1402018-02-25 19:01:20.776:errorCannot invoke method multiply() on null object

Two new lights and a motion sensor added, no issues. Created Motion Lighting, tagged the motion and two lights, labeled the Alexa name and put per mode dimmer levels. Lights turn on fine but when the timer expire’s, this error occurs.

And now it’s working all of a sudden, with no error.

Here is what I am trying to do, and am feeling a little overwhelmed with the options.

Devices - One Motion Sensor, One Hue bulb, and one on off switch. Also a weather device driver for illuminace/lux,

What I want to happen.
If lux is less than 50 and motion is activated turn on both lights.
As soon as motion goes inactive, turn off both lights. No delay.
If either (or both) of the lights was already on. Then don’t do anything.

I have a couple of similair lighting pistons using webcore, that I’m trying to move over to motion lighting.

Thanks in advance.

I think that might be out of the scope of motion lighting, to be honest. You could probably accomplish it by making a virtual switch that turns on with high Lux or manual button press turning on the light, then use that as your disable switch for the motion lighting.

Yeah, I have a pretty simple piston right now that works pretty well. I’ve just been trying to see what the capabilities are with the “built in” apps. To me this is not that complex. Turn on/off lights with motion when it’s dark outside. The only slightly advanced part, is don’t do anything if the lights are already on.

Which makes sense, otherwise, you’d walk into the room that was already being used, and then the lights would turn off after you left, and the person in the room would be sitting in the dark.

With Motion Lighting, use the switches that would turn them on (as in, either light was already on), to disable turning off from motion. Presumably in this case you expect to turn them off the same way they were turned on, with those switches. Once you turn them off, then the full motion functionality is re-enabled.

If they are turned on with Motion Lighting, they will still turn off though with no motion? It seemed like once they turned on that they would ever turn off

There are event and state triggers. You want to use button press on and button press off as your triggers to turn on and off a virtual switch. If you use light state, it won’t work.

What is it that you mean by this? What do you want to happen. How did the lights get to be “already on”. Were they turned on by motion? Or by some other means? Explain the specifics, and I can explain how to accomplish it.

So here is what I am trying to accomplish. I actually have two rooms in my house where I want to use motion lighting. With Smartthings and Webcore, I used a variable to me accomplish my goal, and it worked well, and it works ok with Hubitat as well. But, I’ve been trying to embrace the “official” apps for habitat just to get to know it better, and know what I can and cant do.

I feel like I’ve just done a poor job of explaining the goal and it works in my normal day to day routine.

I used my office in my example, but my kitchen is probably more understandable for most people.

I have two ceiling lights, both controlled by GE zwave dimmers. I have a motion sensor in the kitchen as well. 80% of the time I walk into the kitchen after dark, its just to grab something quickly. I’m in and out pretty quickly. I then walk back to another room, to enjoy what I just grabbed from the kitchen. But I can see the lights in the kitchen so I don’t want them to stay on for 1 minute after motion stops, I want them to turn off as soon as motion stops. This works just fine for me.

Sometimes, I want to spend more time in the kitchen, and maybe I stand still for a bit too long so the lights turn off, and then back on, etc. My fix with smartthings was to use a variable. I called it motion activated. So the logic was this.

Only if both lights were off, turn them on with motion, and then set variable Motion activated to true.

When motion becomes inactive, if the variable is true, then turn off the lights.

So if I wanted the lights to stay on and ignore my routine, I usually would either just manually turn on a light with the wall switch, or more likely use Alexa to turn on the “Kithcen Lights” right before I walked into the room. Then when I’m done, I use alexa to turn them off. With the lights off, the routine is now available to work again.

I liked this because I did not have to create another virtual switch or button to override the routine.

1 Like

This is what I thought you were trying to do. But, you’re right, the way I proposed doing it doesn’t work.

I will take it as a reasonable feature request for Motion Lighting, an option for turning off that says,

Don’t turn off from motion if already on

I wonder if mode restrictions might work better. Use a 5 min timeout on motion for evening (dinner time etc) and no timeout at night.

BTW, this feature, “Don’t turn off if already on”, was implemented in the last release. 1.0.6.709.

1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.