When you change the PAN ID on a coordinator, it's shutting down one network (disassociation) and then creating another (coordinator started). You then need to wait for nodes to join that new network before you can discover them. It doesn't make sense to perform node discovery on a device that isn't currently joined to a network.
If you set ATJN
to 1
on the coordinator, the host will receive Join Notification frames (type 0xA5
) as devices join the network. Maybe this is what you're looking for?