From 1287237b8a9c47f6e54529885c7594f12a61a3b7 Mon Sep 17 00:00:00 2001 From: hathach Date: Mon, 9 Oct 2017 20:52:23 +0700 Subject: [PATCH] fix discover characteristic bug --- libraries/Bluefruit52Lib/src/BLEDiscovery.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/Bluefruit52Lib/src/BLEDiscovery.cpp b/libraries/Bluefruit52Lib/src/BLEDiscovery.cpp index 00e55905..0d22f948 100644 --- a/libraries/Bluefruit52Lib/src/BLEDiscovery.cpp +++ b/libraries/Bluefruit52Lib/src/BLEDiscovery.cpp @@ -140,7 +140,7 @@ uint8_t BLEDiscovery::discoverCharacteristic(uint16_t conn_handle, BLEClientChar ble_gattc_handle_range_t range = { disc_chr->chars[d].handle_value + 1, _hdl_range.end_handle }; // Discovery All descriptors if possible - if ( range.start_handle <= range.start_handle ) + if ( range.start_handle <= range.end_handle ) { // skip discovery descriptor chr[i]->discoverDescriptor(conn_handle, range);