re-advertise on disconnect
This commit is contained in:
parent
c496f27222
commit
0dbf5aae0e
@ -225,6 +225,9 @@ static int ble_gap_event(struct ble_gap_event *event, void* arg){
|
|||||||
else
|
else
|
||||||
conn_handle = event->connect.conn_handle;
|
conn_handle = event->connect.conn_handle;
|
||||||
break;
|
break;
|
||||||
|
case BLE_GAP_EVENT_DISCONNECT:
|
||||||
|
ble_advertise();
|
||||||
|
break;
|
||||||
case BLE_GAP_EVENT_SUBSCRIBE:
|
case BLE_GAP_EVENT_SUBSCRIBE:
|
||||||
ESP_LOGI(TAG, "Subscribe %d", event->subscribe.attr_handle);
|
ESP_LOGI(TAG, "Subscribe %d", event->subscribe.attr_handle);
|
||||||
for(int i = 0; i < INPUTS_NUM; i++){
|
for(int i = 0; i < INPUTS_NUM; i++){
|
||||||
|
Loading…
x
Reference in New Issue
Block a user