apps/blemesh: Add option to enable Mesh persistent storage

This commit is contained in:
Michał Narajowski
2018-07-09 14:23:15 +02:00
parent e32e2c83de
commit ada0e731e6
2 changed files with 12 additions and 1 deletions
+9 -1
View File
@@ -136,7 +136,7 @@ fault_test(struct bt_mesh_model *model, uint8_t test_id, uint16_t company_id)
recent_test_id = test_id;
has_reg_fault = true;
bt_mesh_fault_update(model->elem);
bt_mesh_fault_update(bt_mesh_model_elem(model));
return 0;
}
@@ -405,6 +405,14 @@ blemesh_on_sync(void)
#endif
console_printf("Mesh initialized\n");
if (IS_ENABLED(CONFIG_SETTINGS)) {
settings_load();
}
if (bt_mesh_is_provisioned()) {
printk("Mesh network restored from flash\n");
}
}
int
+3
View File
@@ -46,3 +46,6 @@ syscfg.vals:
BLE_MESH_DEBUG_LOW_POWER: 1
BLE_MESH_DEBUG_FRIEND: 1
BLE_MESH_DEBUG_PROXY: 1
BLE_MESH_SETTINGS: 0
CONFIG_NFFS: 0