Page 1 of 1

BLE_notify demo stuck after less than a minute, and then disconnect

Posted: Thu Sep 27, 2018 8:44 am
by trustmiao
We are testing the BLE_notify example. We tested with two means of connection, from a ESP32 running BLE_client without turning on/off notification, and it will stuck. We also tested connection from "nRF connect" from an iphone, it also stuck.
Any hint?

I was thinking if BLE_notify can't work in 100fps, then the demo won't be there. If we with to transfer 10bytes in 100fps, what will be prefered? Notify or write?

Thanks for any input.

Re: BLE_notify demo stuck after less than a minute, and then disconnect

Posted: Thu Sep 27, 2018 8:59 am
by trustmiao
We 've tested write, it works for 300 seconds sofar without disconnection, sending bytes every 10 ms.

Re: BLE_notify demo stuck after less than a minute, and then disconnect

Posted: Thu Sep 27, 2018 10:37 am
by chegewara
At first try to add this function to your code when you are connected:
https://docs.espressif.com/projects/esp ... t8uint16_t

The problem is that code required to use it is implemented in cpp_utils, but is not pushed to ble arduino library (you will need to alter BLEServer).
Another thing is congestion, check your logs to see if you have ESP_GATTS_CONGEST_EVT.