Hello all,
I'm using ble_wifi_provisioning example.
I need to save the phone pairing.
I added the definitions as described here:
https://academy.nordicsemi.com/courses/bluetooth-low-energy-fundamentals/lessons/lesson-5-bluetooth-le-security-fundamentals/topic/blefund-lesson-5-exercise-2/
CONFIG_SETTINGS=y
CONFIG_BT_SETTINGS=y
CONFIG_FLASH=y
CONFIG_FLASH_PAGE_LAYOUT=y
CONFIG_FLASH_MAP=y
CONFIG_NVS=y
CONFIG_BT_MAX_CONN=1
CONFIG_BT_MAX_PAIRED=5
In main.c I call:
rc = bt_enable(NULL);
if (rc) {
printk("Bluetooth init failed (err %d).\n", rc);
return 0;
}
if (IS_ENABLED(CONFIG_SETTINGS)) {
settings_load();
}
When I run the code, the device returns this error:
Bluetooth init failed (err -5)
I tried several combinations, but I couldn’t solve the problem.
Can you help me?
Thanks in advance to everyone.