SmartThings Community

Zigbee - from flakey to stable

(George) #147

I’ve got 6 zigbee light switches that are not reporting in the IDE live logs. They still work, and I can control them through smartthings and GH and webcore. What would be causing this? I have a whole stack of other routers, and also endpoints that are reporting in the logs. No matter what I do, turn on at physical switch, turn on via smartthings app, via webcore etc, they dont report in the live logs. I’ve tried searching the live logs on both zigbee ID (4 characters) and device network ID (16 characters). Their device name does NOT appear up the top, where all other device names propagate.

I added in a Xbee a few days ago, and have been monitoring the zigbee network. The xbee can see these devices - they are all in the mesh. I’m not sure if the Xbee caused this, however, I’ve been turning off the Xbee at nights (as it’s still attached to my computer, and I’ve been monitoring the network).

Other things in my zigbee mesh. 2 Osram bulbs (always powered on), and 7 Xiaomi outlets (powered). These all act as routers. A whole stack of end points (contact sensors, buttons). All my devices are showing in the mesh, according to the Xbee.

Does the Xbee take over management of some devices, so that it doesnt even reach smartthings? The reason why I want to see the logs, is I’d like to make sure that some of my devices are connected via the Xbee to get them off my smartthings hub, and I’m over the 31 device limit (although I have >12 routers).

Edit: the Xbee is showing that some of these devices are connected directly to the Hub. And they are connected with the Xiaomi power sockets. What is the issue with the power sockets?


(George) #148

I have some further questions. Today, I recieved some zigbee motion sensors. They paired with ST, however, they paired via a router (Xiaomi outlet). They dont appear on the zigbee mesh on the XCTU program as a node. They show up that they are connected to a Router. But they dont show up as an Endpoint. Is this normal behaviour?



Yes I have the same issue re Endpoints/routers - see my post of a couple of days ago, the same types of device show us as ‘end points’ when connected to the hub but ‘routers’ when connecting via xbee routers - if you read my post you will see that they invariable drop off the network after a couple of hours also even though their Xbee router is in close proximity.



Can you advise why you think this will work ? I am trying to understand the logic. I already have 31 Xiaomi devices that are connected reliably to the hub, plus Xiaomi mains powered 'light switch ’ devices which connect reliable to XBee routers. My extra Xiaomi devices appear to pair up to Xbee routres correctly and work for a short period of time, but then drop the connections.

I am trying to figure out why removing and adding would not just have the same effect, what is the difference to current situation?

FYI - I have tried the Xbee reset via powering off (& batteries) on hub for 30 mins - no effect, all the devices registered to the hub reconnected to that (irrespective of xbee routers being far nearer in many cases)



not sure why they are not showing up in your ide live logs if they are working they might be appearing under the router id.
Is the motion sensor a Xiaomi going through Xiaomi outlet and if the motion sensor does not show up as an end device I assume it is showing up as another router? but I have never seen this happen but I do not have any Xiaomi outlets. Xiaomi motion sensor should be showing up as an end device. generally battery powered devices are end devices. If it is a wall powered device it may be a router. It really depends on the manufacture I have battery powered one of my Xbee3 and it is still a router as that is how the Xbee settings are programmed.
Some devices just do not work well as routers such as the Iris/SmartThings plugs or GE light switches or light bulbs with Xiaomi devices.
As far a duplicate device showing up in in different routes that is common but not really sure why some devices do it.

Xiaomi device generally do not like to do an orphan scan and find new routers.
I do not have the patience to wait for my hub to maybe rebuild my zigbee network.
It is just faster to remove all your end devices and re-add them. When doing this I would unplug/unscrew or power off at the breaker (if hard wired) all router devices that do not work with Xiaomi devices so they do not try to route through them.
Then re-pair the Xiaomi devices.
After or before the Xiaomi devices are added you can leave those router devices powered on for adding non Xiaomi devices.

Once you do this end devices will show up under routers (some may still join to the coordinator there is no way to control which router or coordinator the end device joins except for powering off all routers you do not want to go through).
Basically right now your coordinator is full and kicking things off.


(Keith G) #152

With 31 end devices connected directly to the hub, you can only have one router connected, because routers count towards that 32 device limit of the SmartThings hub.

As NoWon states, you should find a way to move some of those 31 Xiaomi devices off to be connected via a router instead of directly to the hub. That will allow you to use more routers.

EDIT: I have to apologize, because I was incorrect in saying that Zigbee routers count towards the 32 device limit. That limit is only for end devices as stated here.

