nRF Connect SDK API 0.1.0
|
int lwm2m_carrier_error_code_add | ( | int32_t | error | ) |
#include <lib/bin/lwm2m_carrier/include/lwm2m_carrier.h>
Set an error code in the OMA LwM2M Device
object Error Code
resource (/3/0/11).
At startup the error code is specified as 0, indicating no error. The error code is to be updated whenever a new error occurs. Or after an LWM2M_CARRIER_EVENT_ERROR_CODE_RESET event if the error code is still valid. Multiple error codes can be set, if the reported error is already present, the error code will remain unchanged.
[in] | error | Individual error to be added (lwm2m_carrier_error_code_values) LWM2M_CARRIER_ERROR_CODE_NO_ERROR will reset all error codes. |
0 | If the error code has been added successfully. |
-EINVAL | If the error code is not supported. |
-ENOENT | If LwM2M object is not initialized yet. |