Skip to content

Commit

Permalink
fix(ble_mesh): fixed heartbeat issue
Browse files Browse the repository at this point in the history
(cherry picked from commit 167cd47)

Co-authored-by: luoxu <luoxu@espressif.com>
  • Loading branch information
forx157 committed Nov 15, 2024
1 parent 94250f0 commit 7fccbcf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion components/bt/esp_ble_mesh/mesh_core/settings.c
Original file line number Diff line number Diff line change
Expand Up @@ -1422,6 +1422,8 @@ int settings_core_commit(void)
struct bt_mesh_hb_pub *hb_pub = NULL;
struct bt_mesh_cfg_srv *cfg = NULL;

bt_mesh_atomic_set_bit(bt_mesh.flags, BLE_MESH_VALID);

hb_pub = bt_mesh_hb_pub_get();
if (hb_pub && hb_pub->dst != BLE_MESH_ADDR_UNASSIGNED &&
hb_pub->count && hb_pub->period) {
Expand All @@ -1440,7 +1442,6 @@ int settings_core_commit(void)
cfg->default_ttl = stored_cfg.cfg.default_ttl;
}

bt_mesh_atomic_set_bit(bt_mesh.flags, BLE_MESH_VALID);
bt_mesh_net_start();
}
#endif /* CONFIG_BLE_MESH_NODE */
Expand Down

0 comments on commit 7fccbcf

Please sign in to comment.