Commit 37f22128 authored by schneider's avatar schneider
Browse files

fix(ble): Forward DM_CONN_CLOSE_IND to pycardium

Closes #237
parent a6be367f
Pipeline #5304 passed with stages
in 1 minute and 10 seconds
......@@ -58,10 +58,6 @@ void ble_epic_ble_api_trigger_event(enum epic_ble_event_type type, void *data)
if (dm_event->hdr.event == DM_CONN_OPEN_IND) {
connection_open = true;
}
if (dm_event->hdr.event == DM_CONN_CLOSE_IND) {
connection_open = false;
}
}
if (!connection_open &&
......@@ -90,6 +86,13 @@ void ble_epic_ble_api_trigger_event(enum epic_ble_event_type type, void *data)
} else {
epic_ble_free_event(&e);
}
if (type == BLE_EVENT_DM_EVENT) {
dmEvt_t *dm_event = data;
if (dm_event->hdr.event == DM_CONN_CLOSE_IND) {
connection_open = false;
}
}
}
int epic_ble_get_event(struct epic_ble_event *e)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment