Janell Armstrong

[Beestack and MC1321x] gZbAddrMode16Bit_c addressing

Discussion created by Janell Armstrong on Mar 7, 2008
Latest reply on Mar 28, 2008 by Janell Armstrong
Three questions.

1) How does a coordinator obtain the network address of a router?

2) How does a router obtain the network address of the coordinator? (I think this is just 0 by default, but I'm uncertain I understood the document corectly.)

3) How does a router obtain the network address of another router?

I've read through the BSSRM, yet I haven't managed to identify the missing element of using gZbAddrMode16Bit_c addressing necessary to actually transmitting packets between two devices.

I have an NCB as the coordinator which creates a ZigBee networking using ZDO_Start(gStartWithOutNvm_c). Likewise, the routers of the network join the network using ZDO_Start(gStartWithOutNvm_c). There are no endpoints in my network.

To send a datagram on both the Coordinator and Router I am using the addressing configuration:

  afAddrInfo_t addrInfo;

  //set address information  FLib_MemSet(&addrInfo, 0, sizeof(addrInfo));  Copy2Bytes(addrInfo.dstAddr.aNwkAddr, addressWhereverIGoToWhateverItIs);  addrInfo.dstAddrMode = gZbAddrMode16Bit_c;  addrInfo.dstEndPoint = appEndPoint;  addrInfo.srcEndPoint = appEndPoint;  addrInfo.txOptions = gApsTxOptionNone_c;  addrInfo.radiusCounter = afDefaultRadius_c; //twice the network depth (how far to send packet before packet expires)   //set cluster information  addrInfo.aClusterId[0] = (mDataClusterId_c & 0xFF); //customized cluster  addrInfo.aClusterId[1] = (mDataClusterId_c >> 8);