Hi everyone,
I’ve plugged this https://www.amazon.de/gp/product/B00PF0ZS8E between my wall socket and my dryer. I’m aiming at switching off the socket as soon as the measured power consumption falls below a certain threshold. I have the items set up as following:
Group Grp_UtilityRoom_Dryer_Socket "Trockner" <socket> (Grp_Sockets,Grp_Socket_GroundFloor,Grp_Socket_GF_UtilityRoom,GF_UtilityRoom)
Switch Dryer "Status" <socket> (Grp_UtilityRoom_Dryer_Socket) {zwave="2:command=switch_binary" }
Number Dryer_Power "Leistung [%.2f W]" (Grp_UtilityRoom_Dryer_Socket) {zwave="2:command=meter,meter_scale=E_W"}
Number Dryer_Volts "Spannung [%.2f V]" (Grp_UtilityRoom_Dryer_Socket) {zwave="2:command=meter,meter_scale=E_V"}
Number Dryer_Amps "Stromstärke [%.2f A]" (Grp_UtilityRoom_Dryer_Socket) {zwave="2:command=meter,meter_scale=E_A"}
Number Dryer_Energy "Arbeit [%.2f KWh]" (Grp_UtilityRoom_Dryer_Socket) {zwave="2:command=meter,meter_scale=E_KWh" }
I can see the state changes during a dryer’s run in the UI as well as in the log files, e.g. in events.log:
2016-09-06 22:21:33 - Dryer_Power state updated to 0.93
2016-09-06 22:21:36 - Dryer_Power state updated to 0.988
2016-09-06 22:21:39 - Dryer_Power state updated to 1.053
2016-09-06 22:21:42 - Dryer_Power state updated to 0.906
2016-09-06 22:22:12 - Dryer_Power state updated to 0.851
2016-09-06 22:22:15 - Dryer_Power state updated to 1.004
2016-09-06 22:22:18 - Dryer_Power state updated to 0.834
2016-09-06 22:22:21 - Dryer_Power state updated to 1.033
2016-09-06 22:22:27 - Dryer_Power state updated to 1.112
2016-09-06 22:22:30 - Dryer_Power state updated to 0
However, for some mysterious reason I do not seem to be able to trigger actions upon these state changes from within a rule.
I have created a file Sockets.rules within the rules folder and (for testing purposes) set it up as following:
rule "dryer auto off"
when
Item Dryer_Power received update
then
sendCommand(Dryer, OFF)
end
From my understanding, it couldn’t be any simplier - Switch off the dryer when the power consumption changes. I’ve walked to my dryer a hundred times now switching it off and on again, but the dryer was never switched off automatically via the rule. I can trigger the dryer dying via the UI, so I’d guess the root of all evil residing somewhere within the “when” condition, but I cannot figure out where’s the mistake.
openhab.log doesn’t show up anything necessary at all, so I’m quite lost here and would very much appreciate some help on this.
In case I can deliver any further information, please let me know.
Many thanks in advance for your assistance!
Best regards