Function anj_ntp_obj_restore

Function Documentation

int anj_ntp_obj_restore(anj_ntp_t *ntp, const anj_persistence_context_t *ctx)

Deserializes the LwM2M NTP Object from the persistence stream. Should be called after successful initialization of NTP module.

Reads NTP Object instance and its resources from the underlying medium via ctx->read.

Parameters:
  • ntp – NTP Object context to fill.

  • ctx – Persistence context; must have direction set to ANJ_PERSISTENCE_RESTORE.

Returns:

0 on success, negative value on error.