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

How to relay message from one node to other in mesh network

Hi,

I have 3 of nRF52840 boards, SDK V2.2.0 and nRF SDK V15.0.0.

I already tested the light switch control example, and saw it working with one client and 2 servers and all the 2 servers within the client's range.

Now my question is,

1) How can i relay the message to node not in range?

2) For relay what changes are needed in code?

3) Can i use nRF mesh app to control set/reset?

Parents
  • 1) This should be done automatically if relaying is enabled on the node you want to relay from.

    2) Take a look at this code here, which shows the different code for setting the relay state:

    /** Values for the relay state. */
    typedef enum
    {
        CONFIG_RELAY_STATE_SUPPORTED_DISABLED = 0x00, /**< Relaying is supported, but disabled. */
        CONFIG_RELAY_STATE_SUPPORTED_ENABLED  = 0x01, /**< Relaying is supported and enabled. */
        CONFIG_RELAY_STATE_UNSUPPORTED        = 0x02  /**< Relaying is not supported. */
    } config_relay_state_t;

    Also take a look at send_relay_status() & handle_config_relay_set(). I believe the FW automatically sets the relay status to enabled.

    3) No, you cannot set/reset the relay status via the nRF Mesh app at the moment.

  • hi bjorn kvaale 

    i want to send the message from client to relay node and relay node has to forward the message to server , which my server is far away from the client .  Relay feature is enabled by default , then what are all changes i want to do ? and then how to do this by using mesh app

    i hope you , you can help me

    thanks in advance

  • The relaying needs to be set in the FW itself. As of now, the mesh app cannot turn on or off relaying of specific nodes. I am not sure whether this will be supported in future releases, but I doubt it. You can either send a unicast message from the client to the server that is farthest away & have the relay node in between the client & the server or you can change the tx power of the client to limit the range of the client. This may be useful if you do not have a big space to test in. You want to make sure that the client is not in RF range of the furthest server, as then you cannot test to make sure the relaying works.

Reply
  • The relaying needs to be set in the FW itself. As of now, the mesh app cannot turn on or off relaying of specific nodes. I am not sure whether this will be supported in future releases, but I doubt it. You can either send a unicast message from the client to the server that is farthest away & have the relay node in between the client & the server or you can change the tx power of the client to limit the range of the client. This may be useful if you do not have a big space to test in. You want to make sure that the client is not in RF range of the furthest server, as then you cannot test to make sure the relaying works.

Children
Related