From ae079c1fc5d990ba55714d4b3a51b19f96edaec4 Mon Sep 17 00:00:00 2001 From: WXK <287788329@qq.com> Date: 星期四, 24 四月 2025 16:01:43 +0800 Subject: [PATCH] 改为中断来低电平触发发送当前扫描数据,3s内扫描不到的会退出,串口来55 AA 75 70 64 61 74 65,进入升级模式 --- 01_SDK/nimble/host/nimble/nimble/host/src/ble_sm.c | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) diff --git a/01_SDK/nimble/host/nimble/nimble/host/src/ble_sm.c b/01_SDK/nimble/host/nimble/nimble/host/src/ble_sm.c index 37ca644..536bc02 100644 --- a/01_SDK/nimble/host/nimble/nimble/host/src/ble_sm.c +++ b/01_SDK/nimble/host/nimble/nimble/host/src/ble_sm.c @@ -40,6 +40,7 @@ * o A proc entry is read from or written to. * o The proc list is read or modified. */ +#pragma diag_suppress 111 #include <string.h> #include <errno.h> @@ -2913,7 +2914,11 @@ int rc; handle = ble_l2cap_get_conn_handle(chan); +#if NIMBLE_BUG_FIXED_EN + if(handle == BLE_HS_CONN_HANDLE_NONE){ +#else if (!handle) { +#endif return BLE_HS_ENOTCONN; } -- Gitblit v1.9.3