OpenZWave / open-zwave

a C++ library to control Z-Wave Networks via a USB Z-Wave Controller.
http://www.openzwave.net/
GNU Lesser General Public License v3.0
1.05k stars 916 forks source link

Check Scale Encoding on SensorMultiLevel CC #2324

Open frankrosano opened 4 years ago

frankrosano commented 4 years ago

I recently migrated from the integrated HA OpenZWave distribution to this qt-openzwave container. Everything is running great, I'd say even better than the version integrated into HA, with the exception of this one odd issue I'm seeing with my thermostats which did not occur on OZW 1.4 in HA.

Upon startup of OZW, the thermostat reports Air Temperature in Celsius despite being configured to Fahrenheit locally. Cool and Heat setpoints report in F as expected. On top of this, the Air Temperature value only sends an update sporadically, with no discernable interval. I've seen comments elsewhere (in a SmartThings device handler I think) that this device requires to be polled (ugh...), so for kicks I even tried enabling polling on the Air Temperature value, but it continued to report in Celsius.

I captured a clean ozwdaemon.log of startup after I removed the ozwcache file, so it should show full device interrogation:

ozwdaemon.log

Nodes 3, 4, and 5 are all T6 Pro thermostats.

The only thing I'm seeing that is slightly suspicious is it appears to choose Celsius as the default scale:

[20200630 17:20:00.580 UTC] [ozw.library] [info]: Info - Node: 3 Sending (Send) message (Callback ID=0x66, Expected Reply=0x04) - SensorMultiLevelCmd_SupportedGetScale (Node=3): 0x01, 0x0a, 0x00, 0x13, 0x03, 0x03, 0x31, 0x03, 0x01, 0x25, 0x66, 0x96 
[20200630 17:20:00.624 UTC] [ozw.library] [info]: Info - Node: 3 Received SensorMultiLevel supported Scale report from node 3 for Sensor Air Temperature: C (0) 
[20200630 17:20:00.625 UTC] [ozw.library] [info]: Info - Node: 3 Received SensorMultiLevel supported Scale report from node 3 for Sensor Air Temperature: F (1) 
[20200630 17:20:00.626 UTC] [ozw.library] [info]: Info - Node: 3 Setting SensorMultiLevel Default Scale to: C (0) 

and then it reports the current temp in C a little later on:

[20200630 17:20:25.799 UTC] [ozw.library] [debug]: Detail - Node: 3 Queuing (Send) SensorMultilevelCmd_Get (Node=3): 0x01, 0x0b, 0x00, 0x13, 0x03, 0x04, 0x31, 0x04, 0x01, 0x00, 0x25, 0xa3, 0x52 
[20200630 17:20:25.805 UTC] [ozw.library] [info]: Info - Node: 3 Sending (Send) message (Callback ID=0xa3, Expected Reply=0x04) - SensorMultilevelCmd_Get (Node=3): 0x01, 0x0b, 0x00, 0x13, 0x03, 0x04, 0x31, 0x04, 0x01, 0x00, 0x25, 0xa3, 0x52 
[20200630 17:20:25.849 UTC] [ozw.library] [debug]: Detail - Node: 3   Received: 0x01, 0x0c, 0x00, 0x04, 0x00, 0x03, 0x06, 0x31, 0x05, 0x01, 0x22, 0x00, 0xdf, 0x3a 
[20200630 17:20:25.850 UTC] [ozw.library] [info]: Info - Node: 3 Response RTT 43 Average Response RTT 42 
[20200630 17:20:25.850 UTC] [ozw.library] [info]: Info - Node: 3 Received SensorMultiLevel report from node 3, instance 1, Air Temperature: value=22.3C 

Reason I think this is only slightly suspicious is that my Aeotec Multisensor (Node 7) initializes pretty much identically, setting default scale to C, however it reports temperature in F from the get-go...so this may or may not have any relevance to the issue.

Last bit of info I have to provide - if I go to the thermostat and manually adjust the setpoint, the air temperature will start reporting in F. It's still reported sporadically, but the next report that comes in after adjusting a setpoint manually is in F and Air Temperature remains in F for as long as OZW remains up. As soon as services are restarted again, the air temperature reverts to C and is stuck there until setpoint is adjusted again.

Please let me know if I can provide any further information to help troubleshoot.

frankrosano commented 4 years ago

Just following up with some logging to validate the behavior I described above. In this case an automation from HA kicked in and adjusted the thermostat setpoint:

