1.Install the Zigbee2MQTT
Zigbee2MQTT Is a third-party plug-in and is not officially built into the Home Assistant. First, copy the link on the Zigbee2MQTT Github page. Zigbee2MQTT Source source address: https://github.com/zigbee2mqtt/hassio-zigbee2mqtt, is not built into Home Assistant, so you need to add a repository, and then some configuration (immediately after).
① Add a Zigbee2MQTT repository:
First open the connection, enter the github page, click the code, click the connection in the copy code,
Then return to the Home Assistant add-in store (Add-on store), click the upper right corner and select "Repositories / Warehouse",
Fill in the newly copied link into the input box, copy the previously copied connection, and then click "Add / Add"
② Install the Zigbee2MQTT
After adding the warehouse, three new items will be added to the Add-on list: Zigbee2MQTT, Zigbee2MQTT Edge, and Zigbee2MQTT Proxy. Select the message, Zigbee2MQTT, for the installation.
③ Set up / start the Zigbee2MQTT
This setup / configuration may be slightly complicated, but only needs to be configured once.
④ Configure the server
The USB direct-inserted Zigbee2MQTT gateway we use needs to input "mqtt: / / core-mosquitto" in the following position
However, if you use a wired network and WiFi Zigbee2MQTT, you need to input the Home Assistant IP (which can be viewed from the router, remember to set the fixed IP on the router) in the format " mqtt://xxx.xxx.xxx. xxx".
⑤ Set the user and password
User, password Enter the account and password you set when you installed Home Assistant.
⑥ Setup Port
There are two types of gateways: USB inserts and network connections (wired Ethernet or WiFi). In this present case, the Sonoff insertion gateway is used.
Home Assistant "Settings" ? "System" ? "Hardware" ? "All Hardware" ? Search "USB" to "find the" device path " of the USB gateway you plugged into the Home Assistant host (if you don't know how to identify it, see which devices are added before and after plugging in).
Fill in the serial device path in the port: in Zigbee2MQTT setting (below), and finally click save.
⑦ If it is a " network connection (wired network or WiFi)
I Find the gateway IP from the router (remember to set the fixed IP, otherwise it is likely to be replaced frequently because of the frequent connection);
II refer to the setting instructions of the purchased gateway to determine the port number of the gateway used;
III combines the IP and port number used by the gateway (different manufacturers may use different ports), and fill in the serial port part port: in the Zigbee2MQTT setting,
For example, my router saw that the gateway IP is "192.168.50.18", the gateway used by the port is "6638", at this time I want to fill in the value is tcp: / / 192.168.50.18:6638;
IV last press to save.
⑧ Start the Zigbee2MQTT
In Zigbee2MQTT Info, open Power On Start, Auto Recovery, Auto Update, and Display sidebar, and start. Then check the "Log" for errors. If the startup is normal, you can enter the Web UI and start connecting to the device!
2.Connect the device to the Zigbee2MQTT
2.1. Zigbee2MQTT Open the "allow the equipment to join"
Click "Allow new devices to pair" at Zigbee2MQTT, and it will turn on the pairing mode.
2.2. Zigbee Device opens the pairing mode
Take AVATTO temperature control valve wisdom as an example, according to the manual, rotate the button to the screen display OF, long press the top. The distribution network indicator light of the equipment is on. Note that different Zigbee devices start the pairing mode in different ways.
2.2. Zigbee equipment was paired successfully
When pairing, the pairing status information appears on the screen, and basically it is ok to see the green. If there is an error, the following possible problems and possible attempts are as follows:
① Try to repeat the first two steps to repair;
② Try to move the device to be paired away from the gateway;
③ The equipment you purchased may not support Zigbee2MQTT, please refer to 3. How to make Zigbee2MQTT support your own Zigbee equipment.
That's how the Home Assistant connects to a Zigbee device through an Zigbee2MQTT.
Instructions for Using the Zigbee2MQTT Dongle