Honeywell home thermostat Binding

This binding is used to connect your HoneywellHome (only T5/T6 thermostat for now) using the official HoneywellHome Api.

Please take a look at the Github Repository readme file for integration details.

Changelog

Version 3.0.3

Coming soon… (Improving API integration to avoid HoneywellHome rate limiter issue)

Resources

Release versions are available here.

Source code available here.

3 Likes

Just a few minor things of note. They are not a big deal just yet except for one thing.

The template that comes up when you initially create this post is no optional. It’s that template that tells MainUI how to process the post and most importantly, where to get the jar file. As it’s currently formatted, the add-on cannot be installed through MainUI.

I think the problem is the URL doesn’t lead directly to the jar file. It’s not enough to just link to the releases page. You have to actually point to the actual download. You’ll need to use https://github.com/idanudel/openhab-honeywellhome/releases/download/v3.0.2/org.openhab.binding.honeywellhome-3.0.2.jar

If that doesn’t work, the problem might also be the text you’ve put before the links under Resources. I think it expects either a naked URL or the entire line to be a link.

Note, I’ve had a few minutes to play around today and was able to successfully get my bridge Thing online and my thermostat discovered. Lots of great Channels are already available. :partying_face:

Update: I tried to link all the Channels to Items and encountered the following problems:

  • No matter what I tried it said that the name I choose for the Displayed Humidity Channel’s Item it threw an error that the name was invalid.

  • After linking I got a bunch of the following log entries:

    2023-07-05 15:10:10.389 [INFO ] [l.handler.HoneywellThermostatHandler] - Starting Honeywell Thermostat Refresh Task with refresh interval: 20

  • That was followed by four instances of this exception:

2023-07-05 15:10:11.960 [WARN ] [mmon.WrappedScheduledExecutorService] - Scheduled runnable ended with an exception:
java.lang.NoSuchMethodError: 'void org.openhab.core.library.types.DecimalType.<init>(long)'
        at org.openhab.binding.honeywellhome.internal.handler.HoneywellThermostatHandler.update(HoneywellThermostatHandler.java:140) ~[?:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[?:?]
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) ~[?:?]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) ~[?:?]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
        at java.lang.Thread.run(Thread.java:833) ~[?:?]
  • All of my Items are coming up NULL, even after waiting for hours.

  • During a restart I’m seeing the following exception

20│java.lang.NoClassDefFoundError: org/openhab/binding/honeywellhome/client/HoneywellClient                                                                                                      │
20│        at org.openhab.binding.honeywellhome.internal.handler.HoneywellHomeHandler.lambda$0(HoneywellHomeHandler.java:74) ~[?:?]                                                              │
20│        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[?:?]                                                                                                     │
20│        at java.util.concurrent.FutureTask.run(FutureTask.java:264) ~[?:?]                                                                                                                    │
20│        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) ~[?:?]                                                              │
20│        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]                                                                                             │
00│        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]                                                                                             │2520│        at java.lang.Thread.run(Thread.java:833) ~[?:?]                                                                                                                                       │
20│Caused by: java.lang.ClassNotFoundException: org.openhab.binding.honeywellhome.client.HoneywellClient cannot be found by org.openhab.binding.honeywellhome_3.0.2                              │
20│        at org.eclipse.osgi.internal.loader.BundleLoader.generateException(BundleLoader.java:541) ~[org.eclipse.osgi-3.18.0.jar:?]                                                            │
20│        at org.eclipse.osgi.internal.loader.BundleLoader.findClass0(BundleLoader.java:536) ~[org.eclipse.osgi-3.18.0.jar:?]                                                                   │
20│        at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:416) ~[org.eclipse.osgi-3.18.0.jar:?]                                                                    │
20│        at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:168) ~[org.eclipse.osgi-3.18.0.jar:?]                                                          │
20│        at java.lang.ClassLoader.loadClass(ClassLoader.java:520) ~[?:?]                                                                                                                       │
20│        ... 7 more                                                                                                                                                                            │

What is your openhab version?
I’m a little bit busy lately but I will get to it soon.

Meanwhile can you please run Get thermostat call (via postman or curl command)?

Or enable debug for this binding and post the response?
(I put the response from Honeywell in debug log level).
Let’s see what object type you get there… (guess I need to add null check)

OH 4.0 snapshot build 3525 (upgraded just weekend).

I’ll try to post since logs later today. If not I’ll get back on Monday.

Sorry for the delay.

I put the binding into debug mode and I assume you want to see the JSON returned by the device, right?

