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

BLE MESH Stack(2.0.1)Light Switch Demo Roundtrip Delay getting higher between client and server

Hii,

I am currently using two nRF52832 SDK boards to implement text message exchange with another nRF52832 SDK board via BLE Mesh SDK 2.0.1.

However, when I try to increase the frequency of sending the command the communication seem to choke. and i'm getting Roundtrip Delay higher between client and server.

Roundtrip calcualtion of 5byte send and receive  sheet is below

  

Round trip calcualtion of 11byte send and receive  sheet is below

How to reduce round trip delay time please suggest me ASAP.

Thanks,

Nikunj Patidar

 

Parents
  • Hello Nikunj,

    Mesh is built on BLE advertisement packets. An advertising packet is 31 bytes long. In Mesh, if you exclude the headers, you are left with 11 bytes. In addition, since you are using the nordic access API, company-ID and opcode, you are left with 8 bytes.

    This means that when you send a message with 50 bytes, it is split into 7 packets. six with 8 bytes, and one with 2 bytes.

    Your devices will only send a packet every 20ms. I am not sure exactly how that example works, but if you loose a packet, it might have to send the entire message again. Since you only have 2 nodes in the network, you don't have any nodes to retransmit the packets either, so if the client doesn't receive the packet initially, the message will be lost.

     

    Can you please try to split the packet into 8 bytes sized packets? You can use the NRF_MESH_EVT_TX_COMPLETE event to know when a packet is sent, to trigger the next one, like explained earlier.

     

    Best regards,

    Edvin

  • Hello Edvin,

    I have try to send only 8 byte Echo back message.

    Echo Back Calculation Time = (Stop Count - Start Count )/32768  in Second

    Loge Snap Shot is Below

    1st time Send 8 byte Echo back time =(176891 -71253)/32768= 3.22 Second
    2nd time Send 8 byte Echo back time =(16612647  -16585267 )/32768= 0.83 Second
    3rd time Send 8 byte Echo back time =(48805  -21421 )/32768= 0.83 Second

    See in Log 1st time Client send only 8byt to server ,Client Retries 3 time after receive Ack but server receive message 2 times.

    i think client wait for Ack if not receive then retries multiple time . in my case server receive messege 2 time but not send ack to client.

    Thank's

    Nikunj 

  • Hello,

    Ok. It seems that you are missing some packets (then the other device will try to resend them). 

    Since you are using the proxy example, what conn_interval and advertising_interval do you use? Can you try with the non-proxy example to see if that helps?

    The reason might be that since you are using the proxy example, the device will not have control of the radio all the time. Not when the softdevice is using it. If it works better with the non-proxy example, you can try to increase the BLE interval (advertising/scanning interval and connection interval) to see if that helps.

     

    Best regards,

    Edvin

  • Hello Edvin,

    Now i'm using non proxy example,The results is better then previous one.

     

    Connection Interval

    #define MIN_CONN_INTERVAL MSEC_TO_UNITS(250, UNIT_1_25_MS)
    #define MAX_CONN_INTERVAL MSEC_TO_UNITS(1000, UNIT_1_25_MS)

    Advertisement interval
    #define BEARER_ADV_INT_DEFAULT_MS 20

    Scan interval
    #define BEARER_SCAN_INT_DEFAULT_MS 2000

    Scan window
    #define BEARER_SCAN_WINDOW_DEFAULT_MS 2000

    i want to send 250 byte Payload using light switch ble mesh example code.i have implemented echo back mechanism.

    i have attached sheet of readings taken with 10,50,250 byte.

    Roundtrip_Calculation_NonProxyClient.xls

    please check it and tell me that roundtrip delay is getting some time higher.  

    Thank's

    Nikunj

Reply Children
No Data
Related