Your motion sensor doesnât necessarily need a lux sensor.
What I am trying out right now is using my, âmaster,â lux sensor that I have monitoring the outside lux.
I am using this lux sensor to control several webCoRE pistons and also using it in this app.
For example, I have a laundry room in my basement that needs light way before my upstairs, âroomâ, does. So, I am experimenting with and watching my outside lux sensor and setting each room accordingly. i.e. I need light in the laundry room when the lux is below 1000 lux, but my upstairs room doesnât need light until say 500 lux since there are more windows to bring in natural light.
@kxavier23
This depends on where the lux sensors are present, and the relative brightness levels across rooms.
Suppose your lux sensor is indoors, say in the upstairs room, and you rely on this for turning on the laundry room lights. Every time the upstairs room lights are ON during night, the laundry room will fail to light up even when there is motion.
I can see your point, which is why I am not using an indoor lux sensor value. Youâre right, if I used a lux sensor in the house, say my living room and the light comes on there, the lux value has nothing to do with the outside light that is influencing the light in say the laundry room.
I am trying to use one source of truth, outside light.
Each, âroom,â in @bangaliâs app can utilize a central or common lux sensor and each room can react independently.
The app is bringing together a bunch of variables (lux, motion etc) in a very flexible way.
additionally only thing i would add is that most rooms work well when using an outside light lux measurement. in the occasional exception that you have one room or space that does not work well when using outside light lux, you always have the option of buying a lux sensor just for that room and not every room.
but from trying this for couple of months i have gotten all rooms to work uniformly in controlling lights by using different lux values across rooms.
just install this, set for your location and use as outdoor lux sensor:
off course if you want to switch to using dedicated outdoor lux sensor afterwards thats always possible. but this will get you started with the concept.
fan speed control. though still have to figure out how I am going to do this since I dont have any fans in the house forget ST controlled fans. may be will do thermostat control instead.
This is very interesting and I have read all the posts but I am confused as to how it will detect the room to be occupied if there is no motion. For instance, I am interested in this because when I am watching TV I have my hues lights dim, but after a while the lights go off because there wasnât any motion. So how does this work to keep the lights from going off if I am not moving?
the basic method to keep the lights on when there is no intermediate motion is to move the room to a âengagedâ state. the ways you could do this are:
currently:
set the state of the room to âengagedâ from the ST app manually.
pushing button 9 using the ST lighting app when the TV turns on. for this you will need a smart outlet monitoring the TV.
whats coming is:
if you have a contact sensor installed on the room door and close the door it would change the room to âengagedâ state till the door is opened again.
monitoring a switch that tells the app to move the room to âengagedâ state while the switch is on. so, if TV switch is on consider the room to be in âengagedâ state even if the room has no motion.
hoping i can get these last 2 things done over the weekend and push to github by mon/tue.
EDIT: struck out line above because ST smart lighting app does not allow button push as the action even though button push can be the trigger.
Does this engaged status have a timer? I have been following your app and been meaning to give it a go. I have something similar in alot of my webCoRE pistons where I define a boolean variable as occupied true or false and build rules with that variable as a restriction for auto offs. My logic is basic and simple and relies on 1 motion and 1 contact:
If motion changes to active
And
Contact is closed
Then set variable occupied=true
If motion stays active for 5 minutes
And
Contact is open
Then set variable occupied=true
If motion stays inactive for 1 hour
Then set variable occupied=false
If contact changes
And
Motion is inactive
Then using Location
Wait 5 minutes
Then set variable occupied=false
Was asking about the timer because what if it thinks someone is in the room but actually is notâŠ
OK, that would work in my case because I could maybe have it detect the sonos playbar âplayingâ and have it engaged. I am confused as to whether this is through the webCoRE or through an ST app?
still working on the code, but as of right now the engaged status does not have a timer the occupied status does have a timer.
heres how the logic goes:â
If contact changes to closed
set occupancy state to checking
if motion changes to active within timeout period
set occupancy state to engaged
else
set occupancy state to vacant
end if
end if
If contact changes to open
set occupancy state to checking
if motion changes to active within timeout period
set occupancy state to occupied
else
set occupancy state to vacant
end if
end if
so if the door is closed and there is one motion after that within the motion timeout period it sets the room to engaged which avoids using a timer. does that work?
right that is what i was thinking. the TV or the sonos âswitchâ being on could be used to control room is âenagagedâ and stop the other switches from turning off.
everything here is through the ST app in the first post though this does work with webcore if you needed to do additional tasks.
no you dont have to. you would just designate a switch which when turned on would change the room state to engaged and keep the lights from switching off.
if incorporated in a piston it shows up as a device with commands to set states and a occupancyState variable.
I installed the app using the github setup but there was only the Rooms Manager and Rooms Child App. I didnât see the Rooms occupancy and I donât see it in my ST My Apps. Am i missing something?
With that logic yes, that would work perfect depending on if there is a contact sensor AND the door is normally closed. Just donât see why it would just be occupied?
The problem with having something else set the engaged status and there is no contact sensor or the room is normally open is, If the TV is on or Music is playing that might not mean that it should forever. Once its set to engaged within the timeout period and the TV is on, seems like it needs to be an event to take it out of engaged? If no one is in the room, and the the rule states that this device should turn off after a period of time if the room is vacant then, from the logic, it will run foreverâŠ
If the TV/Sonos is âstoppedâ then it should take the room from engaged to vacant. Then the lights should turn off after there is no motion or after so much time.