Bathroom Humidity Fan

I agree, more frequent is probably better, I just need to stop it from creating so many run-in threads. I checked and mine created 9 of those this morning, yours could be way worse.

1 Like

I updated my GIT with what I will test when I get home tonight. If you are brave, you can try it out.

I'm at work now, so I'll wait for you to test.

I tried using this as well, but it didn't shut off my fan a couple times and made system sluggish. Ended up doing this simple piston in Webcore

How often does your humidity sensor have events? I'm wondering if having too many runin's going.

Im not sure if you are talking to me or @halfrican.ak , But I believe we are both using the same USB powered multisensors 6. Mine is also using the selective reporting every time humidity changes one percent.

Thanks, I'm using battery, so I'm betting the higher reporting was getting the code to spawn too many running. We'll see after I test and then someone else on USB tests.

Did you get a chance to test the new code? Is it ready for "prime time"? I'd like to try it out again if you think it's good to go.

It looks good, only one runin called at a time. Let me know. Good choice on waiting, found some logic mistakes.

Ok, I reinstalled. So far looks good, haven't had a chance to "really" test it since I'm at work now. One thing I did notice is it was evaluating frequently even without the shower running. I think it had to do with me setting the Aeotec to report 1% change. I kicked it up to 2% change and now I'm not seeing the frequent logging. I'm guessing 1% is just too sensitive to matter?

I live in AZ, so I have it report if it sees 1% change limited to every 5 min, and my limit for turning on the fan is 2%. I look forward to hearing how it works, or what changes are needed.
Thanks!

I noticed my sensor was noting changes of 1% +/- every 30 seconds (USB Powered) so that was causing the app to reevaluate each time. Since a change of 1% is probably neglible I decided to change the sensors parameter to only report changes of 2%. I'm no longer seeing the constant reevaluating and I would assume the lower zwave traffic isn't a bad thing either?

I live in Anchorage, Alaska we generally low humidity compared to some parts of Alaska.

@napalmcsr seeing some strange results since re-install using latest code.

Logs for app:

