PJCzx/homebridge-thermostat

Significant Variance in Temperatures in Home App

MacProDeveloper326 opened this issue · 3 comments

TargetTemperature, CurrentTemperature, TargetHeatingCoolingState, and CurrentHeatingCoolingState values are being logged properly to the console (with correct values), but the actual numbers in the Home app are not showing up correctly.

I'm still able to control my Proliphix ethernet thermostat with this if I monitor the screen on it while I do so (or watch the console output), but the reported values in the Home app are significantly off.

For example, I see in the console that the queried temperature from the thermostat is 72.0 degrees Fahrenheit, but the Home app reports 162 degrees Fahrenheit. The numbers displayed in the interval when sliding to adjust also are affected (I've set values 62.0 and 86.0 in my config.json for minTemp and maxTemp, but in the Home app they range from 144 to 187). Sliding to adjust the temperature still sends the correct values to the console, however (I just can't accurately tell what they are without checking). temperatureDisplayUnits in config.json is set to 1 (without quotes).

I am running the latest build of iOS 13 (the numbers are the same across all my devices, however, including a HomePod, iPad, and a couple Macs). homebridge-thermostat itself is running on Ubuntu 18.

Thanks in advance, and happy to help debug this!

PJCzx commented

Hello !

It have been a while I didn’t worked on the project, but can’t it be possible the default units are Celsius, and their is a confusion between units ?

Best

Hi there, I think you're definitely on to something since 72*(9/5)+32 = 162. Maybe it isn't taking my value of "1" for temperatureDisplayUnits? Need to figure out why that's the case (I've already played with all the unit selection options, including in the Home app). Guess worst case I could try implementing the conversation myself.

Cheers

Ok, I was mostly able to correct this by dropping the conversion formula in a few places. Definitely seems like the units flag in config.json is not working, however. Either way, I'm happy to have finally gotten my old Proliphix thermostat Siri-controlled.

Thanks!