[20200630 19:59:57.665 UTC] [ozw.library] [debug]: Detail - Node: 3 Refreshed Value: old value=72.0, new value=50.0, type=decimal
[20200630 19:59:57.672 UTC] [ozw.library] [debug]: Detail - Node: 3 Changes to this value are not verified
[20200630 19:59:57.679 UTC] [ozw.library] [info]: Info - Node: 3 Received thermostat setpoint report: Setpoint Cooling 1 = 50.0F

and as expected, the air temperature sensor updated shortly thereafter with the F value.

[20200630 20:03:47.687 UTC] [ozw.library] [debug]: Detail - Node: 3 Notification: ValueChanged CC: COMMAND_CLASS_SENSOR_MULTILEVEL Instance: 1 Index: 5
[20200630 20:03:54.478 UTC] [ozw.library] [debug]: Detail - Node: 3   Received: 0x01, 0x0c, 0x00, 0x04, 0x00, 0x03, 0x06, 0x31, 0x05, 0x01, 0x2a, 0x02, 0xcb, 0x24
[20200630 20:03:54.485 UTC] [ozw.library] [info]: Info - Node: 3 Received SensorMultiLevel report from node 3, instance 1, Air Temperature: value=71.5F
[20200630 20:03:54.492 UTC] [ozw.library] [debug]: Detail - Node: 3 Refreshed Value: old value=22.3, new value=71.5, type=decimal
[20200630 20:03:54.499 UTC] [ozw.library] [debug]: Detail - Node: 3 Changes to this value are not verified

Here is an updated copy of the ozwdaemon log containing all this activity as well:

ozwdaemon.log

Fishwaldo commented 4 years ago

1) So you should have a "\<sensorname> Units" for sensors that support multiple Scales. Set that to your preferred scale, and OZW will get that version when issuing a SensorMultilevelCmd_Get

2) For Unsolicited Reports - We can't specify what Scale we want (as its a unsolicited message - There is no SensorMultilevelCmd_Get - So the only way is usually via a configuration option on the device. What you are seeing in the second post is unsolicited - Hence its returning whatever it is configured as default to return.

frankrosano commented 4 years ago

Thanks for the reply!

  1. Prior to opening the issue I did mess with "Air Temperature Units" (which was set to Celsius by default), and manually changed to Fahrenheit. I just tried it again and noticed that OzwAdmin may not be updating this value when changed. I changed it in OzwAdmin, then checked the ozwcache file and it still shows Celsius as chosen. Here's a copy of the ozwcache file after making the change and stopping the OZW daemon:

ozwcache_0xdf2edbb4.xml.txt

I manually updated this to Fahrenheit by setting vindex to 1 (from 0), and started up the ozwdaemon. OZWAdmin now correctly shows Fahrenheit for the scale, but it seems the initial response from the SensorMultilevelCmd_Get is coming in Celsius:

[20200702 16:03:00.324 UTC] [ozw.library] [info]: Info - Node: 3 Sending (Send) message (Callback ID=0x2e, Expected Reply=0x04) - SensorMultilevelCmd_Get (Node=3): 0x01, 0x0b, 0x00, 0x13, 0x03, 0x04, 0x31, 0x04, 0x01, 0x01, 0x25, 0x2e, 0xde 
[20200702 16:03:00.325 UTC] [ozw.library] [info]: Info - Node: 3 Encrypted Flag is 0 
[20200702 16:03:00.334 UTC] [ozw.library] [debug]: Detail - Node: 3   Received: 0x01, 0x04, 0x01, 0x13, 0x01, 0xe8 
[20200702 16:03:00.335 UTC] [ozw.library] [debug]: Detail - Node: 3   ZW_SEND_DATA delivered to Z-Wave stack 
[20200702 16:03:00.349 UTC] [ozw.library] [debug]: Detail - Node: 3   Received: 0x01, 0x07, 0x00, 0x13, 0x2e, 0x00, 0x00, 0x02, 0xc7 
[20200702 16:03:00.350 UTC] [ozw.library] [debug]: Detail - Node: 3   ZW_SEND_DATA Request with callback ID 0x2e received (expected 0x2e) 
[20200702 16:03:00.351 UTC] [ozw.library] [info]: Info - Node: 3 Request RTT 24 Average Request RTT 24 
[20200702 16:03:00.351 UTC] [ozw.library] [debug]: Detail - Node: 3   Expected callbackId was received 
[20200702 16:03:00.368 UTC] [ozw.library] [debug]: Detail - Node: 3   Received: 0x01, 0x0c, 0x00, 0x04, 0x00, 0x03, 0x06, 0x31, 0x05, 0x01, 0x22, 0x00, 0xdc, 0x39 
[20200702 16:03:00.369 UTC] [ozw.library] [info]: Info - Node: 3 Response RTT 43 Average Response RTT 42 
[20200702 16:03:00.370 UTC] [ozw.library] [info]: Info - Node: 3 Received SensorMultiLevel report from node 3, instance 1, Air Temperature: value=22.0C 

