These report their ON/OFF state via association group 2, through a Basic Set command. I guess it is possible (and maybe simple) to add a channel for this in the Z-wave database, but I am unsure how to do it?
I have managed to confirm this is working through code that parses the DEBUG log-file to trace these Basic Set - few other home automation softwares get this one right.
The mode (THERMOSTAT_MODE) tells the thermostat to be permanently off, or to employ its thermostat functions - which means: “activate the heating if it is cold”. Then if it is actually “cold” - below the setpoint - the thermostat will send a Basic Set to Association group 2 whenever the relay is activated (and power is actually drawn) and not.
I tried the latest snapshot (188.8.131.52806152142), but did not manage to find any extra channel (that would report the active state of the thermostat). Should an extra channel pop up by itself in Paper UI/Habmin? I also tried deleting the xml-file and let it be regenerated, but still I did not see any extra channel. If I need to exclude and reinclude, I will do that.
Got it - I deleted the thing and readded it, and saw the new channel called ‘Thermostat state’. But it is linked to switch_binary, which apparently is the functionality for turning the thermostat entirely off, or on (which also can be accomplished with the channel ‘Thermostat Mode’).
It is the message sent to association group 2 I would like to capture in a channel, which tells me whether there is power being drawn at the moment. Maybe it is difficult to get into a channel?
To be clear, the binding doesn’t know anything about association groups - only the commands it receives. When the device sends a command, there is no way to know why it sent the command - eg which association group might have caused it. Association groups are what the device uses to provide functionality only…
So, with that said, we did add a channel called “Thermostat State” a few months back - if this doesn’t work, then I would need to see logs to see what the binding is actually sending as this channel was linked to the basic command class as requested in the original request.
I am not able to state how it should be accomplished in the Z-wave database (or if it is even possible). But my log-file-parser looks for DEBUG statements like this:
2018-03-17 00:00:47.060 [DEBUG] [.commandclass.ZWaveBasicCommandClass] - NODE 5: Basic Set sent to the controller will be processed as Basic Report
2018-03-17 00:00:47.067 [DEBUG] [.commandclass.ZWaveBasicCommandClass] - NODE 5: Basic report, value = 0x00
where the “Basic Set” is the crucial point, and the value 0x00 is then picked up and interpreted as the thermostat being turned off.
From this it sounds like the thermostat reports when it is turned OFF (stops heating), but not when it is turned ON (heating starts)?
I am interested in this because I want to know the energy consumption on my non-energy-reporting thermostats. One solution might be to set up a recurring check that uses what we know (temperature, setpoint, hysteris), something along the lines of (pseudo code):
var powerConsumptionDiningRoom = 0.60 * 50 // watts * square meters for floor heating
var isOn = (heating_setpoint-temperature+hysteresis)>0
var currentConsumption = isOn*powerConsumptionDiningRoom
But I’m not sure if I want to have a lot of recurring rules running very often…
The thermostat is reporting both ON and OFF correctly (with Basic Set), the log excerpt is just an example.
In my case half of my thermostats do not have a floor sensor, and then there is no readout of measured temperature from the thermostat (it measures air internally, but refuses to send it over Z-wave as it is affected by internal heating inside the unit), and such a recurring check would not work at all. For the others, the check could work, but most likely with quite a bit of uncertainty.