Doc for reliable connection missing

Hi,

while browsing through the Q&A I came across this thread:

 How to recover a nRF9160 from sporadic ENETDOWN 

Conclusion is: if a (UDP socket) sendto returns en errno of ENETDOWN the modem has disconnected and I am supposed to close and reoopen
the socket. Fine.

But honestly, without randomly browsing through Q&A how should I have known this? Is there any documentation on how to
"just keep the network up and be able to send data?". Without finding this I would have guessed that, ok, network is down, it
will reconnect and my socket will work again.

Are there other cases of errors that do not recover by themselfes and action by the application is required?
I am aware that the action is application depended (how log to wait until trying reconnect to not drain batteries or stuff like this).
And yes I am supposed to do testing. But handing rare cases is hard to test and trying to find out the "black box" behavior by testing
is also hard.

A writeup of what can happen on how the application should react would be really nice. Or is there allready an overview?

Spending hours in the Q&A browsing through topics to find out if there is an other case I need to act on is not really
a solution.

Regards,

Clemens

Parents Reply Children
  • In my long term experience (now more than 12 months), the modem seems to detect not all "network" issues proper and report that as error (e.g. via a socket error).

    In some rare case of an partial provider outage, my device was still sending UDP messages without getting any error reported. The messages didn't reach the servers, while other messages did. Restarting some of this devices during that outage resulted in PDN error: 30, Request rejected by Serving GW or PDN GW. After the outage and restarting the modems all seems well again.

    For my devices I decided to use also a timeout for server responses to check the modem's health. I'm not sure, if the modem ignores some PDN errors or if the modem doesn't receive them.

Related