Here's the full ozwdaemon log from the startup:

ozwdaemon.log

  1. Understood on the unsolicited reports, that's on the thermostat. My suspicion is that OZW is sending the initial SensorMultilevelCmd_Get request with units as Celsius, and then the t-stat continues to send reports in C until someone interacts with it, making it revert to the (correct) scale configured in the unit settings.
Fishwaldo commented 4 years ago

Decoding For my Reference...

From your output:

0x31, 0x04, 0x01, 0x01,

0x31 - SensorMultiLevel CC 0x04 - Get 0x01 - Air Temp 0x01 - In Fahrenheit

The Report we get back:

0x31, 0x05, 0x01, 0x22, 0x00

0x31 - SensorMultiLevel CC 0x05 - Report 0x01 - Air Temp 0x22 - 0b001|00|010 - Precision 1, Scale Celsius, size 2 0x00, 0xdc - 220 with Precision 1 equals 22.0

Fishwaldo commented 4 years ago

then checked the ozwcache file and it still shows Celsius as chosen.

The cache is only updated on certian events, and changing values is not one of these events, so you can not rely on it having "up to date values"

Fishwaldo commented 4 years ago

I've pushed a potential fix. Should be updated when the next ozwdaemon container is pushed out.

frankrosano commented 4 years ago

Good news! with a little bad news. But first the good news - on startup I am seeing Fahrenheit values reported off the bat. Logging to confirm:

2020-07-27 17:04:36.976866902  [20200727 17:04:36.976 UTC] [ozw.library] [info]: Info - Node: 14 Sending (Send) message (Callback ID=0x45, Expected Reply=0x04) - SensorMultilevelCmd_Get (Node=14): 0x01, 0x0b, 0x00, 0x13, 0x0e, 0x04, 0x31, 0x04, 0x01, 0x08, 0x25, 0x45, 0xb1 
2020-07-27 17:04:36.977350782  [20200727 17:04:36.976 UTC] [ozw.mqtt.publisher] [debug]: Publishing Event valueChanged: 249348116 
2020-07-27 17:04:36.977588269  [20200727 17:04:36.977 UTC] [ozw.library] [info]: Info - Node: 14 Encrypted Flag is 0 
2020-07-27 17:04:36.977921792  [20200727 17:04:36.977 UTC] [ozw.notifications] [debug]: Notification pvt_valueChanged:  281475226058769 Thread:  0x73c70010 
2020-07-27 17:04:36.985786667  [20200727 17:04:36.985 UTC] [ozw.mqtt.publisher] [debug]: Publishing Event valueChanged: 281475226058769 
2020-07-27 17:04:36.988234187  [20200727 17:04:36.986 UTC] [ozw.library] [debug]: Detail - Node: 14   Received: 0x01, 0x04, 0x01, 0x13, 0x01, 0xe8 
2020-07-27 17:04:36.989005446  [20200727 17:04:36.988 UTC] [ozw.library] [debug]: Detail - Node: 14   ZW_SEND_DATA delivered to Z-Wave stack 
2020-07-27 17:04:37.007176727  [20200727 17:04:37.006 UTC] [ozw.library] [debug]: Detail - Node: 14   Received: 0x01, 0x07, 0x00, 0x13, 0x45, 0x00, 0x00, 0x03, 0xad 
2020-07-27 17:04:37.007862418  [20200727 17:04:37.007 UTC] [ozw.library] [debug]: Detail - Node: 14   ZW_SEND_DATA Request with callback ID 0x45 received (expected 0x45) 
2020-07-27 17:04:37.008367494  [20200727 17:04:37.008 UTC] [ozw.library] [info]: Info - Node: 14 Request RTT 30 Average Request RTT 69 
2020-07-27 17:04:37.008795335  [20200727 17:04:37.008 UTC] [ozw.library] [debug]: Detail - Node: 14   Expected callbackId was received 
2020-07-27 17:04:37.041270611  [20200727 17:04:37.040 UTC] [ozw.library] [debug]: Detail - Node: 14   Received: 0x01, 0x0c, 0x00, 0x04, 0x00, 0x0e, 0x06, 0x31, 0x05, 0x01, 0x2a, 0x03, 0x16, 0xf5 
2020-07-27 17:04:37.041911253  [20200727 17:04:37.041 UTC] [ozw.library] [info]: Info - Node: 14 Response RTT 64 Average Response RTT 101 
2020-07-27 17:04:37.042453983  [20200727 17:04:37.042 UTC] [ozw.library] [info]: Info - Node: 14 Received SensorMultiLevel report from node 14, instance 1, Air Temperature: value=79.0F 

