Simon Kemper
Simon Kemper

Reputation: 645

Can I auto-reset ZigBee's Operation-Mode to act as a Coordinator in Software?

I am developing a new wireless IoT-product for a company. The current prototype is using ZigBee for communications and I am currently trying to figure out how to avoid having to run a dedicated ZigBee-Coordinator device. I do not want to develop a second hardware just to let it act as the main ZigBee Coordinator. For this hardware Meshing is very important.

So I read about the Digi S2C modules and stumbled over the fact that this module has a larger flash and therefor incorporates all three ZigBee-Firmwares (End-Device, Router, Coordinator) into one single file. With using serial-commands you can then change the device-mode from coordinator to router or end device.

By thinking about it I came up to the following idea how to avoid having a second hardware just acting as a coordinator.

  1. By powering up the first hardware unit the ZigBee Module runs as a Router / End-Device and is looking for a coordinator

  2. If there is no coordinator the module resets itself and changes its device-mode to become the coordinator

  3. Every following unit does the same and will connect to the first unit which acts as the coordinator

Using this concept I could stick with my single hardware and let it automatically choose between running as an End-Device, Router or Coordinator.

Questions are:

I know that you can put custom code onto the ZigBee-Modules controller. Is this controller able to reset itself and restart in a different operation-mode? Like leaving a flag before restarting or so?

Or do I need a second controller that is taking care of such a process?

Am I missing some detail in the ZigBee-Stack that has already implemented such a concept?

Upvotes: 1

Views: 710

Answers (2)

carneseca
carneseca

Reputation: 136

Am I missing some detail in the ZigBee-Stack that has already implemented such a concept?

I think you might be interested in creating a distributed network. ZigBee has defined commissioning schemes which allow you to create networks without a hub. The first few minutes of this talk should give you an idea of what commissioning options are available: https://youtu.be/HJlQI2Z7V-Q?t=2m48s

You can design your device as a router, and give it the option to additionally form distributed networks. You'll have all situations covered. When a user sets up your system in an environment where they already have a hub, they'll simply join your devices to the network through the existing coordinator. In addition, when a user sets up your system in an environment with no hub, they'll tell one of your devices to form a distributed network. The rest of your devices can then join as normal.

The Light Link profile also addresses this issue. Devices are added to a network by "touch link". The key part is that when someone touch links your device and there is no network, your device promotes itself to coordinator and creates one. You can then continue to touch link the rest of your devices and they will be added to that network.

Upvotes: 1

tomlogic
tomlogic

Reputation: 11694

Are you using Digi's XBee modules, or just asking if this is something possible in general?

I'm not entirely sure I understand what you're asking in your question. The host processor attached to the XBee module has the ability to configure it and restart it as needed. You can check on the network status and tell it to leave the current network, or try to join a network.

You can configure the XBee module through AT commands to be a coordinator, router or end device. You also set network parameters like the network ID and security keys used.

You would likely want to have some sort of interface for the installer to use which would promote a router device to coordinator, otherwise you risk modules electing to becoming coordinators when they shouldn't, and ending up with multiple networks. It also needs to be clear to the installer which module is acting as the coordinator (LED flashes differently?).

Is ZigBee certification a requirement for the product? If not, look at the XBee DigiMesh modules which can form a peer-to-peer network without the need for a coordinator.

Upvotes: 0

Related Questions