NimBLE-Arduino
NimBLE-Arduino copied to clipboard
How to stop a service?
There is a bool NimBLEService::start()
But no bool NimBLEService::stop(), unlike the nkolban version.
How does one stop a service?
The NimBLE stack does not support stopping a service the way the bluedroid stack does. Instead it can "hide" it or delete it completely. For this to work advertising must be stopped first.
The function to do this is in NimBLEServer:
void NimBLEServer::removeService(NimBLEService* service, bool deleteSvc = false);
@h2zero except this appears not to work.. see #541