I have been testing the FreeRTOS cellular interface for the SARA-R4. I have a setup which allows me to simulate a loss of connection (by attenuating the antenna signal). I have implemented the
RegisterUrcNetworkRegistrationEventCallback in such a way that the callback prints out connection status changes.
When I simulate a brief connection loss of 10 seconds, the callback first triggers and reports that the cs and ps registration status are REGISTRATION_STATUS_NOT_REGISTERED_SEARCHING. When the connection comes back up again the callback reports REGISTRATION_STATUS_REGISTERED_HOME. This is expected behavior.
A problem occurs when I simulate a longer connection loss, of a minute or so, then again REGISTRATION_STATUS_NOT_REGISTERED_SEARCHING is first reported, but when the connection comes back up, there is no REGISTRATION_STATUS_REGISTERED_HOME callback. The modem remains disconnected.
What might be related is that I noticed that the networkRegistrationMode is always reported as REGISTRATION_MODE_UNKNOWN, should this not be REGISTRATION_MODE_AUTO in order for the modem to reconnect automatically? How can I configure this?