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

Sending message to all nodes over mesh & identify sender

I'm trying to use the information from this devpost: https://devzone.nordicsemi.com/f/nordic-q-a/39629/how-to-send-data-to-all-node-over-mesh

However, my remaining questions are: 

1) I just need to send a simple on/off, but I also want the nodes that receive the message to know which node sent the message. Is this already a feature in this code, or will this require using a more complex model (i.e. a generic level mode, to send a name/identifier for the node that sent the message)?

2) My understanding is that the client nodes send the message (to turn on the light), and the server just act on it (turn the light on/off). I want all my nodes to be able to send and receive messages, so they all sort of act like servers and clients. Can someone clue me in on how I can begin to implement this? 

3) Will relay functionality automatically be implemented? If Node 1 sends a message that Nodes 2 and 3 are supposed to receive, but 3 is out of range, will 2 automatically route it to 3 if they're in range of one another?

Parents
  • Hi. 

    I apologize for the delay here. 

    1) This is possible and already available in the Mesh SDK. You can use reliable messages to ensure that the node receives the message. When using the reliable publish you will get a response acknowledging that the message is received.

    2) If you want to send data from the server node to the client node, you can implement a client on the server node and a server on the client node as well. That way you will be able to send data both ways. 

    3) The relay functionality is optional, so you can enable it or disable it as you please. Note that if you want a more reliable network, it is recommended to multiple relay nodes. Having multiple relay nodes can ensure that the message can take different routes if one relay node is unavailable. However, how many relay nodes you want is all up to you. In most of the examples in the Mesh SDK, the relay functionality is enabled by default. 

    Best regards, 
    Joakim 

Reply
  • Hi. 

    I apologize for the delay here. 

    1) This is possible and already available in the Mesh SDK. You can use reliable messages to ensure that the node receives the message. When using the reliable publish you will get a response acknowledging that the message is received.

    2) If you want to send data from the server node to the client node, you can implement a client on the server node and a server on the client node as well. That way you will be able to send data both ways. 

    3) The relay functionality is optional, so you can enable it or disable it as you please. Note that if you want a more reliable network, it is recommended to multiple relay nodes. Having multiple relay nodes can ensure that the message can take different routes if one relay node is unavailable. However, how many relay nodes you want is all up to you. In most of the examples in the Mesh SDK, the relay functionality is enabled by default. 

    Best regards, 
    Joakim 

Children
No Data
Related