app:19602018-06-01 14:14:18.907:infoHumidityHandler: FanSwitch.currentValue = on
app:19602018-06-01 14:14:18.897:infoHumidityHandler: state.TurnOffLaterStarted = false
app:19602018-06-01 14:14:18.896:infoHumidityHandler: state.AutomaticallyTurnedOn = true
app:19602018-06-01 14:14:18.894:infoHumidityHandler: humidity = true
app:19602018-06-01 14:14:18.893:debugIsHumidityPresent: humidity rate above incrate
app:19602018-06-01 14:14:18.891:debugIsHumidityPresent: states date is true
app:19602018-06-01 14:14:18.878:debugIsHumidityPresent: states date is true
app:19602018-06-01 14:14:18.845:debugIsHumidityPresent: states is true
app:19602018-06-01 14:14:18.843:debugIsHumidityPresent: humidity: 49
app:19602018-06-01 14:14:18.842:debugIsHumidityPresent: humidity: 51
app:19602018-06-01 14:14:18.840:debugIsHumidityPresent: numStates is 2
app:19602018-06-01 14:14:17.823:infoHumidityHandler:running humidity check
app:19602018-06-01 14:12:39.971:infoFanSwitchHandler: ManualControlMode = After Set Time
app:19602018-06-01 14:12:39.970:infoFanSwitchHandler::Switch changed
app:19602018-06-01 14:12:39.840:debugHumidityHandler:Fan On
app:19602018-06-01 14:12:39.839:infoHumidityHandler: FanSwitch.currentValue = off
app:19602018-06-01 14:12:39.830:infoHumidityHandler: state.TurnOffLaterStarted = false
app:19602018-06-01 14:12:39.829:infoHumidityHandler: state.AutomaticallyTurnedOn = false
app:19602018-06-01 14:12:39.828:infoHumidityHandler: humidity = true
app:19602018-06-01 14:12:39.827:debugIsHumidityPresent: humidity rate above incrate
app:19602018-06-01 14:12:39.822:debugIsHumidityPresent: states date is true
app:19602018-06-01 14:12:39.821:debugIsHumidityPresent: states date is true
app:19602018-06-01 14:12:39.819:debugIsHumidityPresent: states is true
app:19602018-06-01 14:12:39.818:debugIsHumidityPresent: humidity: 47
app:19602018-06-01 14:12:39.817:debugIsHumidityPresent: humidity: 49
app:19602018-06-01 14:12:39.815:debugIsHumidityPresent: numStates is 2
app:19602018-06-01 14:12:37.949:infoHumidityHandler:running humidity check
app:19602018-06-01 14:12:03.734:infoFanSwitchHandler::Switch turned off
app:19602018-06-01 14:12:03.733:infoFanSwitchHandler: ManualControlMode = After Set Time
app:19602018-06-01 14:12:03.731:infoFanSwitchHandler::Switch changed
app:19602018-06-01 14:12:03.653:debugTurnOffFanSwitch:Fan Off
app:19602018-06-01 14:11:18.765:infoFanSwitchHandler: ManualControlMode = After Set Time
app:19602018-06-01 14:11:18.763:infoFanSwitchHandler::Switch changed
app:19602018-06-01 14:11:18.686:debugHumidityHandler:Fan On
app:19602018-06-01 14:11:18.685:infoHumidityHandler: FanSwitch.currentValue = off
app:19602018-06-01 14:11:18.677:infoHumidityHandler: state.TurnOffLaterStarted = false
app:19602018-06-01 14:11:18.676:infoHumidityHandler: state.AutomaticallyTurnedOn = false
app:19602018-06-01 14:11:18.675:infoHumidityHandler: humidity = true
app:19602018-06-01 14:11:18.674:debugIsHumidityPresent: humidity rate above incrate
app:19602018-06-01 14:11:18.673:debugIsHumidityPresent: states date is true
app:19602018-06-01 14:11:18.667:debugIsHumidityPresent: states date is true
app:19602018-06-01 14:11:18.666:debugIsHumidityPresent: states is true
app:19602018-06-01 14:11:18.665:debugIsHumidityPresent: humidity: 45
app:19602018-06-01 14:11:18.664:debugIsHumidityPresent: humidity: 47
app:19602018-06-01 14:11:18.663:debugIsHumidityPresent: numStates is 2
app:19602018-06-01 14:11:17.650:infoHumidityHandler:running humidity check
app:19602018-06-01 14:10:08.607:infoHumidityHandler: FanSwitch.currentValue = off
app:19602018-06-01 14:10:08.596:infoHumidityHandler: state.TurnOffLaterStarted = false
app:19602018-06-01 14:10:08.594:infoHumidityHandler: state.AutomaticallyTurnedOn = false
app:19602018-06-01 14:10:08.593:infoHumidityHandler: humidity = false
app:19602018-06-01 14:10:08.592:debugIsHumidityPresent: returning false
app:19602018-06-01 14:10:08.590:debugIsHumidityPresent: states date is true
app:19602018-06-01 14:10:08.557:debugIsHumidityPresent: states is true
app:19602018-06-01 14:10:08.555:debugIsHumidityPresent: humidity: 45
app:19602018-06-01 14:10:08.553:debugIsHumidityPresent: numStates is 1
app:19602018-06-01 14:10:07.468:infoHumidityHandler:running humidity check
app:19602018-06-01 13:57:07.817:infoHumidityHandler: FanSwitch.currentValue = off
app:19602018-06-01 13:57:07.802:infoHumidityHandler: state.TurnOffLaterStarted = false
app:19602018-06-01 13:57:07.801:infoHumidityHandler: state.AutomaticallyTurnedOn = false
app:19602018-06-01 13:57:07.799:infoHumidityHandler: humidity = false
app:19602018-06-01 13:57:07.798:debugIsHumidityPresent: returning false
app:19602018-06-01 13:57:07.796:debugIsHumidityPresent: states date is true
app:19602018-06-01 13:57:07.783:debugIsHumidityPresent: states is true
app:19602018-06-01 13:57:07.782:debugIsHumidityPresent: humidity: 43
app:19602018-06-01 13:57:07.780:debugIsHumidityPresent: numStates is 1
app:19602018-06-01 13:57:06.698:infoHumidityHandler:running humidity check
app:19602018-06-01 13:52:20.809:infoFanSwitchHandler::Switch turned off
app:19602018-06-01 13:52:20.808:infoFanSwitchHandler: ManualControlMode = After Set Time
app:19602018-06-01 13:52:20.807:infoFanSwitchHandler::Switch changed
app:19602018-06-01 13:52:03.615:infoFanSwitchHandler::Will turn off later
app:19602018-06-01 13:52:03.611:infoFanSwitchHandler: ManualControlMode = After Set Time
app:19602018-06-01 13:52:03.610:infoFanSwitchHandler::Switch changed

