We are currently maintaining a Zigbee controller out of JN5169.
We are using the JN-SW-4170 SDK.
We have of course a good understanding of JN-AN-1216
Application Note: JN-AN-1216 ZigBee 3.0 IoT Control Bridge,
Is there a simple way to query the stack to know if there is any room left to allow a new association ?
can we get the current size of the Trust Center , in order to know if there is room ?
can we get the current child size ?
is there any other table which could prevent an association ?
Hi @zigbee1,
Please look at the vDisplayTableSizes function that is implemented appZpsExtendedDebug.c file
"C:\NXP\bstudio_nxp\sdk\JN-SW-4170\Components\ZigbeeCommon\Source\appZpsExtendedDebug.c"
Regards,
Mario
so there is no real life possibility ? I don't want to use a debug version for production .
Hi @zigbee1,
The function provides the way how to read out the structure for the table sizes. You could copy the implementation.
void * thisNet = ZPS_pvAplZdoGetNwkHandle();
thisNib = ZPS_psNwkNibGetHandle(thisNet);
and the structure.
typedef struct
{
uint16 u16NtActv; /**< nwkNeighborTable (active) size */
uint16 u16Rt; /**< nwkRouteTable size */
uint16 u16Rct; /**< nwkRouteRecordTable size */
uint16 u16AddrMap; /**< nwkAddressMap size */
uint8 u8NtDisc; /**< nwkNeighborTable (discovery) size */
uint8 u8RtDisc; /**< Route discovery table (not strictly NIB) */
uint8 u8Btt; /**< nwkBroadcastTransactionTable size */
uint8 u8SecMatSet; /**< nwkSecurityMaterialSet size */
uint8 u8NibDefault; /** size of the nib default struct **/
uint8 u8ChildTable;
uint16 u16MacAddTableSize;
} ZPS_tsNwkNibTblSize;
Hope it helps.
Regards,
Mario
Hi @zigbee1,
I hope you are doing great.
What do you mean by "if there is any room left to allow a new association"?
You set the child table size on the zpscfg.
Could you please explain in more details your requirement?
Regard,
Mario
What can I say more .
How can we now that the controller (or the network) is full and cannot accept a new device.
Like but not limited:
the Trust Center is Full
the controller child table is full
the other routers don't have more capacity
...