Part Number:CC2538
Hello,
Using CC2538, with Z-Stack Mesh v1.0.0 due to compatibility reasons.
I have already a ZC that creates a network and then I connect a ZR. To do this test I have used the GenericApp example of the library.
I have used HOLD_AUTO_START to perform a network connection at application level. Moreover I don’t want to use NV network parameters so I set the NV flag to force a new join if the NV_RESTORE is defined. As specified in documentation (Z-Stack Developer’s Guide - SWRA176) NV_RESTORE must be always enabled in a real ZigBee network. So I added these two lines just at the end of the function GenericApp_Init() of GenericApp.c.
zgWriteStartupOptions( ZG_STARTUP_SET, (ZCD_STARTOPT_DEFAULT_NETWORK_STATE | ZCD_STARTOPT_DEFAULT_CONFIG_STATE) );
ZDOInitDevice(0);
First time, the ZR connects successfully to the network that ZC has created. But when the router is reset, no beacon request is seen neither attempt to reconnect.
If I restart the node again, it perform the connection successfully. And again, if I restart the node, no attempt to reconnect is seen. Therefore, every two resets ZR doesn’t connect to the network.
I debug the code and seems that in the function ZDO_StartDevice() from ZDObject.c, NLME_NetworkDiscoveryRequest() returns ZNwkInvalidRequest every two resets.
I don’t know what I am doing wrong, I only want a node that connects not automatically to a network without using the NV network parameters.
Anyone could explain me why all this is happening?
Thanks.
Melvin.
I have already a ZC that creates a network and then I connect a ZR. To do this test I have used the GenericApp example of the library.
I have used HOLD_AUTO_START to perform a network connection at application level. Moreover I don’t want to use NV network parameters so I set the NV flag to force a new join if the NV_RESTORE is defined. As specified in documentation (Z-Stack Developer’s Guide - SWRA176) NV_RESTORE must be always enabled in a real ZigBee network. So I added this two lines just at the end of the function GenericApp_Init() of GenericApp.c.
zgWriteStartupOptions( ZG_STARTUP_SET, (ZCD_STARTOPT_DEFAULT_NETWORK_STATE | ZCD_STARTOPT_DEFAULT_CONFIG_STATE) );
ZDOInitDevice(0);
First time, the ZR connects successfully to the network that ZC has created. But when the router is reset, no beacon request is seen neither attempt to reconnect.
If I restart the node again, it perform the connection successfully. And again, if I restart the node, no attempt to reconnect is seen. Therefore, every two resets ZR doesn’t connect to the network.
I debug the code and seems that in the function ZDO_StartDevice() from ZDObject.c, NLME_NetworkDiscoveryRequest() returns ZNwkInvalidRequest every two resets.
I don’t know what I am doing wrong, I only want a node that connects not automatically to a network without using the NV parameters.
Anyone could explain me why all this is happening?
Thanks.
Melvin.