Log for fan:

dev:10142018-06-01 14:12:40.024:infoMaster Bathroom - Exhaust Fan was turned on
dev:10142018-06-01 14:12:39.912:infoMaster Bathroom - Exhaust Fan was turned on
dev:10142018-06-01 14:12:03.832:infoMaster Bathroom - Exhaust Fan was turned off
dev:10142018-06-01 14:12:03.703:infoMaster Bathroom - Exhaust Fan was turned off
dev:10142018-06-01 14:11:18.778:infoMaster Bathroom - Exhaust Fan was turned on
dev:10142018-06-01 14:11:18.725:infoMaster Bathroom - Exhaust Fan was turned on
dev:10142018-06-01 13:52:20.877:infoMaster Bathroom - Exhaust Fan was turned off
dev:10142018-06-01 13:52:20.843:infoMaster Bathroom - Exhaust Fan was turned off
dev:10142018-06-01 13:52:20.824:infoMaster Bathroom - Exhaust Fan was turned off
dev:10142018-06-01 13:52:20.765:infoMaster Bathroom - Exhaust Fan was turned off
dev:10142018-06-01 13:52:03.704:infoMaster Bathroom - Exhaust Fan was turned on
dev:10142018-06-01 13:52:03.663:infoMaster Bathroom - Exhaust Fan was turned on
dev:10142018-06-01 13:52:03.640:infoMaster Bathroom - Exhaust Fan was turned on
dev:10142018-06-01 13:52:03.565:infoMaster Bathroom - Exhaust Fan was turned on

Log for sensor:

dev:10432018-06-01 14:17:04.352:debugNotificationReport: NotificationReport(v1AlarmType:0, v1AlarmLevel:0, reserved:0, notificationStatus:255, notificationType:7, event:0, sequence:false, eventParametersLength:0, eventParameter:[])
dev:10432018-06-01 14:17:04.032:debugBasicSet: BasicSet(value:0)
dev:10432018-06-01 14:16:24.339:debugNotificationReport: NotificationReport(v1AlarmType:0, v1AlarmLevel:0, reserved:0, notificationStatus:255, notificationType:7, event:8, sequence:false, eventParametersLength:0, eventParameter:[])
dev:10432018-06-01 14:16:24.036:debugBasicSet: BasicSet(value:255)
dev:10432018-06-01 14:16:17.988:debugHumidity Report: 53
dev:10432018-06-01 14:14:17.637:debugHumidity Report: 51
dev:10432018-06-01 14:12:37.537:debugHumidity Report: 49
dev:10432018-06-01 14:11:17.508:debugHumidity Report: 47
dev:10432018-06-01 14:11:17.473:debugHumidity Report: 47
dev:10432018-06-01 14:10:07.343:debugHumidity Report: 45
dev:10432018-06-01 14:09:13.821:debugNotificationReport: NotificationReport(v1AlarmType:0, v1AlarmLevel:0, reserved:0, notificationStatus:255, notificationType:7, event:0, sequence:false, eventParametersLength:0, eventParameter:[])
dev:10432018-06-01 14:09:13.520:debugBasicSet: BasicSet(value:0)
dev:10432018-06-01 14:08:38.088:debugIlluminance Report: 78
dev:10432018-06-01 14:08:28.832:debugNotificationReport: NotificationReport(v1AlarmType:0, v1AlarmLevel:0, reserved:0, notificationStatus:255, notificationType:7, event:8, sequence:false, eventParametersLength:0, eventParameter:[])
dev:10432018-06-01 14:08:28.498:debugBasicSet: BasicSet(value:255)
dev:10432018-06-01 13:57:06.520:debugHumidity Report: 43
dev:10432018-06-01 13:54:37.356:debugNo commands to send
dev:10432018-06-01 13:54:37.305:debugDevice Master Bathroom - Motion woke up

