Add Gateway To Home Assistant
You are now ready to register your XiaoMi Gateway. At the time of writing, the Hass documentation has this note:
# You can leave MAC empty if you only have one gateway.
That did not work for me. Had to specify the MAC address in my home setup for Hass to find the XiaoMi Gateway.
- Login to your Home Assistant setup and modify the configuration.yaml file.
- Add the following section, replace the mac and key fields with your unique mac address and password from the previous page.
- mac: 34ce00000000
- Restart Home Assistant Control.
- If everything works, you should see additional widgets appearing on the dashboard. Note that your widgets have long generic names when first recognised by Home Assistant. You can rename your devices by going to Configuration → Customization:
- In the above example I have 3x mono switches, 1x temp/humidity sensor and 2x power plugs. They all show up at various locations. Havn’t figured out why the switches don’t show up on a panel like the switches do (If you know how please leave a comment below thanx!).
- Now that all the devices are showing up properly, we are ready for some automation.
Comment from: Diogo Visitor
in point 5, with version 2.66.2, I needed to press 5 times, or more, not in the blank area above the version, at the bottom of the screen
Thanks. Have updated the article.
Comment from: Juan Visitor
I dont understand step 2. How can i do this step?
Hi Juan, which step 2 are you referring to? Can you tell me the page # of the article you’re having problems with?
Comment from: MALCOLM Visitor
Hi I cant find the password field in the latest version of the gateway 3.3.10_117 there is now a security PIN password General Settings > Security. Is this the same value?? Mac address and IP details can now also be viewed in a different menu General Settings > Network Info
No. The process has changed slightly, but it’s the same logic.
- Go into the Mi Home App
- Go into Xiaomi Gateway
- Tap on the … at the top right corner
- Tap "About"
- At the bottom, you should see "Plug-in versin: xxx.xxx.xx"
- Tap that repeatedly and two more options will pop up
- Type "Wireless communication protocol"
- Turn "Wireless communication protocol" on
- That password you see below is your API key (Everything after "Passwrd:"