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

◆ lwm2m_os_dfu_fragment()

int lwm2m_os_dfu_fragment ( const char *  buf,
size_t  len,
uint32_t  crc32 
)

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

Receive a firmware image fragment and validate its CRC if required.

Parameters
[in]bufBuffer containing the fragment.
[in]lenLength of the fragment in bytes.
[in]crc32Expected IEEE CRC32 value to be checked for the whole fragment. Can be any value if no validation expected.
Return values
0Success.
-EACCESlwm2m_os_dfu_start() was not called beforehand.
-ENOMEMNot enough memory to process the fragment.
-EINVALCRC error.
-EIOInternal error.