Control 12V RGB LED Strip from Home Assistant

Home Assistant is a popular open source platform for home automation. It is written in Python programming language and runs perfectly on Raspberry Pi 3 B/B+ or 4 B. Now, with the latest updates of the Arduino sketch for ANAVI Light Controller it is super easy to control 12V RGB LED strip from Home Assistant through your smartphone, tablet or personal computer.

Have a look at the video and follow the steps below to configure ANAVI Light Controller and change colors of 12V RGB LED strips from Home Assistant.

What Is Required?

The following hardware is required:

How to Install?

  • Install Mosquitto from Hass.io add-on store. Set username and password for login to Mosquitto. Set active Access Control Lists (ACL) for the username and launch Mosquitto (it is recommended to install SSH server prior this step).
  • Add MQTT integration in Home Assistant with enabled discovery (from Configuration > Integrations)
  • Attach the 12V RGB LED strip to ANAVI Light Controller
  • Ensure that ANAVI Light Controller has been flashed the latest version of the default Arduino sketch. If it is not, compile it and after that upload it following this video guide.
  • Turn on ANAVI Light Controller, connect to its WiFi Access Point (AP) and configure it through the captive portal. You must provide your WiFi credentials, MQTT server, username and password. After that ANAVI Light Controller will be automatically discovered by Home Assistant over MQTT.
  • Through Home Assistant change colors or effects of ANAVI Light Controller.

How Does It Work?

ANAVI Light Controller is powered by the ESP8266 microcontroller with WiFi. The default Arduino sketch works with the machine to machine protocol MQTT and implements Home Assistant discovery of MQTT Light component.

As soon as ANAVI Light Controller boots, after it has been configured, it connects to the WiFi network, after that to the MQTT broker and sends retained MQTT message with JSON payload that describes the device. Each ANAVI Light Controller has a unique MD5 ID based on the chip ID of ESP8266. The MQTT integration in Home Assistant discovers ANAVI Light Controller based on the received MQTT message. Thanks to the data in the JSON payload Home Assistant automatically configures the device as MQTT Light.

Home Assistant & 12V RGB LED strip attached to ANAVI Light Controller

Home Assistant discovery is a user-friendly way for quickly adding new Internet of Things to the platform. Combined with MQTT and the default firmware for ANAVI Light Controller the process is straight-forward and anyone can do it in a few minutes.

You may also like