Support of TCP keepalive

I am using the nRF9160 with the SLM application.

The device will open a TCP connection to the server; the server will always initiate commands and the device reply. So the connection needs to be always kept alive.

Are there plans to introduce the TCP keepalive socket option to the base software?
I am aware this question is open for some years already unanswered, but instead of replying in this old threat I'd like to re-raise the question with a bit more elaboration on it.

Usually, TCP is offloaded to the modem library, so the question would be addressed to the library.

But there would also be the option to enable the IP stack of Zephyr and handle TCP there.
However, there the feature is also not present in the SDK version of Zephyr; however in the base Zephyr project it was added last december.

So, what is the usual timeline for taking over features from the main project, or are there plans to make this feature available in the modem library?

  • OK, seems like reality has overtaken while I was speaking, and in nrf v2.7.0 branch, respective Zephyr v3.6.99, the feature is going to be there.
    Then let me rephrase the request: Is it also going to be natively in the modem library?

  • Hello. 

    thanks for the good question. 

    Holger Lamm said:
    and in nrf v2.7.0 branch, respective Zephyr v3.6.99, the feature is going to be there.

    Yes, it does seem that it will be supported in Zephyr 3.6.99. Regarding the modem library I need to ask internally. And will get back to you within the day. 

    Kind regards,
    Øyvind

  • Hello Øyvind,

    any update regarding support in the modem library?

  • Hi,

     

    My apologies for the late response. Øyvind is currently out of office.

    nrf_modem / libmodem unfortunately does not have support for setsockopt with keep-alive for stream sockets.

     

    Kind regards,

    Håkon

  • Is there any update on current or planned inclusion of this support?

1 2