{
  "displayedOutdoorHumidity": 20,
  "vacationHold": {
    "enabled": false
  },
  "currentSchedulePeriod": {
    "day": "Monday",
    "period": "Away"
  },
  "scheduleCapabilities": {
    "availableScheduleTypes": [
      "None",
      "Geofenced",
      "TimedNorthAmerica"
    ],
    "schedulableFan": false
  },
  "scheduleType": {
    "scheduleType": "Timed",
    "scheduleSubType": "NA"
  },
  "changeSource": {
    "by": "partner",
    "name": "Amazon Alexa"
  },
  "scheduleStatus": "Resume",
  "allowedTimeIncrements": 15,
  "settings": {
    "hardwareSettings": {
      "brightness": 1,
      "maxBrightness": 5
    },
    "fan": {
      "allowedModes": [
        "On",
        "Auto",
        "Circulate"
      ],
      "changeableValues": {
        "mode": "On"
      }
    },
    "temperatureMode": {
      "air": false
    },
    "specialMode": null,
    "devicePairingEnabled": true
  },
  "deviceOsVersion": "TH6220WF2006",
  "deviceClass": "Thermostat",
  "deviceType": "Thermostat",
  "deviceID": "LCC-B82CA07C9CB5",
  "deviceInternalID": 2350782,
  "userDefinedDeviceName": "Thermostat",
  "name": "Thermostat",
  "isAlive": true,
  "isUpgrading": false,
  "isProvisioned": true,
  "macID": "B82CA07C9CB5",
  "deviceSettings": null,
  "service": {
    "mode": "Up"
  },
  "deviceRegistrationDate": "2020-07-31T22:37:43.1066667",
  "dataSyncStatus": "Completed",
  "deviceSerialNo": "1949LBJ58399",
  "units": "Fahrenheit",
  "indoorTemperature": 68,
  "outdoorTemperature": 86,
  "allowedModes": [
    "Heat",
    "Off",
    "Cool"
  ],
  "deadband": 0,
  "hasDualSetpointStatus": false,
  "minHeatSetpoint": 50,
  "maxHeatSetpoint": 90,
  "minCoolSetpoint": 50,
  "maxCoolSetpoint": 90,
  "changeableValues": {
    "mode": "Cool",
    "heatSetpoint": 65,
    "coolSetpoint": 68,
    "thermostatSetpointStatus": "PermanentHold",
    "nextPeriodTime": "18:00:00",
    "endHeatSetpoint": 65,
    "endCoolSetpoint": 68,
    "heatCoolMode": "Cool"
  },
  "operationStatus": {
    "mode": "Cool",
    "fanRequest": true,
    "circulationFanRequest": false
  },
  "deviceModel": "T5-T6"
}

The next line in the log is the error.

2023-07-13 12:20:16.626 [WARN ] [mmon.WrappedScheduledExecutorService] - Scheduled runnable ended with an exception:
java.lang.NoSuchMethodError: 'void org.openhab.core.library.types.DecimalType.<init>(long)'
        at org.openhab.binding.honeywellhome.internal.handler.HoneywellThermostatHandler.update(HoneywellThermostatHandler.java:140) ~[?:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[?:?]
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) ~[?:?]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) ~[?:?]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
        at java.lang.Thread.run(Thread.java:833) ~[?:?]

thank you @rlkoshak for you response

This new 3.0.3 version should fix it
(I was not able work with OH 4 in my local dev env, but I guess this changes will do the trick).

let me know if you still have any issue

Unfortunately I still get the error.

2023-07-17 07:39:09.585 [DEBUG] [honeywellhome.client.HoneywellClient] - Got device by id: LCC-B82CA07C9CB5 location id: 2100216 with response: {
  "displayedOutdoorHumidity": 72,
  "vacationHold": {
    "enabled": false
  },
  "currentSchedulePeriod": {
    "day": "Monday",
    "period": "Wake"
  },
  "scheduleCapabilities": {
    "availableScheduleTypes": [
      "None",
      "Geofenced",
      "TimedNorthAmerica"
    ],
    "schedulableFan": false
  },
  "scheduleType": {
    "scheduleType": "Timed",
    "scheduleSubType": "NA"
  },
  "changeSource": {
    "by": "partner",
    "name": "Amazon Alexa"
  },
  "scheduleStatus": "Resume",
  "allowedTimeIncrements": 15,
  "settings": {
    "hardwareSettings": {
      "brightness": 1,
      "maxBrightness": 5
    },
    "fan": {
      "allowedModes": [
        "On",
        "Auto",
        "Circulate"
      ],
      "changeableValues": {
        "mode": "On"
      }
    },
    "temperatureMode": {
      "air": false
    },
    "specialMode": null,
    "devicePairingEnabled": true
  },
  "deviceOsVersion": "TH6220WF2006",
  "deviceClass": "Thermostat",
  "deviceType": "Thermostat",
  "deviceID": "LCC-B82CA07C9CB5",
  "deviceInternalID": 2350782,
  "userDefinedDeviceName": "Thermostat",
  "name": "Thermostat",
  "isAlive": true,
  "isUpgrading": false,
  "isProvisioned": true,
  "macID": "B82CA07C9CB5",
  "deviceSettings": null,
  "service": {
    "mode": "Up"
  },
  "deviceRegistrationDate": "2020-07-31T22:37:43.1066667",
  "dataSyncStatus": "Completed",
  "deviceSerialNo": "1949LBJ58399",
  "units": "Fahrenheit",
  "indoorTemperature": 68,
  "outdoorTemperature": 52,
  "allowedModes": [
    "Heat",
    "Off",
    "Cool"
  ],
  "deadband": 0,
  "hasDualSetpointStatus": false,
  "minHeatSetpoint": 50,
  "maxHeatSetpoint": 90,
  "minCoolSetpoint": 50,
  "maxCoolSetpoint": 90,
  "changeableValues": {
    "mode": "Cool",
    "heatSetpoint": 65,
    "coolSetpoint": 68,
    "thermostatSetpointStatus": "PermanentHold",
    "nextPeriodTime": "08:00:00",
    "endHeatSetpoint": 65,
    "endCoolSetpoint": 68,
    "heatCoolMode": "Cool"
  },
  "operationStatus": {
    "mode": "EquipmentOff",
    "fanRequest": false,
    "circulationFanRequest": false
  },
  "deviceModel": "T5-T6"
}
2023-07-17 07:39:09.607 [WARN ] [mmon.WrappedScheduledExecutorService] - Scheduled runnable ended with an exception:
java.lang.NoSuchMethodError: 'void org.openhab.core.library.types.DecimalType.<init>(long)'
        at org.openhab.binding.honeywellhome.internal.handler.HoneywellThermostatHandler.update(HoneywellThermostatHandler.java:140) ~[?:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) ~[?:?]
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) ~[?:?]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) ~[?:?]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
        at java.lang.Thread.run(Thread.java:833) ~[?:?]

