Closed Pasikav closed 3 weeks ago
You're getting reconnected because the advertising was automatically started after disconnect. You'll want to change that setting to prevent that.
But if i don't start advertising wouldn't my device be invisible for other clients or my understanding of advertising is wrong?
Sorry, the answer here is to advertise with a whitelist so that only bonded peers can connect. Entering "pairing mode" would be advertising without the whitelist.
Its more of a question than issue!
I have ESP32 project nimBLE. Basically my device is BLE Keyboard. One of the functionality is to disconnect from Server side (esp32).
I made it to the point that I disconnect device using
pServer->disconnect(this->connHandle);
and then clear ble store usingble_store_clear()
. From the perspective of server it works fine, there is no connection but client side (windows computer) is still trying to connect, so there is no clear indication that there is no connection and also while debugging i noticed it triggers onConnect event.What i would like to achieve is something alike pairing mode in bluetooth headset when if you set it on pairing mode the connection is made only on client request. Is it even possible using BLE?