From 62e3f414a1abbf37f02dbae9faf2c2e37c1b0705 Mon Sep 17 00:00:00 2001 From: luoxu Date: Tue, 25 Jun 2024 15:02:11 +0800 Subject: [PATCH] feat(ble_mesh): mesh lib update to aff87bf33a --- components/bt/esp_ble_mesh/lib/ext.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/components/bt/esp_ble_mesh/lib/ext.c b/components/bt/esp_ble_mesh/lib/ext.c index ca77996076..1c8dfed3f5 100644 --- a/components/bt/esp_ble_mesh/lib/ext.c +++ b/components/bt/esp_ble_mesh/lib/ext.c @@ -1,5 +1,5 @@ /* - * SPDX-FileCopyrightText: 2023 Espressif Systems (Shanghai) CO LTD + * SPDX-FileCopyrightText: 2023-2024 Espressif Systems (Shanghai) CO LTD * * SPDX-License-Identifier: Apache-2.0 */ @@ -8,6 +8,8 @@ #include #include +#include "esp_log.h" + #if CONFIG_BT_BLUEDROID_ENABLED #include "bta/bta_api.h" #endif @@ -190,6 +192,11 @@ void bt_mesh_ext_mem_swap(void *buf, size_t length) sys_mem_swap(buf, length); } +uint32_t bt_mesh_ext_log_timestamp(void) +{ + return esp_log_timestamp(); +} + /* Net buf */ void bt_mesh_ext_buf_simple_init(struct net_buf_simple *buf, size_t reserve_head) { @@ -498,6 +505,11 @@ float bt_mesh_ext_log2(float num) return bt_mesh_log2(num); } +const char *bt_mesh_ext_hex(const void *buf, size_t len) +{ + return bt_hex(buf, len); +} + /* Crypto */ bool bt_mesh_ext_s1(const char *m, uint8_t salt[16]) { @@ -3954,6 +3966,8 @@ void bt_mesh_ext_mbt_server_cb_evt_to_btc(uint8_t event, void *model, void *ctx) } typedef struct { + uint64_t config_ble_mesh_stack_trace_level : 3; + uint64_t config_ble_mesh_use_duplicate_scan : 1; uint64_t config_ble_mesh_pb_adv : 1; uint64_t config_ble_mesh_pb_gatt : 1; @@ -4116,6 +4130,8 @@ typedef struct { } bt_mesh_ext_config_t; static const bt_mesh_ext_config_t bt_mesh_ext_cfg = { + .config_ble_mesh_stack_trace_level = BLE_MESH_LOG_LEVEL, + .config_ble_mesh_use_duplicate_scan = IS_ENABLED(CONFIG_BLE_MESH_USE_DUPLICATE_SCAN), .config_ble_mesh_pb_adv = IS_ENABLED(CONFIG_BLE_MESH_PB_ADV), .config_ble_mesh_pb_gatt = IS_ENABLED(CONFIG_BLE_MESH_PB_GATT),