Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs

ESB RX_ACK different from NRF5 SDK to NRF connect SD

Hi

Im converting from NRF5 SDK to NRF connect SDK, and im using ESB but noticed that there is a different in RX ack timeout on the NRF5 SDK vs the NRF connect SDK. 

The NRF5 SDK Rx Ack timeout is: 
#define RX_WAIT_FOR_ACK_TIMEOUT_US_2MBPS        (48)        /**< 2 Mb RX wait for acknowledgment time-out value. Smallest reliable value - 43. */

Where the NRF connect SDK Rx Ack timeout is: 
#define RX_ACK_TIMEOUT_US_2MBPS                             160        /* 2 Mb RX wait for acknowledgment time-out value. Smallest reliable value: 160. */

Is there a reason behind this, and is there a way to get the NRF connect SDK to be lowered, as it does seems to not be reliable at a lower rate?

Best regards 
Kenn

Parents
  • Hi,

    While it's pretty clear from the comments that the value should not get below 160 ms, I have not found the underlying reason. Most likely the number stems from testing during the porting of the library from nRF5 SDK to nRF Connect SDK. It's hard to tell whether the value can be lowered, and if so by how much, but I will dig some more internally to figure out more about the issue. What impact does the increased timeout have for your project, is the issue latency, throughput, power consumption, other, or a combination?

    Regards,
    Terje

Reply
  • Hi,

    While it's pretty clear from the comments that the value should not get below 160 ms, I have not found the underlying reason. Most likely the number stems from testing during the porting of the library from nRF5 SDK to nRF Connect SDK. It's hard to tell whether the value can be lowered, and if so by how much, but I will dig some more internally to figure out more about the issue. What impact does the increased timeout have for your project, is the issue latency, throughput, power consumption, other, or a combination?

    Regards,
    Terje

Children
  • Hi Terje

    Thanks for the answer.

    The change does have big impact on my project, as latency on the radio has to be as low as possible. And at the moment I'm not sure I can get the throughput fast enough as I could with the Nrf5 SDK. 

    Hope you found out some interesting internally that could help this problem. 

    Best regards

    Kenn

  • Hi,

    I am afraid I don't have any definite answer to why this setting is changed, nor why it is at exactly 160. There is however one possible explanation, which I have not gotten any confirmation for yet:

    It may have to do with giving enough time for receiving a full ACK with payload. ACK with payload was an optional feature in nRF5, but I do not find a setting for it in NCS so it might be always present. That might explain the need for additional time for the ACK timeout. In that case, a lower value might be possible if the ACKs don't contain payload.

    If it's up to the ESB library to decide whether to include payload in the ACK, then you cannot be sure, in cases where the peer device is also based off of nRF Connect SDK. If on the other hand you know that the peer device will not send payloads in the ACK, then it might be safe to reduce the timeout.

    Have you tried to reduce the value, and seen any issues as a result?

    Regards,
    Terje

  • Hi

    I have tried to change the timeout to the same value as the old SDK, however I can not get a stable connection between my PTX and PRX. 
    I'm still testing if the speed is good enough, and found out that this value in ESB.c file aswell is alot higher than previous SDK. "RETRANSMIT_DELAY_MIN" However it does seem to be able to change it from 435 to 135, without any issues. 

    Best regards 
    Kenn

  • Hi,

    We have traced the values back to worst case scenarios from full capacity testing of the ESB implementation. In other words, the values are, as we see it, indeed the minimal values for ESB in the current nRF Connect SDK.

    You may get away with some lower values if not running at full throughput, or if you accept degraded performance in other areas, but I am afraid that would be something you must experiment with yourself and there are no guarantees such values exist.

    For information on what to expect in the future, please contact our Regional Sales Director (previously Regional Sales Manager) for your area. If you don't know who that is, please ask in a private ticket or private message, and we will let you know.

    Regards,
    Terje

  • Hi 

    What about if I want to change a define value in the ESB.c file in the SDK, how do I make it available, when I clone the SDK to a new PC, without having to manually change it? 

    The value I want to change is a define in the ESB.c file: 

    /* Minimum retransmit time */
    #define RETRANSMIT_DELAY_MIN 435

    My project works with this changed to 135, but as its in the SDK, I have to do it manually. 

Related