From 0646efc2f26adba13c00bc99678fd73788131882 Mon Sep 17 00:00:00 2001 From: Geoffrey Van Landeghem Date: Fri, 13 Sep 2024 16:59:00 +0200 Subject: [PATCH] ZBD distributed TC mode only when TC address is NOT provided --- .../plugin-soc/zigbee_direct_zdd/zigbee_direct_common.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/protocol/zigbee/app/framework/plugin-soc/zigbee_direct_zdd/zigbee_direct_common.c b/protocol/zigbee/app/framework/plugin-soc/zigbee_direct_zdd/zigbee_direct_common.c index 32e561c2c5..66f9b18183 100644 --- a/protocol/zigbee/app/framework/plugin-soc/zigbee_direct_zdd/zigbee_direct_common.c +++ b/protocol/zigbee/app/framework/plugin-soc/zigbee_direct_zdd/zigbee_direct_common.c @@ -778,7 +778,7 @@ static void sli_zigbee_zdd_join_network_write(void) sl_zigbee_direct_network_params.joinMethod = EMBER_USE_CONFIGURED_NWK_STATE; sl_zigbee_direct_network_params.nwkManagerId = 0x0000; // use TC node ID sl_zigbee_direct_security_state.bitmask = (EMBER_STANDARD_SECURITY_MODE | EMBER_HAVE_NETWORK_KEY | EMBER_HAVE_PRECONFIGURED_KEY | EMBER_HAVE_TRUST_CENTER_EUI64); - if (sl_zigbee_tlv_search_buffer_payload_for_id(my_Buffer, 0, SL_ZIGBEE_DIRECT_TLV_TRUST_CENTER_ADDRESS_TAG_ID, (sl_zigbee_tlv_t *) &sl_tlv_pointer1, current_writeValue->len - 1) == EMBER_SUCCESS) { + if (sl_zigbee_tlv_search_buffer_payload_for_id(my_Buffer, 0, SL_ZIGBEE_DIRECT_TLV_TRUST_CENTER_ADDRESS_TAG_ID, (sl_zigbee_tlv_t *) &sl_tlv_pointer1, current_writeValue->len - 1) != EMBER_SUCCESS) { sl_zigbee_direct_security_state.bitmask |= EMBER_DISTRIBUTED_TRUST_CENTER_MODE; sl_zigbee_app_debug_println("Distributed TC mode detected"); }