nRF Connect SDK API 0.1.0
Loading...
Searching...
No Matches
dfu_multi_image.h File Reference
#include <stdbool.h>
#include <stddef.h>
#include <stdint.h>

Go to the source code of this file.

Data Structures

struct  dfu_image_writer
 User-provided functions for writing a single image from DFU Multi Image package. More...
 

Typedefs

typedef int(* dfu_image_open_t) (int image_id, size_t image_size)
 
typedef int(* dfu_image_write_t) (const uint8_t *chunk, size_t chunk_size)
 
typedef int(* dfu_image_close_t) (bool success)
 

Functions

int dfu_multi_image_init (uint8_t *buffer, size_t buffer_size)
 Initialize DFU Multi Image library context.
 
int dfu_multi_image_register_writer (const struct dfu_image_writer *writer)
 Register DFU image writer.
 
int dfu_multi_image_write (size_t offset, const uint8_t *chunk, size_t chunk_size)
 Write subsequent DFU Multi Image package chunk.
 
size_t dfu_multi_image_offset (void)
 Returns DFU Multi Image package write position.
 
int dfu_multi_image_done (bool success)
 Complete DFU Multi Image package write.