Functions | |
void | ble_stack_init (ble_evt_handler_t evt_handler, stack_heaps_table_t *p_heaps_table) |
Initialize BLE Stack. More... | |
void | ble_stack_controller_init (stack_heaps_table_t *p_heaps_table) |
Initialize BLE Stack controller. More... | |
sdk_err_t | ble_hci_init (ble_hci_rx_channel_t *p_rx_channel, ble_hci_host_recv_cb_t host_recv_cb) |
Initialize ble hci adapter module. More... | |
sdk_err_t | ble_hci_host_packet_send (uint8_t *p_data, uint16_t length) |
BLE HCI adapter host send packet. More... | |
uint16_t | ble_hci_rx_channel_surplus_space_get (void) |
Get surplus space of controller receive channel. More... | |
void | ble_idle_time_notify_cb_register (void(*callback)(uint32_t hs)) |
Register BLE idle time notification callback function. More... | |
void | ble_activity_start_notify_cb_register (void(*callback)(ble_gap_actv_role_t e_role, uint8_t index)) |
Register BLE activity start notification callback function. More... | |
void | ble_activity_end_notify_cb_register (void(*callback)(ble_gap_actv_role_t e_role, uint8_t index)) |
Register BLE activity end notification callback function. More... | |
uint8_t | ble_rf_tx_mode_set (ble_rf_tx_mode_t e_rf_tx_mode) |
Change the RF TX mode of LP or ULP. More... | |
ble_rf_tx_mode_t | ble_rf_tx_mode_get (void) |
Get the RF TX mode of LP or ULP. More... | |
void | ble_rf_match_circuit_set (ble_rf_match_circuit_t e_ohm) |
Set the resistance value of the RF match circuit (unit: ohm). More... | |
ble_rf_match_circuit_t | ble_rf_match_circuit_get (void) |
Get the resistance value of the RF match circuit (unit: ohm). More... | |
uint8_t | ble_ext_llcp_send (uint16_t conn_idx, uint8_t *param, uint8_t ext_opcode) |
Start a extended llcp procedure. More... | |
uint8_t | ble_ext_llcp_cb_reg (struct ble_ext_llcp_cb_func_t *func) |
Registered the extended llcp procedure callback. More... | |
void | ble_aes_encrypt (const uint8_t *key, const uint8_t *val, aes_result_cb res_cb, uint32_t src_info) |
Perform an AES encryption - result within callback. More... | |
void | ble_aes_decrypt (const uint8_t *key, const uint8_t *val, aes_result_cb res_cb, uint32_t src_info) |
Perform an AES dencryption - result within callback. More... | |
void | ble_aes_ecb_encrypt (const uint8_t *key, const uint8_t *val, aes_result_cb res_cb, uint32_t src_info) |
Perform an AES ecb encryption - result within callback. More... | |
void | ble_aes_ecb_decrypt (const uint8_t *key, const uint8_t *val, aes_result_cb res_cb, uint32_t src_info) |
Perform an AES ecb dencryption - result within callback. More... | |
void | ble_aes_cbc_encrypt (const uint8_t *key, const uint8_t *iv, const uint8_t *val, aes_result_cb res_cb, uint32_t src_info) |
Perform an AES cbc encryption - result within callback. More... | |
void | ble_aes_cbc_decrypt (const uint8_t *key, const uint8_t *iv, const uint8_t *val, aes_result_cb res_cb, uint32_t src_info) |
Perform an AES cbc dencryption - result within callback. More... | |
void ble_activity_end_notify_cb_register | ( | void(*)(ble_gap_actv_role_t e_role, uint8_t index) | callback | ) |
Register BLE activity end notification callback function.
[in] | callback | function pointer of BLE activity end notification function. |
void ble_activity_start_notify_cb_register | ( | void(*)(ble_gap_actv_role_t e_role, uint8_t index) | callback | ) |
Register BLE activity start notification callback function.
[in] | callback | function pointer of BLE activity start notification function. |
void ble_aes_cbc_decrypt | ( | const uint8_t * | key, |
const uint8_t * | iv, | ||
const uint8_t * | val, | ||
aes_result_cb | res_cb, | ||
uint32_t | src_info | ||
) |
Perform an AES cbc dencryption - result within callback.
[in] | key | Key used for the decryption |
[in] | iv | IV used for the cbc decryption.only first block need to be present, continue block shall be null. |
[in] | val | Value to decrypt using AES |
[in] | res_cb | Function that will handle the AES based result (16 bytes) |
[in] | src_info | Information used retrieve requester |
void ble_aes_cbc_encrypt | ( | const uint8_t * | key, |
const uint8_t * | iv, | ||
const uint8_t * | val, | ||
aes_result_cb | res_cb, | ||
uint32_t | src_info | ||
) |
Perform an AES cbc encryption - result within callback.
[in] | key | Key used for the encryption |
[in] | iv | IV used for the cbc encryption.only first block need to be present, continue block shall be null. |
[in] | val | Value to encrypt using AES |
[in] | res_cb | Function that will handle the AES based result (16 bytes) |
[in] | src_info | Information used retrieve requester |
void ble_aes_decrypt | ( | const uint8_t * | key, |
const uint8_t * | val, | ||
aes_result_cb | res_cb, | ||
uint32_t | src_info | ||
) |
Perform an AES dencryption - result within callback.
[in] | key | Key used for the dencryption |
[in] | val | Value to decrypt using AES |
[in] | res_cb | Function that will handle the AES based result (16 bytes) |
[in] | src_info | Information used retrieve requester |
void ble_aes_ecb_decrypt | ( | const uint8_t * | key, |
const uint8_t * | val, | ||
aes_result_cb | res_cb, | ||
uint32_t | src_info | ||
) |
Perform an AES ecb dencryption - result within callback.
[in] | key | Key used for the dencryption |
[in] | val | Value to decrypt using AES |
[in] | res_cb | Function that will handle the AES based result (16 bytes) |
[in] | src_info | Information used retrieve requester |
void ble_aes_ecb_encrypt | ( | const uint8_t * | key, |
const uint8_t * | val, | ||
aes_result_cb | res_cb, | ||
uint32_t | src_info | ||
) |
Perform an AES ecb encryption - result within callback.
[in] | key | Key used for the encryption |
[in] | val | Value to encrypt using AES |
[in] | res_cb | Function that will handle the AES based result (16 bytes) |
[in] | src_info | Information used retrieve requester |
void ble_aes_encrypt | ( | const uint8_t * | key, |
const uint8_t * | val, | ||
aes_result_cb | res_cb, | ||
uint32_t | src_info | ||
) |
Perform an AES encryption - result within callback.
[in] | key | Key used for the encryption |
[in] | val | Value to encrypt using AES |
[in] | res_cb | Function that will handle the AES based result (16 bytes) |
[in] | src_info | Information used retrieve requester |
uint8_t ble_ext_llcp_cb_reg | ( | struct ble_ext_llcp_cb_func_t * | func | ) |
Registered the extended llcp procedure callback.
[in] | func | ble_ext_llcp_cb_func_t. |
uint8_t ble_ext_llcp_send | ( | uint16_t | conn_idx, |
uint8_t * | param, | ||
uint8_t | ext_opcode | ||
) |
Start a extended llcp procedure.
[in] | conn_idx | function pointer of BLE activity end notification function. |
[in] | param | Pointer to a param which intializer supply. |
[in] | ext_opcode | Extended llcp opcode. |
sdk_err_t ble_hci_host_packet_send | ( | uint8_t * | p_data, |
uint16_t | length | ||
) |
BLE HCI adapter host send packet.
[in] | p_data | Pointer to packet data. |
[in] | length | Length of packet data. |
sdk_err_t ble_hci_init | ( | ble_hci_rx_channel_t * | p_rx_channel, |
ble_hci_host_recv_cb_t | host_recv_cb | ||
) |
Initialize ble hci adapter module.
[in] | p_rx_channel | Pointer to hci adapter rx channel |
[in] | host_recv_cb | Callback to receive controller packet. |
uint16_t ble_hci_rx_channel_surplus_space_get | ( | void | ) |
Get surplus space of controller receive channel.
void ble_idle_time_notify_cb_register | ( | void(*)(uint32_t hs) | callback | ) |
Register BLE idle time notification callback function.
[in] | callback | function pointer of BLE idle time notification function. |
ble_rf_match_circuit_t ble_rf_match_circuit_get | ( | void | ) |
Get the resistance value of the RF match circuit (unit: ohm).
void ble_rf_match_circuit_set | ( | ble_rf_match_circuit_t | e_ohm | ) |
Set the resistance value of the RF match circuit (unit: ohm).
[in] | e_ohm | The resistance value (ohm) of the RF match circuit according to the board, Refer to ble_rf_match_circuit_t. BLE_RF_MATCH_CIRCUIT_25OHM: 25 ohm. BLE_RF_MATCH_CIRCUIT_100OHM: 100 ohm. Others: invalid. |
ble_rf_tx_mode_t ble_rf_tx_mode_get | ( | void | ) |
Get the RF TX mode of LP or ULP.
uint8_t ble_rf_tx_mode_set | ( | ble_rf_tx_mode_t | e_rf_tx_mode | ) |
Change the RF TX mode of LP or ULP.
[in] | e_rf_tx_mode | Refer to ble_rf_tx_mode_t. |
void ble_stack_controller_init | ( | stack_heaps_table_t * | p_heaps_table | ) |
Initialize BLE Stack controller.
[in] | p_heaps_table | Pointer to the BLE stack heaps table. |
void ble_stack_init | ( | ble_evt_handler_t | evt_handler, |
stack_heaps_table_t * | p_heaps_table | ||
) |
Initialize BLE Stack.
[in] | evt_handler | Pointer to the ble event handler. |
[in] | p_heaps_table | Pointer to the BLE stack heaps table. |