Zigbee2mqtt: getting rid of your proprietary Zigbee bridges (Xiaomi, Hue, TRADFRI)

Thanks @milakov and @nickrout! Adding the 0 in the add-on configuration resolved it. It stays a mystery how it had been working for months and I’ve not touched the configuration… Did I have the 0 and it just lost it or did it work without the 0 and all of a sudden it was required (unlikely…)

Anyway thanks again!!!

Just curious, what type of Xiaomi Aqara sensors already supported by Zigbee2mqtt?

It is pretty interesting to use MQTT for controlling Zigbee devices.

2 Likes

I believe the purpose of “grey ring up” is these devices tend to see a bit above themselves (i.e, they are meant to be placed on a coffee table, night stand, dresser, etc). By flipping them upside down (grey ring up) they can be mounted in a higher position and have visibility below themselves.

Hi,

I am planning to use zigbee2mqtt for connection between my Raspberry Pi (Installed Raspbian OS and Hass.io) and Xiaomi sensors with distance around 100 metres between them.

My proposed systems as per below:

  1. Connect Raspberry Pi with a CC2530 or CC2531 coordinator.
  2. Set up 1-2pcs of CC2530 or CC2531 router to extend ZigBee signals between these two devices.
  3. Xiaomi sensors

I have few questions before purchasing required components for setting up whole system above:

  1. Is CC2530 or CC2531 better for coordinator and router? I need one with external antenna installed due to long range.
  2. Could CC2531 coordinator communicate with CC2530 router or vice versa?
  3. Some end devices like Xiaomi sensors parent router traffic goes offline, it don’t attempt to find a new parent so will remain isolated until re-paired with the network. As Xiaomi sensors might become inactive after some inactivity or Raspberry Pi is restarted due to unknown reason.
    So, is there any solution for this issue beside pairing again manually?
  4. When WIFI router which connected with Raspberry Pi is down (WIFI network is down completely and no public internet access), will Raspberry Pi still able to accept Xiaomi sensors status via MQTT in this case?

Thanks.

@milakov

Hi,

  1. I think most of us use the CC2531 as a Coordinator and a Router. The CC2530 is often used as a Router.
    Maybe you are interessed in one of my modded devices, feel free to contact me via pm if interessted.
    Buy a ready2use zigbee2mqtt stick - flashed, antenna mod and printed case
  2. Yes they can.
  3. Idk @Koenkk
  4. I don’t think so because mqtt works over your local network (lan or wifi)
1 Like

I’m sure I’ve just read that the main difference between the cc2531 vs. cc2530 , the cc2531 has internal usb on board. The 2530 does not. other then that there are interchangeable.

However I’m still a bit new to the zigbee of things way doing stuff, and could be wrong. Still reading and tinkering.

1 Like
  1. According to the documentation only the CC2531 can be used as an coordinator the CC2530 has a better range as a router.
  2. Yes
  3. This is true, Xiaomi devices don’t try to find a new/better router. But as soon as the router or coordinator to which your end device (Xiaomi Sensor) was initially connected comes online again, the end device will automatically reconnect to it.
  4. Sensor messages between the Xiaomi Sensor and your CC2531 which is connected to your RPI still get sent via Zigbee. If you attach a monitor to your RPI you can still see the messages in the log. MQTT messages however don’t get sent when the RPI has no network (WIFI down)

Does this help?

1 Like

Both can be used as an coordinator or router.

https://e2e.ti.com/support/wireless-connectivity/zigbee-and-thread/f/158/p/160183/582873

If wifi is down your raspberry pi will still receive mqtt messages because hassio and zigbee2mqtt are on the same pi.

2 Likes

@eifinger,

Thanks for the info.

  1. As long as Xiaomi sensors connect back to initially connected coordinator when it is online, then this should be fine.

  2. Means that I cannot tigger HA light/automation based on Zigbee sensor status when WIFI network is down? Since now all Zigbee devices are communicated via MQTT, despite can see Zigbee logs using external monitor.

Looks like a lot of different opinions on this part.

Just to confirm, previously you tested on this part and it is working?

Because Hass.io only same pi with coordinator, but not for router.

You need to understand tcp/ip networking a bit better. If one process on a host wants to communicate with a service running on the same host, they communicate via the localhost address which requires no Ethernet, either wired or wireless.

2 Likes

Thanks for the clarification.

I am newbie in networking.

@nickrout is right. I overlooked that you will be using zigbee2mqtt and hass.io on the same pi. They will be able to communicate. (Given the MQTT broker is also on that pi)

1 Like

Thanks for your clarification.

Hi,
Sorry if I’m a bit off-topic here.
Will this work with Livolo Zigbee Wall switches? Will I be able to connect them to HA without buying their gateway?

Thanks in advance.

1 Like

Looks to me that it should, being a zigbee product.

There is a list of supported devices https://www.zigbee2mqtt.io/information/supported_devices.html

Search that list.

1 Like

I’m planning on adding some Xiaomi sensors to my network, and I’m mightily confused after browsing this thread.

These will be the first zigbee sensors on my network. I was under the impression that I can just add the zha component in configuration.yaml and then add the devices like I would zwave. Am I mistaken? Do I need to use to use the Xiaomi bridge or Zigbee2mqtt? I’m using a Docker setup and already have MQTT working, and I suppose it would be easy enough to add this Zigbee2mqtt, but for just 2 sensors I don’t know if it’s worth the effort.

Lol, I just learned that I need a Xiaomi Gateway, which I don’t have. Since I have the zigbee USB, is that all I need to use Zigbee2mqtt?