nRF Connect SDK API 2.8.99
Loading...
Searching...
No Matches

◆ nrf_cloud_uninit()

int nrf_cloud_uninit ( void )

#include <include/net/nrf_cloud.h>

Uninitialize nRF Cloud; disconnects cloud connection and cleans up allocated memory.

Note
If nRF Cloud FOTA is enabled and a FOTA job is active uninit will not be performed.
This function is solely intended to allow this library to be deactivated when no longer needed. You can recover from any error state you may encounter without calling this function. See nrf_cloud_disconnect for a way to reset the nRF Cloud connection state without uninitializing the whole library.
Return values
0If successful.
-EBUSYIf a FOTA job is in progress.
-EISCONNIf the expected disconnect event did not occur.
-ETIMEIf
CONFIG_NRF_CLOUD_CONNECTION_POLL_THREAD 
is enabled and the connection poll thread did not become inactive.
Returns
A negative value indicates an error.