I am using Neil Kolban's cpp_utils from his esp32-snippets github repository for BLE (with esp-idf). In my project the esp32 acts as a server, sending notifications to an central device. It is based on Kolbans BLE example "SampleNotify" using the "pCharacteristic->notify()" method.
The program works fine as long as the client is near by the ESP32, but when it is going to get out of reach, then I got an error massage "esp_ble_gatts_send_ notify: rc=-1 Unknown ESP_ERR error". This seems to be due to the method "esp_ble_gatts_send_indicate" in "esp_gatts_api.h".
I still wonder about this, because I thought using notifications the server doesn't care about whether a client is listening or not. And what is more, I do not have any idea how to handle this error massage. Is there any method to detect if the client is "connected" or nearby? This error only occur when I send more then 10-20 notifications in a second (I want to submit an ECG with 125-250 samples per second
![Wink ;-)](./images/smilies/icon_e_wink.gif)
Does anyone have an idea how to proceed with this error?
Thanks, JJens