In this scenario I use a Aeon Labs Multisensor (4 in 1) measure the humidity. If it’s above the defined setpoint the amount of air extraction is raised until it goes below the setpoint (minus a defined hysteresis).
Except from the existence of excess moisture in the air in the bathroom, I can imagine occasions when the bathroom environment could benefit from some extra air exchange. (Without going into details…) That could probably be triggered by the motion sensor. I was thinking that a visit in the bathroom longer than 5 minutes would qualify for such an occasion. I would not like “short visits” to trigger any kind of action.
I need some advice from You experienced guys how to do this properly within PLEG. How do I destinguish a “short visit” in my bathroom from a “long visit” (using the motion sensor) and how can I extend my current PLEG implementation to include this? (The “motion timeout” on my sensor is set very low (5 secs) to allow repeated detections)
In this scenario I use a Aeon Labs Multisensor (4 in 1) measure the humidity. If it’s above the defined setpoint the amount of air extraction is raised until it goes below the setpoint (minus a defined hysteresis).
Except from the existence of excess moisture in the air in the bathroom, I can imagine occasions when the bathroom environment could benefit from some extra air exchange. (Without going into details…) That could probably be triggered by the motion sensor. I was thinking that a visit in the bathroom longer than 5 minutes would qualify for such an occasion. I would not like “short visits” to trigger any kind of action.
I need some advice from You experienced guys how to do this properly within PLEG. How do I destinguish a “short visit” in my bathroom from a “long visit” (using the motion sensor) and how can I extend my current PLEG implementation to include this? (The “motion timeout” on my sensor is set very low (5 secs) to allow repeated detections)
Here is the current implementaion:[/quote]
Not sure why you have Fanoff condition. You can use one input for “FanOn” and then in conditions you can use “FanOn” or “!FanOn” for either on or off.
I like to tie in a door sensor to trigger 5 min after door has been closed. For long visits, which could be a shower or the other. A motion sensor could keep resetting if you just say 5 min, after motion went off.
You may want to do the require(“myvariables.lua”) in the Startup LUA for the PLEG.
Then your LUA code for each action would only call setMultiSwitch with the appropriate args.
This will save some memory and speed up actions.
You have a forward reference to FanOff (i.e. the condition is the 5th condition, but it is reference in the 2nd and 4th condition). This means that they are always using the PREVIOUS value for FanOff. You should either move that condition to the TOP (that’s what the + and - buttons do in the condition tab) or as @integlikewhoa indicated … delete that condition all together and replace your references to FanOff with !FanOn
Also post your status reports in PDF … they are easier to read. Also you do not need to cover your license … It will only work on your Vera.
[quote=“RichardTSchaefer, post:3, topic:181228”]You may want to do the require(“myvariables.lua”) in the Startup LUA for the PLEG.
Then your LUA code for each action would only call setMultiSwitch with the appropriate args.
This will save some memory and speed up actions.
You have a forward reference to FanOff (i.e. the condition is the 5th condition, but it is reference in the 2nd and 4th condition). This means that they are always using the PREVIOUS value for FanOff. You should either move that condition to the TOP (that’s what the + and - buttons do in the condition tab) or as @integlikewhoa indicated … delete that condition all together and replace your references to FanOff with !FanOn
Also post your status reports in PDF … they are easier to read. Also you do not need to cover your license … It will only work on your Vera.[/quote]
Thanks a lot. I’ve taken actions on all of your suggestions. It’s a great feature that I can specify a startup script for each PLEG device. I’ve done that now and it works just fine.
When a motion is detected I’d have to determine if it’s a new visit or just a repeated detection during one visit. If it’s within let’s say 3 minutes from the previous motion detected it should be considered a single visit and I would like to elongate the time before the fan turns off. I guess I must keep track of the timestamp of the first detection of the visit then but I’m not sure about how to implement it. I think I’ve seen a similar implementation somewhere but I can’t seem to find it again. So if you or someone else has any ideas…
Best Home Automation shopping experience. Shop at Ezlo!