mirror of
https://github.com/espressif/esp-idf.git
synced 2026-08-18 06:35:35 +03:00
fix(nimble): Improve safety, fix bugs, and update docs across NimBLE examples
- Remove unused headers from examples - Improve periodic adv/sync example functionality and readability - Use ble_hs_id_infer_auto() instead of hardcoded BLE_OWN_ADDR_PUBLIC/RANDOM - Add ble_hs_util_ensure_addr() calls in on_sync for proper address setup - Use correct ext adv instance (0 instead of 1) in phy_prph, l2cap_coc, multi_conn - Fix struct name: ble_gap_periodic_adv_enable_params -> ble_gap_periodic_adv_start_params - Add CONFIG_BT_NIMBLE_GAP_SERVICE guards around ble_svc_gap_device_name_set - Fix unsafe AD data parsing with bounds checks in central examples - Fix UUID matching bugs (off-by-one loop condition and byte order) in phy_cent, htp_cent, and proximity_sensor_cent - Fix ble_multi_conn_cent address type to use dynamic inference - Remove contradictory sm_sc=0 after sm_sc=1 in ble_multi_adv - Add CONFIG_BT_NIMBLE_EXT_ADV=y to ble_multi_adv sdkconfig defaults - Check return values for ble_gap_set_host_feat, nimble_port_init - Update tutorials and READMEs to match code changes
This commit is contained in:
@@ -1,15 +1,10 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2021-2025 Espressif Systems (Shanghai) CO LTD
|
||||
* SPDX-FileCopyrightText: 2021-2026 Espressif Systems (Shanghai) CO LTD
|
||||
*
|
||||
* SPDX-License-Identifier: Unlicense OR CC0-1.0
|
||||
*/
|
||||
|
||||
#include <assert.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include "host/ble_hs.h"
|
||||
#include "host/ble_uuid.h"
|
||||
#include "esp_central.h"
|
||||
|
||||
/**
|
||||
* Utility function to log an array of bytes.
|
||||
|
||||
@@ -4,8 +4,6 @@
|
||||
* SPDX-License-Identifier: Unlicense OR CC0-1.0
|
||||
*/
|
||||
|
||||
#include <assert.h>
|
||||
#include <string.h>
|
||||
#include "host/ble_hs.h"
|
||||
#include "esp_central.h"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user