Hello! I’m a complete novice with Home Assistant, on day three- I’ve successfully paired some light switches with motion detection, and still getting used to my new hobby.
I’m trying to create an automation for a bathroom fan that’s controlled by a Z Wave in-wall switch, but no matter how simple I make the automation it seems like HA does not register the value of the humidity sensor (ZOOZ Z-Wave Plus 4-in-1 Sensor ZSE40 VER. 2.0). The motion sensor for the device does work without issue, and I can see the values from the sensor in the entity details.
I feel like there must be something simple that I’m overlooking, any advice would be appreciated, here’s the simplest version of what I’m trying to achieve:
Can you clarify, do you mean that you don’t see the humidity sensor reporting any values, or do you mean that the sensor goes above 50, but does not trigger the automation?
Couple things to test if you haven’t. First, you can test the action and make sure that part is working. Just click on the automation “i” symbol, and then click the “TRIGGER” button. If the fan turns on, then you know the action is correct. Second, from the Developer Tools → State page, you can temporarily override the state value for the sensor. Choose the entity in the Entity picker, then change the State value, then click the “SET STATE” button. If the current humidity is less than 50, and you set it over 50, it should trigger the automation. You can examine the Logbook to see if it was ever triggered.
Thank you so much for your fast response! I did mean that the sensor goes above 50 but does not trigger the automation.
BUT, just as I was reading your reply and working out my response the automation triggered (without an override), could it be that using the numeric_state trigger doesn’t work until the sensor wakes up and changes the value? That could certainly be the fundamental issue I didn’t know about.
The numeric_state trigger (like many triggers) is only “processed” when the referenced entity (or one of the referenced entities, if more than one is specified) changes. The first time it changes and the specified criteria is met (in this case, it’s above 50), the trigger will “fire.” After it fires the first time, it will not fire again until the criteria is first not met (in this case, becomes 50 or less), and then is met again.
And, BTW, although typically you wouldn’t quote the value, it doesn’t really matter. The string '50' will be “coerced” into the float value of 50.0.
You can adjust the percent change on the device though, according to the manual. Parameter 3 defaults to reporting 10% changes in humidity, you can lower that.
That is probably worth changing. Of course, the trade-off is, the more often it sends updates the quicker the battery will need to be replaced. I have one of these sensors, and in my case, I care more about light levels and I changed it’s % from the default of 10 down to 5.
Another thing you can do is to enhance the automation so it will turn the switch on when HA starts if the sensor is already above 50. You’d do that like this: