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

◆ lwm2m_carrier_identity_read()

int lwm2m_carrier_identity_read ( uint16_t  instance_id,
uint16_t  identity_type,
char *  buffer,
uint16_t *  buffer_len 
)

#include <lib/bin/lwm2m_carrier/include/lwm2m_carrier.h>

Read an identity in the OMA LwM2M Portfolio object Identity resource (/16/instance_id /0/identity_type ).

Note
If the provided buffer is NULL, the function will perform a dry run to determine the required buffer size (including the null terminator).
Parameters
[in]instance_idPortfolio object instance identifier.
[in]identity_typeType of Identity field to be read (lwm2m_carrier_portfolio_identity_values).
[in,out]bufferBuffer where the null-terminated response will be stored.
[in,out]buffer_lenLength of the provided buffer. Will return the number of bytes of the full response.
Return values
0If the operation was successful.
-ENOENTIf the instance does not exist.
-EINVALIf the provided buffer length reference is NULL or the identity type is invalid.
-ENOMEMIf the provided buffer is too small.