Reading the message more closely, it’s complaining that DecimalType doesn’t have a constructor that takes a long which is indeed the case (DecimalType (openHAB Core 4.0.0-SNAPSHOT API)) There are only constructors that take Number or String.

I think you need to avoid the use of primitives and use Integer, Double, or use BigDecimal. Alternatively you can convert the primitive to a String, but I suspect that’s not the best approach.

Thank you for testing it

I changed it to “Number” (Gson is able to work with that)

The new v3.0.4 version is available here.
let me know if you have any issues.

(sorry I can’t test it by myself yet, I will try to find time to make OH 4 work on my MAC)

That did it. :partying_face: I’m no longer receiving the error and my Items are populating.

Some recommendations now that I’m seeing some actual values (these are low priority things to consider from a usability perspective).

  • Fan Status should be a Switch, unless there is some third state besides “On” and “Off”. If it’s read only I think there is a way for the binding to push state description metadata to the Item to set it as such.
  • Is Alive should be a read only Switch or a Contact.
  • For fields that can be changed that are a set of standard Strings, I think you can set options on the state description from the binding including only those that are allowed.
  • Given the Temperature Units Channel, you can set the state description pattern appropriately so it shows 68 °F automatically. You can also post “68 °F” as the update (or °C as appropriate)

There are several channels that seem redundant. For example, Mode and Heat/Cool Mode seem to have the same states. Same for Name and User Defined Device Name, though mine is just “Thermostat” so there might be different values is one customizes it. I remember thinking that when looking at the original JSON last time I messed with the API and I never spent the time to look up why. There may be a reason.

Finally, for some reason I can’t seem to link the “Displayed Outdoor Humidity” Channel. It’s weird and I need to gather more information. I don’t really need that Channel but it’s weird.

I just loaded 3.0.4 version and it works well in openhab version 4.0.0.M4

Is there a way to read the HOME / AWAY status?, that would be great to tell whether someone is in the house or not.

Thanks
Carlos

do you mean the currentSchedulePeriod ? (this is the only thing I can see the API provide)

Given what I see in your code, YES that seems to be the HOME / AWAY status read

My fan’s can be “Follow Schedule, Auto, Circulate, On”
Follow Schedule allows me to change the state based on the schedule
Auto turns the fan on when needed for the AC or heat pump
Circulate turns the fan on sometimes to keep the house air fresh even if the ac or heat have not been used
On just leaves the fan on 24x7

1 Like

Hi:
Is it possible for you to have the currentSchedulePeriod as a readable channel in the binding?

I don’t see it in the current version
Thank you
Carlos

Hey,

I tried to add it, but for some reason I have some build issue, I will try to handle in the next few days

Hey @clark
I added currentSchedulePeriod, a new version (that also supports openhab 4.X) is available here

1 Like

Hi
Version 4.0.0 of the binding does not work on my openhab 4.0.1 instance, I get a missing handler error.

can you share the error log you getting?

I’m working with 4.0 and everything works for me…

I download the jar file again and now it works, but now the bridge shows offline and the logs show a 401 code suggesting the credentials are wrong although I did not change anything
I may try recreating the setup process and getting new credentials
Thanks

use the newest 4.0.1 version - in 4.0.0 I had a small bug