ESPHome + Hubitat

Right now things seem to working well and stable (famous last words) and I've just put a garage door opener and a bunch of lights and outlets on it to shake out any issues.

The intent of the solution is that people can make their own driver stubs using the library and examples I'm providing. I just put one together for a ESPHome fan but since I don't one of those it may need some adjustments.

Eventually I'll write up some proper instructions but if anyone is adventurous and wants to play the code is in my GitHub right now at hubitat-public/ESPHome at main · bradsjm/hubitat-public · GitHub

There are example drivers so far for Contact Sensors, Fans, Garage Door Openers, Motion Sensors, RGBCT Lights and Outlets w/optional metering.

  1. Make sure the ESPHome yaml for the device includes the "api:" section and does NOT enable encryption.
  2. Download the library (ESPHome-API-Library.groovy) and install it in the Hubitat library section.
  3. Download an example driver from the repository and install it in the drivers section.
  4. Create a new virtual device and choose the driver you just installed for it
  5. Open the new device and set the IP address of the ESPHome device and the password if applicable. Make sure the device is NOT using encryption (which is now the default I believe)
  6. Save the preferences and the driver will connect and attempt to download the entities and will default to the first one it finds
  7. If the wrong entity is in the preferences, use the dropdown to pick the correct one and save the changes again.
  8. If the driver doesn't do exactly what you need, you can edit the functionality to suit your device.
6 Likes