diff --git a/example/hog_boot_host_demo.c b/example/hog_boot_host_demo.c index de35cf27d..40d509918 100644 --- a/example/hog_boot_host_demo.c +++ b/example/hog_boot_host_demo.c @@ -514,6 +514,7 @@ static void packet_handler (uint8_t packet_type, uint16_t channel, uint8_t *pack sm_request_pairing(connection_handle); break; case HCI_EVENT_ENCRYPTION_CHANGE: + case HCI_EVENT_ENCRYPTION_CHANGE_V2: if (connection_handle != hci_event_encryption_change_get_connection_handle(packet)) break; printf("Connection encrypted: %u\n", hci_event_encryption_change_get_encryption_enabled(packet)); if (hci_event_encryption_change_get_encryption_enabled(packet) == 0){ diff --git a/example/hog_host_demo.c b/example/hog_host_demo.c index ab6734602..45eb49f11 100644 --- a/example/hog_host_demo.c +++ b/example/hog_host_demo.c @@ -427,6 +427,7 @@ static void packet_handler (uint8_t packet_type, uint16_t channel, uint8_t *pack sm_request_pairing(connection_handle); break; case HCI_EVENT_ENCRYPTION_CHANGE: + case HCI_EVENT_ENCRYPTION_CHANGE_V2: if (connection_handle != hci_event_encryption_change_get_connection_handle(packet)) break; printf("Connection encrypted: %u\n", hci_event_encryption_change_get_encryption_enabled(packet)); if (hci_event_encryption_change_get_encryption_enabled(packet) == 0){ diff --git a/example/sm_pairing_central.c b/example/sm_pairing_central.c index 4abc20d19..3234f3110 100644 --- a/example/sm_pairing_central.c +++ b/example/sm_pairing_central.c @@ -213,7 +213,8 @@ static void hci_packet_handler(uint8_t packet_type, uint16_t channel, uint8_t *p // general gatt client request to trigger mandatory authentication // gatt_client_discover_primary_services(&hci_packet_handler, con_handle); break; - case HCI_EVENT_ENCRYPTION_CHANGE: + case HCI_EVENT_ENCRYPTION_CHANGE: + case HCI_EVENT_ENCRYPTION_CHANGE_V2: con_handle = hci_event_encryption_change_get_connection_handle(packet); printf("Connection encrypted: %u\n", hci_event_encryption_change_get_encryption_enabled(packet)); break;