I can also confirm that using the normally recommended “self-healing” method of powering down the ST hub will not work well where Xiaomi end-devices are concerned. They do not re-join after going past the end-device timeout which is the whole reason why people have troubles with Xiaomi devices remaining connected. It’s much better to do a “forced” (manual) re-join by putting the device into pairing mode (but don’t delete it from the ST hub’s device list, in it’s install location, to get it to connect through a router.

In your situation however, you will need to remove a number of your Xiaomi devices to make sure you have all routers paired and properly connected to the ST hub before attempting to re-join end devices to connect via the routers.

It’s a lot more work, but the best-case procedure would be to remove all devices, pair all routers to the ST hub first, and then pair all end-devices at their intended install location so they can choose their router.

Also, in my testing if a battery-powered Xiaomi end device appears as a router in the XCTU network scan, that device is connected via an incompatible router and will sooner or later drop its connection.

1 Like


Just as a note for everyone running Xbees I noticed mine had PL set to 1 even through default should have been 4 (max power) I assume it came programmed at 1 and I never wrote the default settings to it before adding all the settings listed previously in this thread.
PL should be 4

1 Like

(Graeme) #154

Just something I have noticed about the Xiaomi Aqara Motion Sensor ( I have 6 of them) is that when you initially pair them, they remain connected until there has been no motion activity for about 2 hours, then they drop off the network (regardless of whether they link directly to only the hub/coordinator, or have links via routers such as the xbee).
You can then re-pair them by putting the hub into pairing mode and pressing the button on the device several times, until they show up as available, and then they seem to be able to remain connected for longer (hopefully indefinitely - so far a few days).
I also noticed that they connect to the xbee routers right away when pairing and show up in an XCTU network scan as Routers, well before they show up as paired and available in ST.


(Alwas) #155

This thread is about people seeking help with Xbee’s, this conversation about all things Xiaomi, buttons and motion sensors etc is best placed on the Xiaomi thread, it’s about 1500 posts long, they seem to be having a lot of fun over there.


(Graeme) #156

As I read it, the thread is about ZigBee and its reliability on ST - based on its title. I added xbee routers to my network based on this thread and am feeding back some results that I have seen. My post refers to Xiaomi ZigBee devices, which are mentioned in some 40 posts previously in the thread indicating that some of the followers of the thread may be interested and are trying to get their Xiaomi devices to work reliably on ST - possibly also using xbee routers (which I also reference).

1 Like

(Keith G) #157

This does not match my experience with my two Aqara Motion Sensors. If they are dropping off after about 2 hours then it’s likely because of end device aging timeout, but this hasn’t been an issue with the ST v2 hub for a while. It is an issue with other hub types, such as the Samsung Connect Home or the Samsung ST Link for NVIDIA Shield TV. Are you using a v2 hub?

It may be possible that with adjusted sleep timeout settings on an XBee (SN = AF0 & SP = 130 or higher, as described in this post,) you might be able to keep Xiaomi devices connected beyond a non-v2 ST hub’s end device aging timeout period, as long as the are paired and always remain connected via the XBee. But I threw out my Samsung ST Link out of disgust and have most moved over to a Hubitat hub so I don’t think I’ll be testing this theory.

In all my testing, if a Xioami end device shows up as a router in an XCTU scan, it won’t remain connected. Also, I’ve not seen this happen when a Xiaomi device is connected via an XBee, just when connected through my only other Zigbee router, a Securifi Peanut Plug. As I understand it, if the XBee recognizes a device as a router, it will try to send and expect to receive messages only intended for routers, which an end device isn’t going to be capable of. But if it’s working for you, then fantastic!



I have read through both the Xbee2 and Xbee3 manual and I can not find what setting AO = 7 does. I only see settings 0,1,3
I haven’t had any issues just curious where you found this setting.


(Don) #159

I don’t remember off the top of my head.

I think it had something to do with the firmware I loaded into my pro module. I was just putting pieces together from different threads, websites, and people’s help. This was before this became so common and talked about.

I am using firmware 4060 on Zigbee reg family. With function set for Zigbee reg.

Possibly it’s in there somewhere. I should be able to select option 3, but since it is working I have not messed with it.

When I get time to be at my computer I can see if I left any notes and hints there.


(Graeme) #160

Thanks - yes, I had changed the SN and SP settings on my xbee’s.
One of my xBees is a Digi usb x-stick, which I have plugged into a permanently on PC, constantly running scans from XCTU at present. The other is a xBee SC2 plugged into a Waveshare USB adapter. It is currently also plugged into a PC, but I am planning to have it just run from a USB power socket.

Oddly, all but one of my Xiaomi motion sensors have switched from routers to End Devices on their own in the last day.

I have 45 ZigBee devices and my network looks like this:

B9C6 is a XIaomi Motion sensor which is showing as a router.
DE93 is also a Xiaomi Motion Sensor which changed from a router to an End Device
5362 is the Digi X-stick
B1E8 is the xbee SC2
963F and F76C are both ST Power Outlets


(Keith G) #161

Very interesting that a majority of end devices (31) are connected directly to your ST hub. It definitely confirms that the 32 device limit is still just for end devices, and not for routers (repeaters), as was stated here:

So I stand corrected on my previous statement that routers count towards the limit, a few posts up. I could have sworn I read that somewhere here on the forums, but it turns out I was wrong!

Also interesting is that of the other end devices, only 2 of them are “claimed” by a single router. The other 6 are showing a connection via multiple routers. I don’t know enough about the deep ins and outs of Zigbee to know whether that’s normal.

Hopefully those work just as well with Xiaomi and other devices as the developer modules!


(Keith G) #162

Hi again - I have to apologize, because I was incorrect in previously stating that Zigbee routers count towards the 32 device limit. That limit is only for end devices as stated here.

However, you will only be able to pair one more end device that directly connects to the hub, and after that any additional devices need to connect via a router. Since you have so many devices directly connected to the hub, perhaps moving a router closer to the location of the hub would help with your issue of dropped connections - if they are due to weak network connections because of distance and or interference.


(Devesh Batra) #163

appreciate if someone can point me to part numbers for what i need (module, USB adapter…) to get started… tried finding stuff on and its a nightmare …




@ArstenA where did you buy your CR-10S at that price? I have been looking for one


(Brian Spranger) #165

I got mine from lightinthebox.

I have seen them as low as $340 on groupbuys.

Get the CR-10s not the CR-10.

I do think prices have in general gone up on all Chinese import sites.


(Alwas) #166

The last time I used and i was very satisfied with their service.
These are the part numbers.