Functions | |
sdk_err_t | dfu_init (dfu_func_t *p_app_func, dfu_buf_table_t *p_buffer, dfu_pro_callback_t *p_callback) |
Function for initializing the DFU Used and Program State Callback. More... | |
void | dfu_cmd_parse_reset (void) |
Function for reset the DFU cmd parse state. More... | |
void | dfu_receive_data_process (uint8_t *p_data, uint16_t length) |
This function should be called when dfu receives data. More... | |
void | dfu_schedule (void) |
Function for checking DFU cmd. More... | |
void | dfu_ble_set_mtu_size (uint16_t mtu_size) |
Function for setting the BLE MTU size. More... | |
void | dfu_ble_send_data_cmpl_process (void) |
This function should be called when BLE stack sends data completely. More... | |
void | dfu_ble_receive_data_process (uint8_t *p_data, uint16_t length) |
This function should be called when BLE receives data. More... | |
void | dfu_uart_receive_data_process (uint8_t *p_data, uint16_t length) |
This function should be called when UART receives data. More... | |
void | dfu_disable_cmd_set (uint16_t cmd_bit_map) |
Function for set DFU disable cmd. More... | |
bool | dfu_cmd_handler_set (uint8_t index, uint16_t cmd, dfu_receive_cmd_handler_t cmd_handler) |
Function for set DFU cmd handler. More... | |
void | dfu_spi_flash_func_config (dfu_spi_flash_func_t *spi_flash_func) |
Function for initializing the DFU SPI Flash Callback. More... | |
void dfu_ble_receive_data_process | ( | uint8_t * | p_data, |
uint16_t | length | ||
) |
This function should be called when BLE receives data.
[in] | p_data | The received data from BLE. |
[in] | length | The length of data. |
void dfu_ble_send_data_cmpl_process | ( | void | ) |
This function should be called when BLE stack sends data completely.
void |
void dfu_ble_set_mtu_size | ( | uint16_t | mtu_size | ) |
Function for setting the BLE MTU size.
[in] | mtu_size | The BLE MTU size. |
bool dfu_cmd_handler_set | ( | uint8_t | index, |
uint16_t | cmd, | ||
dfu_receive_cmd_handler_t | cmd_handler | ||
) |
Function for set DFU cmd handler.
[in] | index | Index of DFU cmd. |
[in] | cmd | DFU cmd. |
[in] | cmd_handler | DFU cmd handler. |
void dfu_cmd_parse_reset | ( | void | ) |
Function for reset the DFU cmd parse state.
void dfu_disable_cmd_set | ( | uint16_t | cmd_bit_map | ) |
Function for set DFU disable cmd.
[in] | cmd_bit_map | The bitmask of DFU disable cmd. |
sdk_err_t dfu_init | ( | dfu_func_t * | p_app_func, |
dfu_buf_table_t * | p_buffer, | ||
dfu_pro_callback_t * | p_callback | ||
) |
Function for initializing the DFU Used and Program State Callback.
[in] | p_app_func | DFU used functions. |
[in] | p_buffer | DFU data receiving buffer. |
[in] | p_callback | DFU program state callback functions. |
void dfu_receive_data_process | ( | uint8_t * | p_data, |
uint16_t | length | ||
) |
This function should be called when dfu receives data.
[in] | p_data | The received data |
[in] | length | The length of data |
void dfu_schedule | ( | void | ) |
Function for checking DFU cmd.
void dfu_spi_flash_func_config | ( | dfu_spi_flash_func_t * | spi_flash_func | ) |
Function for initializing the DFU SPI Flash Callback.
[in] | spi_flash_func | DFU operationally external flash used functions. |
void dfu_uart_receive_data_process | ( | uint8_t * | p_data, |
uint16_t | length | ||
) |
This function should be called when UART receives data.
[in] | p_data | The received data from UART |
[in] | length | The length of data |