Hi Mrs. Kolban/Chegewara,
I'm working in a ESP32 BLE Gateway to get characteristics of various servers. These servers are smartbands with heart rate measurement and steps. So, the gateway will able to connect in these devices and read these characteristicas every time that are nearby. That is connections are done and undone everytime (people in and people out). I build the gateway object with BLEDevice::createClient for each device that is detected by the BLEScan. That's OK and devices can connect and disconnect but, at the four cicle of the process of connection, ESP32 freeze the main loop. I have tested events and they continue responding.
Hi Mrs. Kolban/Chegewara, I'm working in a ESP32 BLE Gateway to get characteristics of various servers. These servers are smartbands with heart rate measurement and steps. So, the gateway will able to connect in these devices and read these characteristicas every time that are nearby. That is connections are done and undone everytime (people in and people out). I build the gateway object with BLEDevice::createClient for each device that is detected by the BLEScan. That's OK and devices can connect and disconnect but, at the four cicle of the process of connection, ESP32 freeze the main loop. I have tested events and they continue responding.
Let me show below:
15:12:11.808 -> BLE Main Client 15:12:12.491 -> WiFi: Connecting to SuperLess 15:12:13.478 -> 192.168.1.20 15:12:23.456 -> Scanning... 15:12:23.456 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:12:24.506 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:12:34.487 -> Listing devices: 15:12:54.505 -> Listing devices: 15:13:04.480 -> Scanning... 15:13:04.480 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:13:04.718 -> [D][BLEAdvertisedDevice.cpp:401] setManufacturerData(): - manufacturer data: f0ffe8e9b9b5ad5f 15:13:04.718 -> BLE Advertised Device found: Name: F1, Address: e8:e9:b9:b5:ad:5f, manufacturer data: f0ffe8e9b9b5ad5f 15:13:04.752 -> Add device: e8:e9:b9:b5:ad:5f 15:13:04.752 -> [V][BLEUtils.cpp:1038] dumpGapEvent(): Received a GAP event: ESP_GAP_BLE_SCAN_RESULT_EVT
################################################# Everything is working fine - 1 device detected ################################################# ... 15:13:05.497 -> [D][BLEAdvertisedDevice.cpp:401] setManufacturerData(): - manufacturer data: f0ffd0b2882cae68 15:13:05.497 -> BLE Advertised Device found: Name: F1, Address: d0:b2:88:2c:ae:68, manufacturer data: f0ffd0b2882cae68 15:13:05.497 -> Add device: d0:b2:88:2c:ae:68 15:13:05.497 -> [V][BLEUtils.cpp:1038] dumpGapEvent(): Received a GAP event: ESP_GAP_BLE_SCAN_RESULT_EVT ... 15:13:05.565 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:13:06.547 -> netif: attempt to leave on non-IGMP netif 15:13:15.549 -> Trying to connect: 0 15:13:15.549 -> Do connect to: e8:e9:b9:b5:ad:5f 15:13:15.549 -> Connecting... 15:13:15.549 -> [D][BLEDevice.cpp:66] createClient(): >> createClient ... 15:13:16.800 -> [D][BLEClient.cpp:165] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 4] ... ESP_GATTC_OPEN_EVT 15:13:16.800 -> Connected to server: e8:e9:b9:b5:ad:5f 15:13:16.834 -> onConnect: e8:e9:b9:b5:ad:5f 15:13:16.834 -> [V][FreeRTOS.cpp:120] give(): Semaphore giving: name: OpenEvt (0x3ffee04c), owner: connect ################################################# Everything is working fine - 1 device connected ################################################# ... 15:13:22.084 -> [D][BLEClient.cpp:470] handleGAPEvent(): BLEClient ... handling GAP event! 15:13:27.839 -> Scanning... 15:13:27.839 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) .. 15:13:28.889 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:13:38.884 -> Listing devices: 15:13:38.884 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:13:38.884 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: NO
################################################# Above is a list of the device detected #################################################
15:13:39.868 -> tcp_input 15:13:48.870 -> Trying to connect: 1 15:13:48.870 -> Do connect to: d0:b2:88:2c:ae:68 15:13:48.870 -> Connecting... 15:13:48.870 -> [D][BLEDevice.cpp:66] createClient(): >> createClient ... 15:13:50.935 -> [D][BLEClient.cpp:165] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 5] ... ESP_GATTC_OPEN_EVT 15:13:50.935 -> Connected to server: d0:b2:88:2c:ae:68 15:13:50.935 -> onConnect: d0:b2:88:2c:ae:68 15:13:50.935 -> [V][FreeRTOS.cpp:120] give(): Semaphore giving: name: OpenEvt (0x3ffee0ec), owner: connect ################################################# Here make connection with second device #################################################
... 15:13:55.984 -> [D][BLEClient.cpp:470] handleGAPEvent(): BLEClient ... handling GAP event! 15:14:00.929 -> Listing devices: 15:14:00.929 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:14:00.963 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: YES 15:14:02.957 -> iceto/Desktop/ESP32/ESP32/esp-idf-public/components/lwip/lwip/src/api/tcpip.c 15:14:10.948 -> Scanning... 15:14:10.948 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ######################################################################## Both are connected with BLEDevice::createClient in separated objects ########################################################################
... 15:14:12.001 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: <N/A> 15:14:33.002 -> Scanning... 15:14:33.002 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:14:34.017 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:14:44.036 -> Listing devices: 15:14:44.036 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:14:44.036 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: YES 15:14:45.016 -> callback 15:14:46.678 -> [D][BLEDevice.cpp:154] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 4] ... ESP_GATTC_DISCONNECT_EVT ################################################# Everything is working fine - 2 devices connected #################################################
... 15:14:46.749 -> [V][FreeRTOS.cpp:120] give(): Semaphore giving: name: OpenEvt (0x3ffee0ec), owner: <N/A> 15:14:46.749 -> onDisconnect: d0:b2:88:2c:ae:68 ################################################# Device d0:b2:88:2c:ae:68 leaves area #################################################
15:14:46.749 -> [D][BLEDevice.cpp:154] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 5] ... ESP_GATTC_CLOSE_EVT 15:14:46.749 -> [V][BLEUtils.cpp:1272] dumpGattClientEvent(): GATT Event: ESP_GATTC_CLOSE_EVT 15:14:46.784 -> [D][BLEClient.cpp:165] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 5] ... ESP_GATTC_CLOSE_EVT 15:14:54.027 -> Trying to connect: 1 15:15:04.024 -> Listing devices: 15:15:04.024 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:15:04.024 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: NO 15:15:06.022 -> 15:15:14.018 -> Scanning... 15:15:14.018 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ################################################# Everything is working fine - 1 device connected ################################################# ... 15:15:15.066 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:15:16.081 -> 15:15:36.078 -> Scanning... 15:15:36.078 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:15:37.129 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: <N/A> 15:15:47.100 -> Listing devices: 15:15:47.100 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:15:47.100 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: NO 15:15:48.118 -> 15:15:57.105 -> Trying to connect: 1 15:16:07.123 -> Listing devices: 15:16:07.123 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:16:07.123 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: NO 15:16:09.121 -> 15:16:17.112 -> Scanning... 15:16:17.112 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ################################################# Everything is working fine - 1 device connected ################################################# ... 15:16:17.418 -> [D][BLEAdvertisedDevice.cpp:401] setManufacturerData(): - manufacturer data: f0ffd0b2882cae68 15:16:17.418 -> BLE Advertised Device found: Name: F1, Address: d0:b2:88:2c:ae:68, manufacturer data: f0ffd0b2882cae68 ################################################# Device d0:b2:88:2c:ae:68 return to area #################################################
15:16:17.452 -> [V][BLEUtils.cpp:1038] dumpGapEvent(): Received a GAP event: ESP_GAP_BLE_SCAN_RESULT_EVT ... 15:16:19.144 -> 15:16:39.164 -> Scanning... 15:16:39.164 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:16:39.537 -> [D][BLEAdvertisedDevice.cpp:253] parseAdvertisement(): Type: 0xff (ESP_BLE_AD_MANUFACTURER_SPECIFIC_TYPE), length: 8, data: f0ffd0b2882cae68 15:16:39.537 -> [D][BLEAdvertisedDevice.cpp:401] setManufacturerData(): - manufacturer data: f0ffd0b2882cae68 15:16:39.537 -> BLE Advertised Device found: Name: F1, Address: d0:b2:88:2c:ae:68, manufacturer data: f0ffd0b2882cae68 15:16:39.571 -> [V][BLEUtils.cpp:1038] dumpGapEvent(): Received a GAP event: ESP_GAP_BLE_SCAN_RESULT_EVT ################################################# Sure! Device d0:b2:88:2c:ae:68 return to area #################################################
... 15:16:40.180 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:16:50.191 -> Listing devices: 15:16:50.191 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:16:50.191 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: NO 15:16:51.205 -> ################################################# Here begins the issue --------------------------- #################################################
15:17:00.185 -> Trying to connect: 1 15:17:00.185 -> Do connect to: d0:b2:88:2c:ae:68 15:17:00.185 -> Connecting... 15:17:00.185 -> [D][BLEDevice.cpp:66] createClient(): >> createClient ... 15:17:01.882 -> [D][BLEClient.cpp:165] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 6] ... ESP_GATTC_OPEN_EVT 15:17:01.882 -> Connected to server: d0:b2:88:2c:ae:68 15:17:01.882 -> onConnect: d0:b2:88:2c:ae:68 15:17:01.882 -> [V][FreeRTOS.cpp:120] give(): Semaphore giving: name: OpenEvt (0x3ffefc6c), owner: connect ############################################################### Ok, device d0:b2:88:2c:ae:68 returned to area and is connected ###############################################################
... 15:17:06.959 -> [D][BLEClient.cpp:470] handleGAPEvent(): BLEClient ... handling GAP event! 15:17:11.901 -> Listing devices: 15:17:11.901 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:17:11.901 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: YES 15:17:13.894 -> 15:17:21.884 -> Scanning... 15:17:21.918 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:17:22.935 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:17:32.932 -> Trying to connect: 0 15:17:43.949 -> Scanning... 15:17:43.949 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:17:44.999 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:17:54.993 -> Listing devices: 15:17:54.993 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:17:54.993 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: YES 15:17:55.973 -> sktop/ESP32/ESP32/esp-idf-public/components/lwip/lwip/src/api/sockets.c 15:18:04.996 -> Trying to connect: 1 15:18:14.991 -> Listing devices: 15:18:14.991 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: YES 15:18:14.991 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: YES 15:18:15.126 -> [D][BLEDevice.cpp:154] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 4] ... ESP_GATTC_DISCONNECT_EVT ################################################# Everything is working fine - 2 devices connected ################################################# ... 15:18:15.160 -> [V][FreeRTOS.cpp:120] give(): Semaphore giving: name: OpenEvt (0x3ffee04c), owner: <N/A> 15:18:15.160 -> onDisconnect: e8:e9:b9:b5:ad:5f 15:18:15.160 -> [D][BLEDevice.cpp:154] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 4] ... ESP_GATTC_CLOSE_EVT ################################################# Device e8:e9:b9:b5:ad:5f leaves area ################################################# ...
15:18:15.262 -> [E][BLEClient.cpp:188] gattClientEventHandler(): disconnect event, conn_id: 0 15:18:16.991 -> STEN
15:18:16.991 -> 15:18:24.982 -> Scanning... 15:18:24.982 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:18:26.032 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: <N/A> 15:18:27.014 -> STEN 15:18:27.014 -> 15:18:36.022 -> Trying to connect: 0 15:18:47.041 -> Scanning... 15:18:47.041 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:18:48.058 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:18:58.058 -> Listing devices: 15:18:58.058 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: NO 15:18:58.058 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: YES 15:18:59.074 -> STEN 15:18:59.074 -> 15:19:08.063 -> Trying to connect: 1 15:19:18.068 -> Listing devices: 15:19:18.068 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: NO 15:19:18.068 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: YES 15:19:20.065 -> STEN 15:19:20.065 -> 15:19:28.062 -> Scanning... 15:19:28.062 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ################################################# Everything is working fine - 1 device connected ################################################# ... 15:19:29.114 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:19:30.096 -> STEN 15:19:30.096 -> 15:19:39.093 -> Trying to connect: 0 15:19:50.108 -> Scanning... 15:19:50.108 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) ... 15:19:51.158 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:20:01.152 -> Listing devices: 15:20:01.152 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: NO 15:20:01.152 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: YES 15:20:02.135 -> STEN 15:20:02.135 -> 15:20:11.136 -> Trying to connect: 1 15:20:21.163 -> Listing devices: 15:20:21.163 -> Device name: F1 code: e8:e9:b9:b5:ad:5f Connected: NO 15:20:21.163 -> Device name: F1 code: d0:b2:88:2c:ae:68 Connected: YES 15:20:23.156 -> STEN 15:20:23.156 -> ################################################# HERE is the crash ################################################# 15:20:31.142 -> Scanning... 15:20:31.142 -> [D][BLEScan.cpp:204] start(): >> start(duration=1) 15:20:31.142 -> [D][FreeRTOS.cpp:165] take(): Semaphore taking: name: ScanEnd (0x3ffba674), owner: <N/A> for start 15:20:31.176 -> [D][FreeRTOS.cpp:174] take(): Semaphore taken: name: ScanEnd (0x3ffba674), owner: start 15:20:31.176 -> [D][BLEScan.cpp:236] start(): << start() 15:20:31.176 -> [V][BLEUtils.cpp:1038] dumpGapEvent(): Received a GAP event: ESP_GAP_BLE_SCAN_PARAM_SET_COMPLETE_EVT 15:20:31.176 -> [V][FreeRTOS.cpp:70] wait(): >> wait: Semaphore waiting: name: ScanEnd (0x3ffba674), owner: start for start 15:20:31.176 -> [V][BLEUtils.cpp:1253] dumpGapEvent(): dumpGapEvent: Logger not coded 15:20:31.210 -> [D][BLEClient.cpp:470] handleGAPEvent(): BLEClient ... handling GAP event! 15:20:31.210 -> [V][BLEUtils.cpp:1038] dumpGapEvent(): Received a GAP event: ESP_GAP_BLE_SCAN_START_COMPLETE_EVT 15:20:31.210 -> [V][BLEUtils.cpp:1253] dumpGapEvent(): dumpGapEvent: Logger not coded 15:20:31.210 -> [D][BLEClient.cpp:470] handleGAPEvent(): BLEClient ... handling GAP event! 15:20:31.413 -> [V][BLEUtils.cpp:1038] dumpGapEvent(): Received a GAP event: ESP_GAP_BLE_SCAN_RESULT_EVT 15:20:31.413 -> [V][BLEUtils.cpp:1253] dumpGapEvent(): dumpGapEvent: Logger not coded 15:20:31.413 -> [D][BLEClient.cpp:470] handleGAPEvent(): BLEClient ... handling GAP event! 15:20:31.413 -> [D][BLEAdvertisedDevice.cpp:424] setRSSI(): - setRSSI(): rssi: -44 15:20:31.413 -> [D][BLEAdvertisedDevice.cpp:253] parseAdvertisement(): Type: 0x09 (ESP_BLE_AD_TYPE_NAME_CMPL), length: 2, data: 4631 15:20:31.447 -> [D][BLEAdvertisedDevice.cpp:413] setName(): - setName(): name: F1 15:20:31.447 -> [D][BLEAdvertisedDevice.cpp:253] parseAdvertisement(): Type: 0x01 (ESP_BLE_AD_TYPE_FLAG), length: 1, data: 05 15:20:31.447 -> [D][BLEAdvertisedDevice.cpp:253] parseAdvertisement(): Type: 0xff (ESP_BLE_AD_MANUFACTURER_SPECIFIC_TYPE), length: 8, data: f0ffe8e9b9b5ad5f 15:20:31.481 -> [D][BLEAdvertisedDevice.cpp:401] setManufacturerData(): - manufacturer data: f0ffe8e9b9b5ad5f 15:20:31.481 -> BLE Advertised Device found: Name: F1, Address: e8:e9:b9:b5:ad:5f, manufacturer data: f0ffe8e9b9b5ad5f ################################################# Device e8:e9:b9:b5:ad:5f return to area ################################################# 15:20:31.481 -> [V][BLEUtils.cpp:1038] dumpGapEvent(): Received a GAP event: ESP_GAP_BLE_SCAN_RESULT_EVT 15:20:31.481 -> [V][BLEUtils.cpp:1253] dumpGapEvent(): dumpGapEvent: Logger not coded 15:20:31.515 -> [D][BLEClient.cpp:470] handleGAPEvent(): BLEClient ... handling GAP event! 15:20:31.515 -> [D][BLEScan.cpp:106] handleGAPEvent(): Ignoring e8:e9:b9:b5:ad:5f, already seen it. 15:20:32.159 -> [V][BLEUtils.cpp:1038] dumpGapEvent(): Received a GAP event: ESP_GAP_BLE_SCAN_RESULT_EVT 15:20:32.159 -> [V][BLEUtils.cpp:1253] dumpGapEvent(): dumpGapEvent: Logger not coded 15:20:32.159 -> [D][BLEClient.cpp:470] handleGAPEvent(): BLEClient ... handling GAP event! 15:20:32.192 -> [W][BLEScan.cpp:78] handleGAPEvent(): ESP_GAP_SEARCH_INQ_CMPL_EVT 15:20:32.192 -> [V][FreeRTOS.cpp:120] give(): Semaphore giving: name: ScanEnd (0x3ffba674), owner: start 15:20:32.192 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: ScanEnd (0x3ffba674), owner: start 15:20:33.205 -> wrapped rcv_wnd 15:20:33.205 -> 15:20:42.176 -> Trying to connect: 0 15:20:42.176 -> Do connect to: e8:e9:b9:b5:ad:5f 15:20:42.210 -> Connecting... ################################################# Try to connect e8:e9:b9:b5:ad:5f but... ################################################# 15:20:42.210 -> [D][BLEDevice.cpp:66] createClient(): >> createClient 15:20:42.210 -> [D][BLEDevice.cpp:72] createClient(): << createClient 15:20:42.210 -> [D][BLEClient.cpp:103] connect(): >> connect(e8:e9:b9:b5:ad:5f) 15:20:42.210 -> [I][BLEDevice.cpp:600] addPeerDevice(): add conn_id: 3, GATT role: client 15:20:42.210 -> [D][FreeRTOS.cpp:165] take(): Semaphore taking: name: RegEvt (0x3fff14f8), owner: <N/A> for connect 15:20:42.244 -> [D][FreeRTOS.cpp:174] take(): Semaphore taken: name: RegEvt (0x3fff14f8), owner: connect 15:20:42.244 -> [V][FreeRTOS.cpp:70] wait(): >> wait: Semaphore waiting: name: RegEvt (0x3fff14f8), owner: connect for connect 15:20:42.244 -> [D][BLEDevice.cpp:154] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 0] ... ESP_GATTC_REG_EVT 15:20:42.244 -> [V][BLEUtils.cpp:1272] dumpGattClientEvent(): GATT Event: ESP_GATTC_REG_EVT 15:20:42.278 -> [D][BLEClient.cpp:165] gattClientEventHandler(): gattClientEventHandler [esp_gatt_if: 0] ... ESP_GATTC_REG_EVT 15:20:42.278 -> [I][BLEClient.cpp:233] gattClientEventHandler(): register app id: 3, 3, gattc_if: 0 15:20:42.278 -> [V][FreeRTOS.cpp:120] give(): Semaphore giving: name: RegEvt (0x3fff14f8), owner: connect 15:20:42.278 -> [V][FreeRTOS.cpp:86] wait(): << wait: Semaphore released: name: RegEvt (0x3fff14f8), owner: connect 15:20:42.312 -> [D][FreeRTOS.cpp:165] take(): Semaphore taking: name: OpenEvt (0x3ffefd04), owner: <N/A> for connect 15:20:42.312 -> [D][FreeRTOS.cpp:174] take(): Semaphore taken: name: OpenEvt (0x3ffefd04), owner: connect 15:20:42.312 -> [V][FreeRTOS.cpp:70] wait(): >> wait: Semaphore waiting: name: OpenEvt (0x3ffefd04), owner: connect for connect ############################################################ Code stops here, loop stops but event from disconnet works ############################################################ 15:21:55.122 -> onDisconnect:d0:b2:88:2c:ae:68 <-Here a turn off the other device ############################################################
Can you help me? Best regards,
Robson