how to change the pan id of a router when it cant find the predefined 64 bit pan id

i have a zb router with a predefined pan id (let’s say 4). it can not find any network with this pan id but can find another network with a different pan id(let’s say 5). how can this router join to that other network without any external user effort. in short how the pan id can be modified through an on air communication with the co-ordinator of the other network.
as i have gone through the user manual, it is not possible for a cordinator having different pan id to communicate with that router.
the at command AI returns 0x22 in the router.
what should i do to set the router parameter in such a way that after some successive trys it automatically set the pan id to 0, through which it can be open to any network.
i have already enable the channel verification & set the watchdog timer to 1

It can’t. For the Coordinator to set the PAN ID on a remote module, the PAN ID must be 0. Then and only then can the coordinator select both the 16 bit and 64 bit PAN ID’s. Otherwise if you set the 16 bit PAN ID, then the Coordinator must use the same 16 bit PAN ID. If then both 16 bit PAN ID’s are the same, the coordinator will set the 64 bit PAN ID during the association process.

1 Like

thanks a lot for the valuable reply. now please tell me if I put the end devices in an open environment(with pan id 0) where several coordinators are working in different pan id then how can I reassure that the end device is connected with the same coordinator after it wakes up. the chances are high for the end device to move into other networks as well if in any circumstance the coordinator is not alive at that time. what should I do to prevent such situation.

That is incorrect. As long as an End device’s sleep times are accounted for on the parent router or coordinator, the end device will not disassociate when it wakes up. It will still be associated to the same network as it was before. There for it will not change networks.

For a device on a zigbee network to change association a qualifying event such as a network reset, PAN ID change, Encryption settings changed or some other event to occur. Simply waking from a sleep state will not cause a network reset for as long as the parents have not forced a disassociation and then filled the child table after the effect with a different end device.