This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

When broadcasting a message, Mesh "steps in"?

Other Parts Discussed in Thread: Z-STACK

Hello.

When the coordinator (or any other router) broadcasts a message, using the 0xFFFF "destination address", then if there is a far router which the coordinator can't communicate with it directly, would the coordinator send the message to that far router using the Mesh topology?

or that for it to happen, the coordinator cannot use the broadcasting 0xFFFF address, but must use the specific network address of that far router?

Meaning, is the Mesh topology good only for unicast messages, and not for broadcast messages?

Thank you in advance.

  • It's not optimal but it works if you need just a couple of hoops. But for large networks the bandwidth used rises exponentially

    We use rebroadcasting for multihop delivery. Other  networks like Insteon also use this extensively with great success.

     

  • Reference section 3.3.3 in the Z-Stack Developer's Guide.

    With the address mode set to AddrBroadcast and using 0xFFFF as the broadcast address will result in the message being sent to all devices in the network, including sleeping devices. Since ZigBee routing is a distributed process, each routing device will send the message to its children as well as its parent. Each routing device will continue this process until the massage had been broadcast to all nodes. This means, of course, that a parent device may receive multiple transmissions of this broadcast message, but this way the message can propagate completely across the mesh network. Parents must also store this message in order for sleeping devices to be able to poll for it when they wake.

     

    Scott

  • Thanks a lot guys.

    If all the routers (less than 32) are the children of the coordinator, then it means that the message for the coordinator (the father) wont be forwarded to the far router by his "router brothers"?

  • Unless you've been fooling around with the network settings, the Coordinator should only have 6 Router children (i'm unsure what the limit is), and each Router under that should have no more than 6 Router children.

     

    Scott

  • Thank you.

    I indeed intend to increase the MAX_DEVICE_LIST and MAX_CHILDREN to 32 (and MAX_ROUTERS to 31 since I read here in the sticky that it must be smaller than MAX_CHILDREN).

    So in the case of a broadcasting message,
    Do routers forward the message to their "brothers"? (Or only to their parents and children?)

  • Just remember when u change all the settings, that u keep to the "Cskip". If u never heard about that, this threat may help you:

    CC2430, maximum node depth (somebody from TI uploaded a useful excel sheet here!!!)

    or

    Zigbee Tree Addressing (Cskip) Explained

     

    Cheers

  • Hey.

    I intend to follow the Cskip restrictions, thank you for reminding me though.

    Regarding my question, If I built up a 1 depth network with a Coordinator and Routers which all of them are children of the coordinator.

    1. When Coordinator broadcasts a message, do the routers forward the message to their brothers?

    2. When Coordinator sends an unicast message to a far router, will it use other routers in the way to forward the message to the far router?
    SInce I've just done such an experiment, and the far router did manage to send unicast messages to Coordinator (through the mid-way routers brothers), but the Coordinator didnt manage to send unicast messages to that far router.

    Thanks again.

  • "Regarding my question, If I built up a 1 depth network with a Coordinator and Routers which all of them are children of the coordinator."

    This tells me that you are setting up a 1 depth network of a Corrdinator and 6 Routers (the limit of CSKIP) with no End Devices. This is a star network, not really a mesh. No Router to Router communication will occur unless the Cordinator dies.

    1) Not in this case, unless the Coordinator dies.

    2) There are no Routers in the way in this example.

    Routing is a decentralized, cooperative process. No device in the network has a complete map of the netowrk (unless the programmer implements such a map). Each device contains a routing table of its neighbors. Entries in that table are created only as needed (AODV).

    Read more on ZigBee routing here. Download the Zigbee pdf and see pages 8-16 and 8-17.

    Scott

  • Hello and thank you for your help.

    I read the ZigBee PDF file (the one in the workshop) and it contained great information.
    Here are my answers to you please:

    1. To my understanding, From the moment that the coordinator has formed a PAN network, then it acts like any other Router.
    Therefore i dont understand why would "Router brothers" will forward messages to each other only when the coordinator is disconnected?
    Is it because that "brothers" forward messages to each other only when their father is disconnected (no matter if their father is the Coordinator or other Router)?

    2. Well, there are Routers in the midway in my experiment.
    Let me please explain better my experiment:

    http://img244.imageshack.us/img244/4323/mesh.jpg

    So now that its more clear, why do you think that Router #2 didnt manage to receive unicast messages from Coordinator, while the Coordinator did manage to receive unicast messages from Router #2 (through Router #1)?

     

    Thank you very much,
    I appreciate it.

     

  • How have you prevented Router2 from associating with the Coordinator? From your diagram I am assuming that Router2 is associated with Router1 and ROuter1 is associated with the COordinator.

    Under normal circumstances, and all three in RF range of each other, both Routers will associate with the Coordinator

  • Hello again.

    The association process was like this:
    - In each device, the NV_RESTORE and HOLD_AUTO_START are compiled in.
    - At first, the coordinator has started a PAN network by calling the ZDOInitDevice.
    - After this stage, I placed both Routers #1 and #2 close to the Coordinator (they havent started themself in network yet).
    - Now, I pressed a Button in Coordinator to allow joining, and press a button in Routers to have them calling the ZDOInitDevice, and they joined the PAN network.
    - Now I placed Routers #1 and #2 as in the picture above and conducted the experiment.

    As I said, Coordinator and Router #2 werent in RF range of each other.
    The Coordinator managed to receive unicast messages from Router #2 only through Router #1, and what i dont understand is, why didnt Router #2 manage to receive unicast messages from Coordinator?

    Thank you again.

  • With the startup process you describe, both routers are almost certainly children of the Coordinator. The physical placement of the devices will not affect the routing process. I'm uncertain what you observed in this particular instance.

    In case I mis-spoke earlier ... in this situation, all three devices are within RF range of each other and both routers are associated with the coordinator.

    You transmit a message from router1 to router2. The routing table on router1 will not have an entry for router2 and a route discovery will take place. Router1 should now be able to send a message directly to router2. If you are seeing alternate routing, maybe there was RF noise that occurred while you we're starting up ... I'm not sure.

    Scott

  • Hello.

    Again, I very appreciate your great help :)

    I think that I missed an important detail in the pre-experiment stage.
    After associating the two Routers (#1 and #2) with the Coordinator, I turned them off (the Coordinator remained ON), and then I firstly turned on Router #2 as shown in the picture (where its out of the RF range of the Coordinator), and then I turned on Router #1 in the midway.

    Could it be that Router #2 became the child of Router #1 and not the child of the Coordinator as it was at first?
    I mean, do routers forget who was their parents when they are turned off and then on again?

  • Since you had the NV_RESTORE option turned on, the Routers would remember who they associated to. Otherwise the normal association process would have taken place. But, since you placed ROuter2 out of RF range of the Coordinator, its messages would have to be relayed through Router1 ... so Router2 would be thinking that it can communicate directly to the Coordinator, when it cannot. You've set up a very strange experiment here ... I'm not sure what it's supposed to tell you.

    Scott