ozwdaemon_fahrenheit-unit.log

Now for the bad news. The "Air Temperature Units" are defaulting to Celsius, despite the thermostat being set (on the device itself) to report in Fahrenheit. Only after I went into the ozwcache and updated the Air Temperature Units to vindex=1 did I get the Fahrenheit value reported correctly. Here is logging from when I first started up, prior to changing the Air Temperature Units:

2020-07-27 16:48:02.622219343  [20200727 16:48:02.621 UTC] [ozw.library] [info]: Info - Node: 14 Sending (Send) message (Callback ID=0x45, Expected Reply=0x04) - SensorMultilevelCmd_Get (Node=14): 0x01, 0x0b, 0x00, 0x13, 0x0e, 0x04, 0x31, 0x04, 0x01, 0x00, 0x25, 0x45, 0xb9 
2020-07-27 16:48:02.623198716  [20200727 16:48:02.622 UTC] [ozw.library] [info]: Info - Node: 14 Encrypted Flag is 0 
2020-07-27 16:48:02.631013698  [20200727 16:48:02.630 UTC] [ozw.mqtt.publisher] [debug]: Publishing Event valueChanged: 281475226058769 
2020-07-27 16:48:02.632545800  [20200727 16:48:02.632 UTC] [ozw.library] [debug]: Detail - Node: 14   Received: 0x01, 0x04, 0x01, 0x13, 0x01, 0xe8 
2020-07-27 16:48:02.633587565  [20200727 16:48:02.633 UTC] [ozw.library] [debug]: Detail - Node: 14   ZW_SEND_DATA delivered to Z-Wave stack 
2020-07-27 16:48:02.652647338  [20200727 16:48:02.652 UTC] [ozw.library] [debug]: Detail - Node: 14   Received: 0x01, 0x07, 0x00, 0x13, 0x45, 0x00, 0x00, 0x03, 0xad 
2020-07-27 16:48:02.653652542  [20200727 16:48:02.653 UTC] [ozw.library] [debug]: Detail - Node: 14   ZW_SEND_DATA Request with callback ID 0x45 received (expected 0x45) 
2020-07-27 16:48:02.654404219  [20200727 16:48:02.654 UTC] [ozw.library] [info]: Info - Node: 14 Request RTT 30 Average Request RTT 70 
2020-07-27 16:48:02.655131158  [20200727 16:48:02.654 UTC] [ozw.library] [debug]: Detail - Node: 14   Expected callbackId was received 
2020-07-27 16:48:02.679096856  [20200727 16:48:02.678 UTC] [ozw.library] [debug]: Detail - Node: 14   Received: 0x01, 0x0c, 0x00, 0x04, 0x00, 0x0e, 0x06, 0x31, 0x05, 0x01, 0x22, 0x01, 0x09, 0xe0 
2020-07-27 16:48:02.680070812  [20200727 16:48:02.679 UTC] [ozw.library] [info]: Info - Node: 14 Response RTT 55 Average Response RTT 96 
2020-07-27 16:48:02.680872955  [20200727 16:48:02.680 UTC] [ozw.library] [info]: Info - Node: 14 Received SensorMultiLevel report from node 14, instance 1, Air Temperature: value=26.5C 

From your analysis before I see the request is asking for Celsius (0x31, 0x04, 0x01, 0x00), which isn't surprising since that's what the config was telling it to do.

