After successfully playing with ZHA/Elelabs Zigbee Shield I wanted to try this popular CC2531/Zigbee2mqtt “Bridge”.
As with my working ZHA I have a new RPi/Hass.Io and latest HA 0.85.1. I think I successfully followed the instructions flashing the CC2531. I only allowed some system monitoring to new installation. I added Samba and SSH and then followed:
I thought everything was supposed to be straight forward. MQTT showed to the UI. ZigBee2mqtt log doesn’t look good (last line):
Missing “Bridge State”:
Not sure which port I should use /dev/ttyAMA0 or /dev/ttyACM0 (Tried both - no luck)
So nothing happens and I cannot pair anything. The worst part is memory usage which went immediately sky high.
And immediately after uninstall the Zigbee2mqtt memory usage is back to normal.
That log entry from Zigbee2MQTT is the same one I get when the wrong USB serial device is chosen.
Assuming you’re using HassIO, go to the “Hass.IO” screen, then choose “System” at the top, then under “Host system” click “Hardware”.
You should see a list of all connected devices there. I would remove the C2531 from the system, restart, see what devices you have connected. Make a note of them. Then reconnect the CC2531 and do the same process and the new device that showed up will be the proper name to use within the plugin’s configuration page.
Everything there except the MQTT error seems normal, so I would say that the addon is functioning properly, it just can’t see your MQTT broker.
So the question now is, how is your MQTT broker set up?
In your config for the Zigbee2MQTT addon, you should have " mqtt_server" set, at a minimum, and if do not have anonymous access enabled on your broker you’ll also have to have “mqtt_user” & “mqtt_pass” set.
For example, in my config for the Zigbee2MQTT addon config is:
So how did you add MQTT to your system? Do you already use MQTT for things and it works?
I know you said it was auto-discovered to add to HA, but an MQTT broker isn’t installed by default in HA unless that changed VERY recently.
Usually people install one of the two MQTT addons from the addon store. Either the “Mosquitto broker” or “MQTT Server & Web client”.
For the first one, the configuration (allow anonymous & configure user/pass) is set in the addon configuration. For the second one, I’m not sure as I don’t use it.
For example, I have the “mosquitto broker” addon installed for MQTT, with the following config:
No, that’s just a page to manually send data over MQTT, it doesn’t necessarily mean it’s connected to a broker. You can try it and see if you get an error in the logs about a broker not being available or connected.
I would just go ahead and install the Mosquito broker and proceed from there.
That is basically exactly what I did - like I said I just started with this zigbee2mqtt with opening the box of brand new RPi. Before that I have Elelabs Zigbee Shield/ZHA working very well in another RPi taking care of lights, heating and security with 31 devices including around 10 different kind of IKEA Trådfri Bulbs. Pairing in ZHA with Ikea is exactly same from Ikea side. After resetting the bulb actually blinks shortly to inform reset is OK and it is ready for pairing.
Later today I will try again - also with other zigbee devices … I will report after that - and probably need help once again
Yep, that’s what it looks like. Huh, learn something new every day I guess… lol
It looks like there are some features missing from HBMQTT as well as a bug or two, so it still makes sense to use an external broker such as Mosquito IMHO, but it’s good to know there are other options.
So do you see that long ass payload it sent (in your screenshot) to the topic “homeassistant/” ? That’s the payload for autodiscovery that will create the entity automatically.
When you initially configure the MQTT integration in home assistant, if you did it through the UI there should have been a checkbox to enable discovery, or if you did it via YAML there’s a setting for that i believe.
If you have autodiscovery enabled for MQTT, HA should see that payload sent to the “homeassistant/” topic and automatically add an entity based on that.
Alternatively, you can read through that discovery payload yourself and manually create an entity based on what it’s telling you would have been configured by autodiscovery.
I have to give one last update here. Just not to mislead anybody.
As being a bit stubborn I wanted to give that “native” HA mqtt another chance.
I got rid of Mosquitto and tried with embedded MQTT broker. It finally worked fine.
Missing part was password.
I still would like to get good solution for protection of CC2531. I am not so sure about those 3D printed enclosures. If nothing else, could just heat shrink tube work?
Hey guys, I managed to discover my Xiaomi Aqara temperature sensor and I can see it in zigbee2mqtt configuration.yaml file. I can’t however see it on the GUI, where do Zigbee devices show up? are they meant to show up on the dashboard?