Patched version of nrf51822 FOTA compatible driver, with GPTIO disabled, as it clashed with the mbed definitions...

Fork of nRF51822 by Nordic Semiconductor

Embed: (wiki syntax)

« Back to documentation index

Device Firmware Update internal header for bank handling in DFU.

Device Firmware Update internal header for bank handling in DFU.

Device Firmware Update Bank handling module interface. More...

Data Structures

struct  dfu_bank_func_t
 Structure for holding of function pointers for needed prepare and activate procedure for the requested update procedure. More...

Typedefs

typedef void(* dfu_bank_prepare_t )(uint32_t image_size)
 Type definition of function used for preparing of the bank before receiving of a software image.
typedef void(* dfu_bank_cleared_t )(void)
 Type definition of function used for handling clear complete of the bank before receiving of a software image.
typedef uint32_t(* dfu_bank_activate_t )(void)
 Type definition of function used for activating of the software image received.

Enumerations

enum  dfu_state_t {
  DFU_STATE_INIT_ERROR, DFU_STATE_IDLE, DFU_STATE_PREPARING, DFU_STATE_RDY,
  DFU_STATE_RX_INIT_PKT, DFU_STATE_RX_DATA_PKT, DFU_STATE_VALIDATE, DFU_STATE_WAIT_4_ACTIVATE
}
 

States of the DFU state machine.

More...

Variables

static uint32_t m_data_received
 Amount of received data.

Detailed Description

Device Firmware Update Bank handling module interface.

This header is intended for shared definition and functions between single and dual bank implementations used for DFU support. It is not supposed to be used for external access to the DFU module.


Typedef Documentation

typedef uint32_t(* dfu_bank_activate_t)(void)

Type definition of function used for activating of the software image received.

Returns:
NRF_SUCCESS If the image has been successfully activated any other NRF_ERROR code in case of a failure.

Definition at line 71 of file dfu_bank_internal.h.

typedef void(* dfu_bank_cleared_t)(void)

Type definition of function used for handling clear complete of the bank before receiving of a software image.

Definition at line 64 of file dfu_bank_internal.h.

typedef void(* dfu_bank_prepare_t)(uint32_t image_size)

Type definition of function used for preparing of the bank before receiving of a software image.

Parameters:
[in]image_sizeSize of software image being received.

Definition at line 59 of file dfu_bank_internal.h.


Enumeration Type Documentation

States of the DFU state machine.

Enumerator:
DFU_STATE_INIT_ERROR 

State for: dfu_init(...) error.

DFU_STATE_IDLE 

State for: idle.

DFU_STATE_PREPARING 

State for: preparing, indicates that the flash is being erased and no data packets can be processed.

DFU_STATE_RDY 

State for: ready.

DFU_STATE_RX_INIT_PKT 

State for: receiving initialization packet.

DFU_STATE_RX_DATA_PKT 

State for: receiving data packet.

DFU_STATE_VALIDATE 

State for: validate.

DFU_STATE_WAIT_4_ACTIVATE 

State for: waiting for dfu_image_activate().

Definition at line 31 of file dfu_bank_internal.h.


Variable Documentation

uint32_t m_data_received [static]

Amount of received data.

Definition at line 52 of file dfu_bank_internal.h.