This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

[nRF52840 + zigbee ] ZED cannot join to ZC sometimes.

Hi,

I am on  verifying long run test.

environment

SDK : v3.1.0

PS storage : not erase (ZB_FALSE);      ==> zigbee_erase_persistent_storage(ZB_FALSE);

ZC ---------------------------------ZED

Phenomenon:

I reset ZED continuously.

ZED joins ZC well most of the tries.

but sometimes, it fails.

After fails, ZC should be reset. (ZED reset cannot recover the operation).

From  no 7965, abnormal state logging.

No 7729 to no 7964 shows normal operation.

Board parameter is not changed between the trials.

I attached wireshark logging file.

Please check and give solutions.

If you cannot give the reason of the abnormal operation, 

let me know how ZC can detect this situation.

If ZC can detect this it can restart.

Thanks.

join_error_7965.pcapng

Parents
  • Hi,

    I will need to consult with our developers about this issue. Please be patient.

    Best regards,

    Marjeris

  • Hi,

    Is there no news about the problem?

    The problem occures frequently when ZC's turn on time is long.(one day or more).

  • Hi,

    Sorry for the late reply, I should have asked about this before, but could you provide network key or other security material, so we can decipher the traffic dump?

    And are there any multiprotocol devices involved?

  • I missed your reply. and i didnot solve the problem yet.

    I don't use multiprotocol.

    I modified the bulb example.

    I modified ZB_ZCL_ON_OFF_SEND_REQ macro to carry user data(16 bytes) as follows.

    ZED wakes up and send ZB_ZCL_ON_OFF_SEND_REQ when external event(door open interrupt)

    and enter system off.

    ZED runs well without fails but ZC somethimes get strange signal and can not accept more 

    join request.

    I expained this first post.

    #define my_ZB_ZCL_ON_OFF_SEND_REQ(node_msg, \
    buffer, addr, dst_addr_mode, dst_ep, ep, prof_id, dis_default_resp, command_id, cb) \
    { \
    zb_uint8_t* ptr = ZB_ZCL_START_PACKET_REQ(buffer) \
    ZB_ZCL_CONSTRUCT_SPECIFIC_COMMAND_REQ_FRAME_CONTROL(ptr, dis_default_resp) \
    ZB_ZCL_CONSTRUCT_COMMAND_HEADER_REQ(ptr, ZB_ZCL_GET_SEQ_NUM(), command_id); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[0]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[1]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[2]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[3]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[4]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[5]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[6]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[7]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[8]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[9]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[10]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[11]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[12]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[13]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[14]); \
    ZB_ZCL_PACKET_PUT_DATA8(ptr, node_msg[15]); \
    ZB_ZCL_FINISH_PACKET(buffer, ptr) \
    ZB_ZCL_SEND_COMMAND_SHORT( \
    buffer, addr, dst_addr_mode, dst_ep, ep, prof_id, ZB_ZCL_CLUSTER_ID_ON_OFF , cb); \
    }

  • embedholic said:
    ZED runs well without fails but ZC somethimes get strange signal and can not accept more 

     Which strange signal?

    The sniffer log you provided had some encrypted payload we could not decipher since you didn't provide a network key.

    You can also try to start sniffing before the new network is formed.

  • Could you let me know what the network key is ?

    Do you mean "start sniffing before the new network is formed"  that i shall run wireshark before ZC start with zigbee_erase_persistent_storage TRUE?

    I will try tha again.

    Thanks.

  • You should start sniffing before the TC link key exchange between the two nodes, Wireshark will then automatically decode the packets after the joining process is completed.

    Please take a look at section 10.3.2 Adding a new node into the network in the Zigbee Base Device Specification for more information about how the TC link key exchange happens. See item 5 and 6 under section 10.3.2:

    5. If bdbJoinUsesInstallCodeKey is equal to FALSE and bdbJoiningNodeEui64 does not correspond to an entry in apsDeviceKeyPairSet, the Trust Center SHALL add an entry into its AIB apsDeviceKeyPairSet with the DeviceAddress parameter set to bdbJoiningNodeEui64 and the LinkKey value set to the default global Trust Center link key (“ZigBeeAlliance09”).

    a. The apsLinkKeyType of that entry SHALL be set to 0x01 (Global). See Table 4.39 in [R1].

    6. The Trust Center SHALL transport the network key to the joining node by issuing the APSME-TRANSPORT-KEY.request primitive to the APSME encrypted with the LinkKey value of the apsDeviceKeyPairSet entry corresponding to the joining node.

    When sniffing you can take a look at the Zigbee Security Header inside a packet after joining procedure, also take a look at the content on the Transport Key frame.

Reply
  • You should start sniffing before the TC link key exchange between the two nodes, Wireshark will then automatically decode the packets after the joining process is completed.

    Please take a look at section 10.3.2 Adding a new node into the network in the Zigbee Base Device Specification for more information about how the TC link key exchange happens. See item 5 and 6 under section 10.3.2:

    5. If bdbJoinUsesInstallCodeKey is equal to FALSE and bdbJoiningNodeEui64 does not correspond to an entry in apsDeviceKeyPairSet, the Trust Center SHALL add an entry into its AIB apsDeviceKeyPairSet with the DeviceAddress parameter set to bdbJoiningNodeEui64 and the LinkKey value set to the default global Trust Center link key (“ZigBeeAlliance09”).

    a. The apsLinkKeyType of that entry SHALL be set to 0x01 (Global). See Table 4.39 in [R1].

    6. The Trust Center SHALL transport the network key to the joining node by issuing the APSME-TRANSPORT-KEY.request primitive to the APSME encrypted with the LinkKey value of the apsDeviceKeyPairSet entry corresponding to the joining node.

    When sniffing you can take a look at the Zigbee Security Header inside a packet after joining procedure, also take a look at the content on the Transport Key frame.

Children
No Data
Related