Skip to content
This repository was archived by the owner on Nov 18, 2024. It is now read-only.

Commit c4d8178

Browse files
committed
After a client disconnects, we need to restart advertising or else...
any reconnects by the client will not happen for a very long time.
1 parent 8c4edde commit c4d8178

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

libraries/BLE/src/BLEServer.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,8 @@ void BLEServer::handleGATTServerEvent(esp_gatts_cb_event_t event, esp_gatt_if_t
214214
if(removePeerDevice(param->disconnect.conn_id, false)) {
215215
m_connectedCount--; // Decrement the number of connected devices count.
216216
}
217+
218+
startAdvertising();
217219
break;
218220
} // ESP_GATTS_DISCONNECT_EVT
219221

0 commit comments

Comments
 (0)