SG RFID nRF51822 fork

Fork of nRF51822 by Nordic Semiconductor

Embed: (wiki syntax)

« Back to documentation index

ble_dfu.h File Reference

ble_dfu.h File Reference

Go to the source code of this file.

Data Structures

struct  ble_dfu_pkt_write_t
 DFU Packet structure. More...
struct  ble_pkt_rcpt_notif_req_t
 Packet receipt notification request structure. More...
struct  ble_dfu_evt_t
 DFU Event structure. More...
struct  ble_dfu_s
 DFU service structure. More...
struct  ble_dfu_init_t
 DFU service initialization structure. More...

Typedefs

typedef struct ble_dfu_s ble_dfu_t
 DFU service structure.
typedef void(* ble_dfu_evt_handler_t )(ble_dfu_t *p_dfu, ble_dfu_evt_t *p_evt)
 DFU Service event handler type.

Enumerations

enum  ble_dfu_evt_type_t {
  BLE_DFU_START, BLE_DFU_RECEIVE_INIT_DATA, BLE_DFU_RECEIVE_APP_DATA, BLE_DFU_VALIDATE,
  BLE_DFU_ACTIVATE_N_RESET, BLE_DFU_SYS_RESET, BLE_DFU_PKT_RCPT_NOTIF_ENABLED, BLE_DFU_PKT_RCPT_NOTIF_DISABLED,
  BLE_DFU_PACKET_WRITE, BLE_DFU_BYTES_RECEIVED_SEND
}
 

DFU Event type.

More...
enum  ble_dfu_procedure_t {
  BLE_DFU_START_PROCEDURE = 1, BLE_DFU_INIT_PROCEDURE = 2, BLE_DFU_RECEIVE_APP_PROCEDURE = 3, BLE_DFU_VALIDATE_PROCEDURE = 4,
  BLE_DFU_PKT_RCPT_REQ_PROCEDURE = 8
}
 

DFU Procedure type.

More...
enum  ble_dfu_resp_val_t {
  BLE_DFU_RESP_VAL_SUCCESS = 1, BLE_DFU_RESP_VAL_INVALID_STATE, BLE_DFU_RESP_VAL_NOT_SUPPORTED, BLE_DFU_RESP_VAL_DATA_SIZE,
  BLE_DFU_RESP_VAL_CRC_ERROR, BLE_DFU_RESP_VAL_OPER_FAILED
}
 

DFU Response value type.

More...

Functions

void ble_dfu_on_ble_evt (ble_dfu_t *p_dfu, ble_evt_t *p_ble_evt)
 Function for handling a BLE event.
uint32_t ble_dfu_init (ble_dfu_t *p_dfu, ble_dfu_init_t *p_dfu_init)
 Function for initializing the DFU service.
uint32_t ble_dfu_response_send (ble_dfu_t *p_dfu, ble_dfu_procedure_t dfu_proc, ble_dfu_resp_val_t resp_val)
 Function for sending response to a control point command.
uint32_t ble_dfu_bytes_rcvd_report (ble_dfu_t *p_dfu, uint32_t num_of_firmware_bytes_rcvd)
 Function for notifying the peer about the number of bytes of firmware data received.
uint32_t ble_dfu_pkts_rcpt_notify (ble_dfu_t *p_dfu, uint32_t num_of_firmware_bytes_rcvd)
 Function for sending Packet Receipt Notification to the peer.

Detailed Description

Definition in file ble_dfu.h.