Seems like app is turning fan on/off repeatedly?

I added additional debug code, It looks like when it turns on it is getting a race condition with the switch handler which is automatically turning it off. the debug lines will tell me.

ok, I'm re-installing now, will post logs soon.

I just tried turning the switch on manually, and noticed that it appears to have logged 4 responses to the ON command. I activated this remotely using dashboard. Perhaps this actually an issue with Lutron Integration?

[dev:1014]2018-06-01 16:23:54.292:infoMaster Bathroom - Exhaust Fan was turned on

[dev:1014])2018-06-01 16:23:54.257:infoMaster Bathroom - Exhaust Fan was turned on

[dev:1014]2018-06-01 16:23:54.225:infoMaster Bathroom - Exhaust Fan was turned on

[dev:1014]2018-06-01 16:23:54.063:infoMaster Bathroom - Exhaust Fan was turned on

edit: same result when I turned it off with dashboard, 4 OFF responses.

edit 2: I checked all of my other lutron dimmers, they are only showing a single response to RM commands. However I noticed that if I turn them on/off using dashboard tile I'm getting multiple responses.

Here is what mine looks like now

app:462018-06-01 17:31:11.175:infoHumidityHandler: state.AutomaticallyTurnedOn = true
app:462018-06-01 17:31:11.173:infoFanSwitchHandler: ManualOffMinutes = 25
app:462018-06-01 17:31:11.172:infoFanSwitchHandler: ManualControlMode = After Set Time
app:462018-06-01 17:31:11.171:infoFanSwitchHandler::Switch changed
app:462018-06-01 17:31:11.131:debugHumidityHandler:Fan On
app:462018-06-01 17:31:11.130:infoHumidityHandler: FanSwitch.currentValue = off
app:462018-06-01 17:31:11.127:infoHumidityHandler: state.TurnOffLaterStarted = false
app:462018-06-01 17:31:11.126:infoHumidityHandler: state.AutomaticallyTurnedOn = false
app:462018-06-01 17:31:11.125:infoHumidityHandler: humidity = true

[app:1967])2018-06-01 16:27:30.454:infoFanSwitchHandler::Switch turned off

[app:1967])2018-06-01 16:27:30.448:infoHumidityHandler: state.AutomaticallyTurnedOn = false

[app:1967])2018-06-01 16:27:30.445:infoFanSwitchHandler: ManualOffMinutes = 20

[app:1967]2018-06-01 16:27:30.444:infoFanSwitchHandler: ManualControlMode = After Set Time

[app:1967]2018-06-01 16:27:30.443:infoFanSwitchHandler::Switch changed

[app:1967]2018-06-01 16:23:54.219:infoFanSwitchHandler::Will turn off later

[app:1967]2018-06-01 16:23:54.216:infoHumidityHandler: state.AutomaticallyTurnedOn = false

[app:1967]2018-06-01 16:23:54.210:infoFanSwitchHandler: ManualOffMinutes = 20

[app:1967]2018-06-01 16:23:54.209:infoFanSwitchHandler: ManualControlMode = After Set Time

[app:1967]2018-06-01 16:23:54.208:infoFanSwitchHandler::Switch changed

Looks consistent with what I'm seeing, if the coding such that it's ignoring the multiple responses i'm seeing in the logs?

This should be true if the humidity turned it on until the switch is turned off, that is what is bothering me...

and that variable is what makes it ignore the turn on until it is turned off manually or automatically.