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

can't relay message through multiple servers in mesh network.

Hi All,


we are going to develop the lighting application based on nRF52832 with the use of BLE mesh SDK V3.0.0 and nRF SDK V15.2.0.
I am new to BLE and also BLE mesh. So I am learning the server and client app.
I have setup 7 boards out of which 1 is client. The client is nRF-DK. I provisioned them through nRF Mesh android application.

I have subscribed all servers to group with 0xc001 address and also I have make client to publish the Set/Reset status of the switch 2/3 on nRF52-DK(Client). By receiving the group message published by the client, the server turns on/off the respective LED.

Now when I put all boards near to each other, and press the Set/Reset button then the LEDs of all servers reacts to that message. But when I place them all in series like the last few server boards are not capable to direct communicate with client. And the boards in between them should be relay the messages from client to them. So then some board responds to that messages and turn on/off the LEDs but last few boards cannot listen to that messages and thus not turning LED's on/off.

So my questions are:-

1> I heard that "by default the server is also capable to relay the messages" but why some boards which are out of range cannot responds to the messages even they can be in the range of relay nodes? Is there any settings from code side I have to do? or I have to change the parameter/configuration of mesh. 

2> Is the communication distance between client-to-server is same as server-to-server when the sensitivity matters?

Please guide me through this.

Thanks to all in advanced.

Parents
  • Hi, 

    Relay role is enabled by default. Please check in you code if MESH_FEATURE_RELAY_ENABLED = 1 in nrf_mesh_config_code.h

    What you described is pretty strange. How do you send the message from client to server ? What was the delay between 2 commands you send from the client ? 

    Could you try to test again using only 3 devices. One client and 2 servers. What you can do is to start first with one client and one server, and you move the server until it's out side the range of the client. Then you put the 3rd device in between and turn it on. If the mesh network works as it should the first server should be able to receive the command after you turn on the 3rd device to work as a relay. 

    You can reduce the output power of the chip to make it easier to reproduce (so you don't have to go too far to get out of range) Please change the radio_config.tx_power in set_default_broadcast_configuration() to RADIO_POWER_NRF_NEG8DBM for example. 

  • Dear Hung Bui,

    By message, I mean to say is i want to publish a command to a group address.

    Could you try to test again using only 3 devices.

    I have already done that and it is running fine.. And I know that the Relay functionality is enabled in server.

    But I have 8 server boards which are in series. So that last few boards are not accessible by client. In this configuration, last boards are not responding to the client. Or else, I can say that after 2 or 3 board, other boards could not get the commands from client.

    I hope you understand my concern. 

    Is there anything related to TTL value?

    I have set the TTL to 25. But not any success.

    My question is something similar to the post below.

    https://devzone.nordicsemi.com/f/nordic-q-a/40702/light-switch-demo-relaying-messages-relayed-messages-ttl-limited-to-4

    But I can't get the reply from that.

  • Hi Jaydeepsinh

    Ok, so the relay feature actually works ? 

    The problem you are having now is that you can't relay after 2-3 boards. 

    It could be related to the TTL value. 

    TTL is the time to live value that included in each mesh message. After each hop that value will be reduced by 1 until it reaches 01, no more relaying.

    How did you set your TTL to 25 ? By default the TTL will have the value of ACCESS_DEFAULT_TTL = 4.

  • Hello Hung Bui,

    Yes you got me right.

    the relay functionality is working upto few boards (upto 3-4 boards).

    And I can't relay message after 3-4 boards. That's the real problem.

    Now As I said, I have set the TTL value of 25 which is more than enough I think. And I have set the TTL value by using the nRF-Mesh Android Application by which I have provisioned all boards.

    I have also tested the TTL value which is decrement up-to 21 in last server board which I have debugged.

  • OK, we need to check how you tested. Do you see the issue all the time, for any message you send, or just on some messages that they couldn't reach the servers located further away ? 

    Have you tried to test with the light switch example ? I would suggest to disable proxy after your provisioned the device. Or change the advertising interval to long interval, just to make sure it's not because of the BLE activity that cause the BLE mesh performance to be reduced.

    I don't see any reason why the server wouldn't relay the message after it get to 21. The difference between a message being relayed and a message sent from the originator is the TTL inside the packet. 

Reply
  • OK, we need to check how you tested. Do you see the issue all the time, for any message you send, or just on some messages that they couldn't reach the servers located further away ? 

    Have you tried to test with the light switch example ? I would suggest to disable proxy after your provisioned the device. Or change the advertising interval to long interval, just to make sure it's not because of the BLE activity that cause the BLE mesh performance to be reduced.

    I don't see any reason why the server wouldn't relay the message after it get to 21. The difference between a message being relayed and a message sent from the originator is the TTL inside the packet. 

Children
No Data
Related