You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if (ret == ESP_ERR_NVS_NO_FREE_PAGES || ret == ESP_ERR_NVS_NEW_VERSION_FOUND){
14
+
ESP_ERROR_CHECK(nvs_flash_erase());
15
+
ret = nvs_flash_init();
16
+
}
17
+
ESP_ERROR_CHECK(ret);
18
+
19
+
nimble_port_init();
20
+
/*Initialize the NimBLE host configuration.*/
21
+
ble_hs_cfg.sync_cb = bleprhp_on_sync;
22
+
ble_hs_cfg.reset_cb = bleprhp_on_reset;
23
+
/*Security Manager local input output capabilities*/
24
+
ble_hs_cfg.sm_io_cap = BLE_SM_IO_CAP_DISP_YES_NO;
25
+
/*security Manager bond flag
26
+
if set proper flag in Pairing request/response will be set. This results in storing keys distributed during bonding.*/
27
+
ble_hs_cfg.sm_bonding = 1;
28
+
/*security manager mitm flag
29
+
if set proper flag in pairing request/response will be set. This results in requiring man-in-the-middle protection when pairing.*/
30
+
ble_hs_cfg.sm_mitm = 1;
31
+
/*Security Manager secure connections flag
32
+
if set proper flag in pairing request/response will be set. this results in using LE Secure Connections for pairing if also supported by remote device. Fallback to legacy pairing if not supported by remote.*/
0 commit comments