Is it possible the "Air Temperature Units" value is being mis-interpreted when the device is queried? I've noticed that my other Aeotec multisensor (Node 7 in above log files) also shows Celsius for the air temp units, and on boot-up the SensorMultilevelCmd_Get is requesting the value in Celsius as well. Difference here is I have this sensor updating fairly frequently so it is overwritten with a Fahrenheit value before I notice anything is wrong.

If it helps, I just deleted my ozwcache and restarted the daemon. Here is logging to contain all the device querying and the new ozwcache file:

ozwdaemon_freshstart.log ozwcache_0xdf2edbb4.txt

joshtbernstein commented 4 years ago

The issue I was seeing seems to be resolved with https://github.com/OpenZWave/open-zwave/commit/21221b69b85f9e67921297e22812f6c8ad8adc2e. Also I do see that Air Temperature Units is set to C as @alterbridge86 noted, but for me the value is also reported in C.


OpenZWave/1/node/12/instance/1/commandclass/49/,{    "Instance": 1,    "CommandClassId": 49,    "CommandClass": "COMMAND_CLASS_SENSOR_MULTILEVEL",    "CommandClassVersion": 5,    "TimeStamp": 1596578733}
OpenZWave/1/node/12/instance/1/commandclass/49/value/281475183034386/,{    "Label": "Air Temperature",    "Value": 23.5,    "Units": "C",    "ValueSet": true,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "Decimal",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_SENSOR_MULTILEVEL",    "Index": 1,    "Node": 12,    "Genre": "User",    "Help": "Air Temperature Sensor Value",    "ValueIDKey": 281475183034386,    "ReadOnly": true,    "WriteOnly": false,    "Event": "valueChanged",    "TimeStamp": 1596578751}
OpenZWave/1/node/12/instance/1/commandclass/49/value/1407375089877010/,{    "Label": "Humidity",    "Value": 67.0,    "Units": "%",    "ValueSet": true,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "Decimal",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_SENSOR_MULTILEVEL",    "Index": 5,    "Node": 12,    "Genre": "User",    "Help": "Humidity Sensor Value",    "ValueIDKey": 1407375089877010,    "ReadOnly": true,    "WriteOnly": false,    "Event": "valueRefreshed",    "TimeStamp": 1596578751}
OpenZWave/1/node/12/instance/1/commandclass/49/value/72057594252640276/,{    "Label": "Air Temperature Units",    "Value": {        "List": [            {                "Value": 0,                "Label": "Celsius"            },            {                "Value": 1,                "Label": "Fahrenheit"            }        ],        "Selected": "Celsius",        "Selected_id": 0    },    "Units": "",    "ValueSet": false,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "List",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_SENSOR_MULTILEVEL",    "Index": 256,    "Node": 12,    "Genre": "System",    "Help": "Air Temperature Sensor Available Units",    "ValueIDKey": 72057594252640276,    "ReadOnly": false,    "WriteOnly": false,    "Event": "valueAdded",    "TimeStamp": 1596578733}
OpenZWave/1/node/12/instance/1/commandclass/49/value/73183494159482900/,{    "Label": "Humidity Units",    "Value": {        "List": [            {                "Value": 0,                "Label": "Percent"            }        ],        "Selected": "Percent",        "Selected_id": 0    },    "Units": "",    "ValueSet": false,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "List",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_SENSOR_MULTILEVEL",    "Index": 260,    "Node": 12,    "Genre": "System",    "Help": "Humidity Sensor Available Units",    "ValueIDKey": 73183494159482900,    "ReadOnly": false,    "WriteOnly": false,    "Event": "valueAdded",    "TimeStamp": 1596578733}
OpenZWave/1/node/12/instance/1/commandclass/64/,{    "Instance": 1,    "CommandClassId": 64,    "CommandClass": "COMMAND_CLASS_THERMOSTAT_MODE",    "CommandClassVersion": 3,    "TimeStamp": 1596578733}
OpenZWave/1/node/12/instance/1/commandclass/64/value/206569492/,{    "Label": "Mode",    "Value": {        "List": [            {                "Value": 0,                "Label": "Off"            },            {                "Value": 1,                "Label": "Heat"            },            {                "Value": 2,                "Label": "Cool"            },            {                "Value": 3,                "Label": "Auto"            },            {                "Value": 11,                "Label": "Heat Econ"            },            {                "Value": 12,                "Label": "Cool Econ"            }        ],        "Selected": "Auto",        "Selected_id": 3    },    "Units": "",    "ValueSet": true,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "List",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_THERMOSTAT_MODE",    "Index": 0,    "Node": 12,    "Genre": "User",    "Help": "Set the Thermostat Mode",    "ValueIDKey": 206569492,    "ReadOnly": false,    "WriteOnly": false,    "Event": "valueChanged",    "TimeStamp": 1596578751}
OpenZWave/1/node/12/instance/1/commandclass/66/,{    "Instance": 1,    "CommandClassId": 66,    "CommandClass": "COMMAND_CLASS_THERMOSTAT_OPERATING_STATE",    "CommandClassVersion": 1,    "TimeStamp": 1596578733}
OpenZWave/1/node/12/instance/1/commandclass/66/value/206602263/,{    "Label": "Operating State",    "Value": "Idle",    "Units": "",    "ValueSet": true,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "String",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_THERMOSTAT_OPERATING_STATE",    "Index": 0,    "Node": 12,    "Genre": "User",    "Help": "Set the Thermostat Operating State",    "ValueIDKey": 206602263,    "ReadOnly": true,    "WriteOnly": false,    "Event": "valueChanged",    "TimeStamp": 1596578751}
OpenZWave/1/node/12/instance/1/commandclass/67/,{    "Instance": 1,    "CommandClassId": 67,    "CommandClass": "COMMAND_CLASS_THERMOSTAT_SETPOINT",    "CommandClassVersion": 2,    "TimeStamp": 1596578733}
OpenZWave/1/node/12/instance/1/commandclass/67/value/281475183329298/,{    "Label": "Heating 1",    "Value": 65.0,    "Units": "F",    "ValueSet": true,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "Decimal",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_THERMOSTAT_SETPOINT",    "Index": 1,    "Node": 12,    "Genre": "User",    "Help": "Set the Thermostat Setpoint Heating 1",    "ValueIDKey": 281475183329298,    "ReadOnly": false,    "WriteOnly": false,    "Event": "valueChanged",    "TimeStamp": 1596578749}
OpenZWave/1/node/12/instance/1/commandclass/67/value/562950160039954/,{    "Label": "Cooling 1",    "Value": 76.0,    "Units": "F",    "ValueSet": true,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "Decimal",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_THERMOSTAT_SETPOINT",    "Index": 2,    "Node": 12,    "Genre": "User",    "Help": "Set the Thermostat Setpoint Cooling 1",    "ValueIDKey": 562950160039954,    "ReadOnly": false,    "WriteOnly": false,    "Event": "valueChanged",    "TimeStamp": 1596578749}
OpenZWave/1/node/12/instance/1/commandclass/67/value/1970325043593234/,{    "Label": "Furnace",    "Value": 0.0,    "Units": "C",    "ValueSet": false,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "Decimal",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_THERMOSTAT_SETPOINT",    "Index": 7,    "Node": 12,    "Genre": "User",    "Help": "Set the Thermostat Setpoint Furnace",    "ValueIDKey": 1970325043593234,    "ReadOnly": false,    "WriteOnly": false,    "Event": "valueAdded",    "TimeStamp": 1596578733}
OpenZWave/1/node/12/instance/1/commandclass/67/value/2251800020303890/,{    "Label": "Dry Air",    "Value": 0.0,    "Units": "C",    "ValueSet": false,    "ValuePolled": false,    "ChangeVerified": false,    "Min": 0,    "Max": 0,    "Type": "Decimal",    "Instance": 1,    "CommandClass": "COMMAND_CLASS_THERMOSTAT_SETPOINT",    "Index": 8,    "Node": 12,    "Genre": "User",    "Help": "Set the Thermostat Setpoint Dry Air",    "ValueIDKey": 2251800020303890,    "ReadOnly": false,    "WriteOnly": false,    "Event": "valueAdded",    "TimeStamp": 1596578733}```
Fishwaldo commented 4 years ago

Now for the bad news. The "Air Temperature Units" are defaulting to Celsius, despite the thermostat being set (on the device itself) to report in Fahrenheit.

Unfortunately there is no way to get the "scale" that is used on a device as its only transmitted as part of the actual temp reporting. That value is actually used only for specifying what unit we want in response to a GET and does not represent anything on the device itself.

So if you want to report F, then you need to ensure when you app starts, its always setting the units to F.

frankrosano commented 4 years ago

Ok that makes sense. So my final question - how can the app define a "default" scale for OZW? I'm using the qt-openzwave container with Home Assistant, I looked through all of the MQTT commands but don't see anything jumping out at me to define scale.