[Home Assistant] Basic Setup Guide | Adding Custom Integrations

Prerequisite

What’s Integration?

Integrations in Home Assistant can be viewed as applications in computer/tablet/smart phones. In order to register i.e. integrate different smart home devices into the Home Assistant platform, you need to install the corresponding integration.

As a one of major point of confusion in current version of Home Assistant, there are various methods of integration installation. This is not based on user’s choice but developer’s choice i.e. each integration only support one way or the other. So if you do not know each options, you may end up viewing Home Assistant as rather limited platform.

After going installing a dozen of integrations a few times, I categorize Home Assistant to have four distinctive ways of integration installation.

On the top level, I see the integration can be divided into two categories. One is an official home assistant integration and the other is through the Home Assistant Community Store (HACS). Both are free and community member developed integrations, but I interpret these as one is officially approved and the other has not (yet).

The HACS installation is viewed as custom add-on as these are not officially approved by Home Assistant. Although HACS have its own list of integration page, there are still some integration that’s are not listed in there yet despite integrations are for Home Assistant. So this is more of a custom integration within already custom store.

Initially, I did not realize the existence of various methods of installation existing in Home Assistant so I got a bit confused. However, organizing type of integration installation as above, I now feel much more comfortable searching and installing new integrations for my devices.

In this guide, we will be focusing on HACS integrations with the real world examples that I have been through.

What is HACS?

Although Home Assistant have large number of integrations on its official list, you may still encounter devices that are not on the list. You are not out of the luck here. Home Assistant have second public list of integrations, called Home Assistant Community Store (HACS). Think HACS as a free store for not yet officially approved integrations.

Install HACS

If you have followed my basic installation guide, you are in good shape here because you should already have the Terminal/SSH add-on.

Open Terminal & SSH

You then need to copy and paste following command line. This will initiate install of HACS.

wget -q -O - https://install.hacs.xyz | bash -

You have installed HACS but not yet configured. So you need to follow steps as described in official site. In these steps, you will be asked to create an account on GitHub. This is a programming code hosting site and where all the active programming of Home Assistant taking place including official integration and Home Assistant itself.

Once you have HACS installed and configured, you can start searching custom integrations on the HACS page.

HACS UI Install

In my case, I needed HACS to install following integrations:

  • UniFi Protect
  • Home Connect (Kitchen Appliances)
  • Arlo Camera

UniFi Protect

HACS > Integrations > Explore & Add repositories > UniFi Protect Integration > Install

You need to restart the system. Now this has added UniFi Protect to your official integration search list.

Configuration > Integrations > ADD INTEGRATION > UniFi Protect

IP address: I used UniFi Dream Machine Pro so the router address is the same as where UniFi Protect controller runs. If you use Cloud Key, this is Cloud Key’s IP address.

Port Number: Leave to 433 for Unifi OS.

Username & Password: I have created a new user on UniFi controller for home automation integration.

The rest of the set up I left as default.

Ease of Setup: 7/10

Setting up the HACS require some additional steps. Also you need to create integration account on UniFi Controller side. Overall, if you follow step by step instruction, you can make it work. Given HACS being such a usable part of Home Assistant, I hope this is added as Advanced User Setting on the official Home Assistant using UI. Once HACS is installed, I think the system is much more user friendly if official integration page include HACS integration entries. To ensure user understands the risk of custom components (HACS) compared to official integrations, each entries may have special label/tag, and before each installation warning pop up may be shown.

Performance: 8/10

I’ve already shown UniFi Protect camera on other part of examples, but the latency/response time of this integration using Camera is phenomenal. Below is comparison table.

The above test proves Home Assistant, especially with appropriate hardware have very low latency. In fact, if one really desires for real time stream, recommendation is turn off RTSP on UniFi camera. This will force Home Assistant to capture images from UniFi Camera using sequential snap shots. This will be essential true real time stream. The trade off is loss of sound and frame rate is ultra low i.e. you see rapid sequence of images rather than smooth video stream.

So why am I not giving full 10? This is because I have noted strange issue/bug where using virtual machine setting (Home Assistant OS on NUC ProxMox Virtual Machine), door bell ring and motion trigger stops working after a few hours of system running while the video stream remains to work. I noticed the very similar issue with another platform, Homebridge when using Docker. These issues do not occur with dedicated hardware install either on Home Assistant or Homebridge. However, Homebridge developer forum reports this will be fixed and some suggested the issue really lies on updated UniFi Protect. So this may not be a real issue on Home Assistant Integration part, and hopefully it gets fixed.

HACS Custom Install

The last method of integration install is custom install within HACS. HACS is already unofficial custom components but this is for integrations that are not even on HACS store list. In my case, I was googling for possible “Bryan Evolution Thermostat” integration and came across a home assistant-infinitude component that suggested to use this.

Bryant Evolution

This is a thermostat identical to Carrier Infinity Touch thermostat, just rebranded by Bryant.

Ease of setup: 6/10

This integration is fully software based, but requires a few steps.

  1. Set up Infinitude Proxy Server
  2. Point Bryan Evolution Thermostat to the Infinitude Proxy Server
  3. Install home assistant-infinitude integration on the home assistant

Infinitude Proxy Server

Bryant evolution normally connects to Bryant’s cloud server. Infinitude Proxy server is locally running server app that can be used in place of Bryant’s official cloud server. I have Qnap NAS. So I installed Infinitude Proxy server on it using docker. It was important to assign static IP to this.

Bryant Evolution to Infinitude

On the Bryant Evolution controller, I went into Wi-Fi set up > Advanced > Proxy Server Setting. This is where I entered Infinitude Proxy server IP address.

I initially had an issue for this not working due to the fact Bryant Evolution was originally placed on IoT network and Infinitude was on the main LAN. Since Home Assistant OS is also on the main LAN, I moved Bryan Evolution to the main LAN and now all started working.

Infinitude page accessed by typing in IP address:3000 on web browser

Home Assistant to Infinitude Integration

This is the final and uniques step for the home assistant integration.

HACS > Integrations > right upper corner "..." >  Custom repositories

You need to paste the link to the integration/repository and select Integration as category. Then hit Add and Install. You need to then restart the system.

Lastly, you need to add lines to configuration.yaml and restart again.

climate:
  - platform: infinitude
    host: <infinitude_hostname_or_ip>
    port: <optional, defaults to 3000>
    zone_names:
      - Custom Zone Name 1
      - 
      - Custom Zone Name 3

Performance: 10/10

I have not test this in much extent, but so far it works great. Not only I get to see the settings, but I can actually make changes. The cool thing about is, I can still remain to access Bryant Evolution thermostats using its official up even remotely.

Next Up

Now you know how to install and configure various integrations, you can start putting them together i.e. start making automations.