Hublink with ST Fahrenheit & Centigrade bug

I've set up hublink to ST and connected a coupe of Aeotec Multi Sensors. HE thinks the data is coming in Fahrenheit from ST and is converting it to Centigrade based on my user settings. However the temperature data from ST is coming in centigrade so it does not need any converting. For example outside temp on ST dash states 9.1c and the Virtual device events log on HE states -12.72c (9.1f is -12.72c) On another sensor ST dash has 19.8c and the Virtual device events log on HE states -6.72c (19.8f is -6.72c).

Any chance of a bug fix?

The centigrade scale was known as such from 1743-1954. In 1948, the scale was renamed the Celsius scale

That is 71 years ago.

This is fitting wordgroup:

  • Cattywampus. ...
  • Gardyloo. ...
  • Taradiddle. ...
  • Snickersnee. ...
  • Widdershins. ...
  • Collywobbles. ...
  • Centigrade....

:joy::rofl: Hey, Jean Pierre Cristin would be proud of my gaffe !

Still need a Bug Fix. Any thoughts from the HE dev team on this one?

Ha, you know, I travelled around USA for 5 weeks in Dec/Jan, and as an Aussie, found myself saying centigrade. Dunno why. And it took me a while to figure out that I wasn't saying Celsius.

I had to google what the difference was, and there's no difference, apart from as you correctly point out, centigrade is >70 years old, and virtually no one refers to it. Also, I prefer Celsius.

You are right, that the Virtual Omni Sensor driver is doing an F to C conversion, and it should not be. We will look into a fix for that.

In the meantime, you could modify the code for Send Hub Events (the app on ST side) to convert C to F. Not as it should be, but would work until we get this sorted on our side.

This will be fixed in the next release.

Thanks @bravenel. I'm happy to do that but I think I need some help with the code on the ST side, my coding skills are pretty basic. I've reviewed the Send Hub Events code on ST IDE and scrolling through I can't see any obvious coding doing conversion to C, it seems to simply pass data through. If you can direct me I think I could do the mods

As a temporary measure I will set ST settings to F which will solve the Omni Sensor issue and then modify several webcore pistons (which I still use on ST side) to convert back from F to C.

One way or another I will work around until next release :grinning:

In Send Hub Events, on line 86 add this code:

def handleTempEvent(evt) {
	evt.value = (evt.value * 1.8) + 32

Change line 67 to this:

subscribe(multiSensors, "temperature", handleTempEvent)

You will want to revert these changes when you update to the next Hubitat release. Doing this will allow you to keep your ST system in °C and not change your pistons.

@bravenel you're a :star:. Many many thanks