This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Number of hops BT Mesh

Hello,

To determine the current network topology I hoped I could use the heartbeats to determine the RSSI and the number of hops. The RSSI of the last node is in the example (health client), but I can't find the number of hops. Is that accessible?

Even better would be, that I could see which modules were used as a relay to het the heartbeat to the health client.

Is there any way to do this?

Thanks,

Milo

Heartbeats - Heartbeat messages are transmitted by nodes periodically. A heartbeat message indicates to other nodes in the network that the node sending the heartbeat is still active. In addition, heartbeat messages contain data which allows receiving nodes to determine how far away the sender is, in terms of the number of hops required to reach it. This knowledge can be exploited with the TTL field.

Parents
  • Hi,

    Number of hops is available in the NRF_MESH_EVT_HB_MESSAGE_RECEIVED event, in the field evt.params.hb_message.hops. See the nrf_mesh_evt_hb_message_t Struct Reference for descriptions of all fields.

    There is no method provided through the Bluetooth mesh specification for finding the full path of the packet, so in that case you will have to build something for that yourself. You would need to in every node to figure out what nodes they receive messages from, and communicate that information out from the nodes. Please note however that this quickly becomes very statistical/probabilistic, as not every packet will make the same "path" through the network. (Bluetooth mesh is a flooding network, and so every packet will "spread" or "flood" out from the point of origin through the network. It is not a point-to-point routed network.)

    I also found a DevZone thread named Mesh Monitor with Heartbeat Messages which may be of some interest to you.

    Regards,
    Terje

Reply
  • Hi,

    Number of hops is available in the NRF_MESH_EVT_HB_MESSAGE_RECEIVED event, in the field evt.params.hb_message.hops. See the nrf_mesh_evt_hb_message_t Struct Reference for descriptions of all fields.

    There is no method provided through the Bluetooth mesh specification for finding the full path of the packet, so in that case you will have to build something for that yourself. You would need to in every node to figure out what nodes they receive messages from, and communicate that information out from the nodes. Please note however that this quickly becomes very statistical/probabilistic, as not every packet will make the same "path" through the network. (Bluetooth mesh is a flooding network, and so every packet will "spread" or "flood" out from the point of origin through the network. It is not a point-to-point routed network.)

    I also found a DevZone thread named Mesh Monitor with Heartbeat Messages which may be of some interest to you.

    Regards,
    Terje

Children
Related