ble_gatt_client
|
Go to the source code of this file.
Data Structures | |
struct | hci_request |
struct | hci_version |
Functions | |
int | hci_open_dev (int dev_id) |
int | hci_close_dev (int dd) |
int | hci_send_cmd (int dd, uint16_t ogf, uint16_t ocf, uint8_t plen, void *param) |
int | hci_send_req (int dd, struct hci_request *req, int timeout) |
int | hci_create_connection (int dd, const bdaddr_t *bdaddr, uint16_t ptype, uint16_t clkoffset, uint8_t rswitch, uint16_t *handle, int to) |
int | hci_disconnect (int dd, uint16_t handle, uint8_t reason, int to) |
int | hci_inquiry (int dev_id, int len, int num_rsp, const uint8_t *lap, inquiry_info **ii, long flags) |
int | hci_devinfo (int dev_id, struct hci_dev_info *di) |
int | hci_devba (int dev_id, bdaddr_t *bdaddr) |
int | hci_devid (const char *str) |
int | hci_read_local_name (int dd, int len, char *name, int to) |
int | hci_write_local_name (int dd, const char *name, int to) |
int | hci_read_remote_name (int dd, const bdaddr_t *bdaddr, int len, char *name, int to) |
int | hci_read_remote_name_with_clock_offset (int dd, const bdaddr_t *bdaddr, uint8_t pscan_rep_mode, uint16_t clkoffset, int len, char *name, int to) |
int | hci_read_remote_name_cancel (int dd, const bdaddr_t *bdaddr, int to) |
int | hci_read_remote_version (int dd, uint16_t handle, struct hci_version *ver, int to) |
int | hci_read_remote_features (int dd, uint16_t handle, uint8_t *features, int to) |
int | hci_read_remote_ext_features (int dd, uint16_t handle, uint8_t page, uint8_t *max_page, uint8_t *features, int to) |
int | hci_read_clock_offset (int dd, uint16_t handle, uint16_t *clkoffset, int to) |
int | hci_read_local_version (int dd, struct hci_version *ver, int to) |
int | hci_read_local_commands (int dd, uint8_t *commands, int to) |
int | hci_read_local_features (int dd, uint8_t *features, int to) |
int | hci_read_local_ext_features (int dd, uint8_t page, uint8_t *max_page, uint8_t *features, int to) |
int | hci_read_bd_addr (int dd, bdaddr_t *bdaddr, int to) |
int | hci_read_class_of_dev (int dd, uint8_t *cls, int to) |
int | hci_write_class_of_dev (int dd, uint32_t cls, int to) |
int | hci_read_voice_setting (int dd, uint16_t *vs, int to) |
int | hci_write_voice_setting (int dd, uint16_t vs, int to) |
int | hci_read_current_iac_lap (int dd, uint8_t *num_iac, uint8_t *lap, int to) |
int | hci_write_current_iac_lap (int dd, uint8_t num_iac, uint8_t *lap, int to) |
int | hci_read_stored_link_key (int dd, bdaddr_t *bdaddr, uint8_t all, int to) |
int | hci_write_stored_link_key (int dd, bdaddr_t *bdaddr, uint8_t *key, int to) |
int | hci_delete_stored_link_key (int dd, bdaddr_t *bdaddr, uint8_t all, int to) |
int | hci_authenticate_link (int dd, uint16_t handle, int to) |
int | hci_encrypt_link (int dd, uint16_t handle, uint8_t encrypt, int to) |
int | hci_change_link_key (int dd, uint16_t handle, int to) |
int | hci_switch_role (int dd, bdaddr_t *bdaddr, uint8_t role, int to) |
int | hci_park_mode (int dd, uint16_t handle, uint16_t max_interval, uint16_t min_interval, int to) |
int | hci_exit_park_mode (int dd, uint16_t handle, int to) |
int | hci_read_inquiry_scan_type (int dd, uint8_t *type, int to) |
int | hci_write_inquiry_scan_type (int dd, uint8_t type, int to) |
int | hci_read_inquiry_mode (int dd, uint8_t *mode, int to) |
int | hci_write_inquiry_mode (int dd, uint8_t mode, int to) |
int | hci_read_afh_mode (int dd, uint8_t *mode, int to) |
int | hci_write_afh_mode (int dd, uint8_t mode, int to) |
int | hci_read_ext_inquiry_response (int dd, uint8_t *fec, uint8_t *data, int to) |
int | hci_write_ext_inquiry_response (int dd, uint8_t fec, uint8_t *data, int to) |
int | hci_read_simple_pairing_mode (int dd, uint8_t *mode, int to) |
int | hci_write_simple_pairing_mode (int dd, uint8_t mode, int to) |
int | hci_read_local_oob_data (int dd, uint8_t *hash, uint8_t *randomizer, int to) |
int | hci_read_inq_response_tx_power_level (int dd, int8_t *level, int to) |
int | hci_read_inquiry_transmit_power_level (int dd, int8_t *level, int to) |
int | hci_write_inquiry_transmit_power_level (int dd, int8_t level, int to) |
int | hci_read_transmit_power_level (int dd, uint16_t handle, uint8_t type, int8_t *level, int to) |
int | hci_read_link_policy (int dd, uint16_t handle, uint16_t *policy, int to) |
int | hci_write_link_policy (int dd, uint16_t handle, uint16_t policy, int to) |
int | hci_read_link_supervision_timeout (int dd, uint16_t handle, uint16_t *timeout, int to) |
int | hci_write_link_supervision_timeout (int dd, uint16_t handle, uint16_t timeout, int to) |
int | hci_set_afh_classification (int dd, uint8_t *map, int to) |
int | hci_read_link_quality (int dd, uint16_t handle, uint8_t *link_quality, int to) |
int | hci_read_rssi (int dd, uint16_t handle, int8_t *rssi, int to) |
int | hci_read_afh_map (int dd, uint16_t handle, uint8_t *mode, uint8_t *map, int to) |
int | hci_read_clock (int dd, uint16_t handle, uint8_t which, uint32_t *clock, uint16_t *accuracy, int to) |
int | hci_le_set_scan_enable (int dev_id, uint8_t enable, uint8_t filter_dup, int to) |
int | hci_le_set_scan_parameters (int dev_id, uint8_t type, uint16_t interval, uint16_t window, uint8_t own_type, uint8_t filter, int to) |
int | hci_le_set_advertise_enable (int dev_id, uint8_t enable, int to) |
int | hci_le_create_conn (int dd, uint16_t interval, uint16_t window, uint8_t initiator_filter, uint8_t peer_bdaddr_type, bdaddr_t peer_bdaddr, uint8_t own_bdaddr_type, uint16_t min_interval, uint16_t max_interval, uint16_t latency, uint16_t supervision_timeout, uint16_t min_ce_length, uint16_t max_ce_length, uint16_t *handle, int to) |
int | hci_le_conn_update (int dd, uint16_t handle, uint16_t min_interval, uint16_t max_interval, uint16_t latency, uint16_t supervision_timeout, int to) |
int | hci_le_add_white_list (int dd, const bdaddr_t *bdaddr, uint8_t type, int to) |
int | hci_le_rm_white_list (int dd, const bdaddr_t *bdaddr, uint8_t type, int to) |
int | hci_le_read_white_list_size (int dd, uint8_t *size, int to) |
int | hci_le_clear_white_list (int dd, int to) |
int | hci_le_add_resolving_list (int dd, const bdaddr_t *bdaddr, uint8_t type, uint8_t *peer_irk, uint8_t *local_irk, int to) |
int | hci_le_rm_resolving_list (int dd, const bdaddr_t *bdaddr, uint8_t type, int to) |
int | hci_le_clear_resolving_list (int dd, int to) |
int | hci_le_read_resolving_list_size (int dd, uint8_t *size, int to) |
int | hci_le_set_address_resolution_enable (int dev_id, uint8_t enable, int to) |
int | hci_le_read_remote_features (int dd, uint16_t handle, uint8_t *features, int to) |
int | hci_for_each_dev (int flag, int(*func)(int dd, int dev_id, long arg), long arg) |
int | hci_get_route (bdaddr_t *bdaddr) |
char * | hci_bustostr (int bus) |
char * | hci_typetostr (int type) |
char * | hci_dtypetostr (int type) |
char * | hci_dflagstostr (uint32_t flags) |
char * | hci_ptypetostr (unsigned int ptype) |
int | hci_strtoptype (char *str, unsigned int *val) |
char * | hci_scoptypetostr (unsigned int ptype) |
int | hci_strtoscoptype (char *str, unsigned int *val) |
char * | hci_lptostr (unsigned int ptype) |
int | hci_strtolp (char *str, unsigned int *val) |
char * | hci_lmtostr (unsigned int ptype) |
int | hci_strtolm (char *str, unsigned int *val) |
char * | hci_cmdtostr (unsigned int cmd) |
char * | hci_commandstostr (uint8_t *commands, char *pref, int width) |
char * | hci_vertostr (unsigned int ver) |
int | hci_strtover (char *str, unsigned int *ver) |
char * | lmp_vertostr (unsigned int ver) |
int | lmp_strtover (char *str, unsigned int *ver) |
char * | pal_vertostr (unsigned int ver) |
int | pal_strtover (char *str, unsigned int *ver) |
char * | lmp_featurestostr (uint8_t *features, char *pref, int width) |
static void | hci_set_bit (int nr, void *addr) |
static void | hci_clear_bit (int nr, void *addr) |
static int | hci_test_bit (int nr, void *addr) |
static void | hci_filter_clear (struct hci_filter *f) |
static void | hci_filter_set_ptype (int t, struct hci_filter *f) |
static void | hci_filter_clear_ptype (int t, struct hci_filter *f) |
static int | hci_filter_test_ptype (int t, struct hci_filter *f) |
static void | hci_filter_all_ptypes (struct hci_filter *f) |
static void | hci_filter_set_event (int e, struct hci_filter *f) |
static void | hci_filter_clear_event (int e, struct hci_filter *f) |
static int | hci_filter_test_event (int e, struct hci_filter *f) |
static void | hci_filter_all_events (struct hci_filter *f) |
static void | hci_filter_set_opcode (int opcode, struct hci_filter *f) |
static void | hci_filter_clear_opcode (struct hci_filter *f) |
static int | hci_filter_test_opcode (int opcode, struct hci_filter *f) |
int hci_authenticate_link | ( | int | dd, |
uint16_t | handle, | ||
int | to | ||
) |
dd | |
handle | |
to |
Definition at line 2696 of file hci.c.
References AUTH_REQUESTED_CP_SIZE, hci_request::clen, hci_request::cparam, hci_request::event, EVT_AUTH_COMPLETE, EVT_AUTH_COMPLETE_SIZE, hci_send_req(), hci_request::ocf, OCF_AUTH_REQUESTED, hci_request::ogf, OGF_LINK_CTL, hci_request::rlen, and hci_request::rparam.
char* hci_bustostr | ( | int | bus | ) |
return a string corresponding to the bus code (see HCI bus types in hci.h)
bus | bus code |
Definition at line 189 of file hci.c.
References HCI_PCCARD, HCI_PCI, HCI_RS232, HCI_SDIO, HCI_UART, HCI_USB, and HCI_VIRTUAL.
Referenced by hci_dtypetostr().
int hci_change_link_key | ( | int | dd, |
uint16_t | handle, | ||
int | to | ||
) |
dd | |
handle | |
to |
Definition at line 2768 of file hci.c.
References CHANGE_CONN_LINK_KEY_CP_SIZE, hci_request::clen, hci_request::cparam, hci_request::event, EVT_CHANGE_CONN_LINK_KEY_COMPLETE, EVT_CHANGE_CONN_LINK_KEY_COMPLETE_SIZE, hci_send_req(), hci_request::ocf, OCF_CHANGE_CONN_LINK_KEY, hci_request::ogf, OGF_LINK_CTL, hci_request::rlen, and hci_request::rparam.
|
inlinestatic |
Definition at line 178 of file hci_lib.h.
Referenced by hci_filter_clear_event(), and hci_filter_clear_ptype().
int hci_close_dev | ( | int | dd | ) |
char* hci_cmdtostr | ( | unsigned int | cmd | ) |
translate a command code into an english sentence
use the commands_map table which is an array of structures { "english sentence", command code }
cmd | command code value |
Definition at line 722 of file hci.c.
References hci_uint2str().
char* hci_commandstostr | ( | uint8_t * | commands, |
char * | pref, | ||
int | width | ||
) |
translate a byte array of bit "commands" into a series of corresponding english strings which is returned
commands | an array of bytes corresponding to a list of encoded commands |
pref | prefix to add to str (if pref !=NULL pref will be the first concatenated string) |
width |
Definition at line 735 of file hci.c.
References bt_malloc(), commands_map, hci_map::str, and hci_map::val.
int hci_create_connection | ( | int | dd, |
const bdaddr_t * | bdaddr, | ||
uint16_t | ptype, | ||
uint16_t | clkoffset, | ||
uint8_t | rswitch, | ||
uint16_t * | handle, | ||
int | to | ||
) |
dd | |
bdaddr | |
ptype | |
clkoffset | |
rswitch | |
handle | |
to |
Definition at line 1539 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, CREATE_CONN_CP_SIZE, hci_request::event, EVT_CONN_COMPLETE, EVT_CONN_COMPLETE_SIZE, hci_send_req(), hci_request::ocf, OCF_CREATE_CONN, hci_request::ogf, OGF_LINK_CTL, hci_request::rlen, and hci_request::rparam.
int hci_delete_stored_link_key | ( | int | dd, |
bdaddr_t * | bdaddr, | ||
uint8_t | all, | ||
int | to | ||
) |
dd | |
bdaddr | |
all | |
to |
Definition at line 2670 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, DELETE_STORED_LINK_KEY_CP_SIZE, hci_send_req(), hci_request::ocf, OCF_DELETE_STORED_LINK_KEY, hci_request::ogf, and OGF_HOST_CTL.
int hci_devba | ( | int | dev_id, |
bdaddr_t * | bdaddr | ||
) |
dev_id | |
bdaddr |
Definition at line 1182 of file hci.c.
References bacpy(), hci_dev_info::bdaddr, hci_dev_info::flags, hci_devinfo(), hci_test_bit(), and HCI_UP.
Referenced by hci_devid(), and main().
int hci_devid | ( | const char * | str | ) |
return the bt device number
str | string should be hci<n> |
Definition at line 1130 of file hci.c.
References __same_bdaddr(), hci_devba(), hci_for_each_dev(), HCI_UP, and str2ba().
Referenced by main().
int hci_devinfo | ( | int | dev_id, |
struct hci_dev_info * | di | ||
) |
get device info given device id
dev_id | device id |
di | device info structure if ok |
Definition at line 1155 of file hci.c.
References AF_BLUETOOTH, BTPROTO_HCI, hci_dev_info::dev_id, and HCIGETDEVINFO.
Referenced by hci_devba().
char* hci_dflagstostr | ( | uint32_t | flags | ) |
return the HCI device flags string given its code
flags | HCI device flags code |
Definition at line 260 of file hci.c.
References bt_malloc(), dev_flags_map, hci_test_bit(), HCI_UP, hci_map::str, and hci_map::val.
int hci_disconnect | ( | int | dd, |
uint16_t | handle, | ||
uint8_t | reason, | ||
int | to | ||
) |
dd | |
handle | |
reason | |
to |
Definition at line 1584 of file hci.c.
References hci_request::clen, hci_request::cparam, DISCONNECT_CP_SIZE, hci_request::event, EVT_DISCONN_COMPLETE, EVT_DISCONN_COMPLETE_SIZE, hci_send_req(), hci_request::ocf, OCF_DISCONNECT, hci_request::ogf, OGF_LINK_CTL, hci_request::rlen, and hci_request::rparam.
char* hci_dtypetostr | ( | int | type | ) |
return the bus string according to the bus code (type)
type | bus code |
Definition at line 217 of file hci.c.
References hci_bustostr().
int hci_encrypt_link | ( | int | dd, |
uint16_t | handle, | ||
uint8_t | encrypt, | ||
int | to | ||
) |
dd | |
handle | |
encrypt | |
to |
Definition at line 2732 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_request::event, EVT_ENCRYPT_CHANGE, EVT_ENCRYPT_CHANGE_SIZE, hci_send_req(), hci_request::ocf, OCF_SET_CONN_ENCRYPT, hci_request::ogf, OGF_LINK_CTL, hci_request::rlen, hci_request::rparam, and SET_CONN_ENCRYPT_CP_SIZE.
int hci_exit_park_mode | ( | int | dd, |
uint16_t | handle, | ||
int | to | ||
) |
dd | |
handle | |
to |
Definition at line 2881 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_request::event, EVT_MODE_CHANGE, EVT_MODE_CHANGE_SIZE, EXIT_PARK_MODE_CP_SIZE, hci_send_req(), hci_request::ocf, OCF_EXIT_PARK_MODE, hci_request::ogf, OGF_LINK_POLICY, hci_request::rlen, and hci_request::rparam.
|
inlinestatic |
Definition at line 221 of file hci_lib.h.
References hci_filter::event_mask.
|
inlinestatic |
Definition at line 205 of file hci_lib.h.
References hci_filter::type_mask.
|
inlinestatic |
Definition at line 189 of file hci_lib.h.
Referenced by hci_send_req().
|
inlinestatic |
Definition at line 213 of file hci_lib.h.
References hci_filter::event_mask, hci_clear_bit(), and HCI_FLT_EVENT_BITS.
|
inlinestatic |
Definition at line 229 of file hci_lib.h.
References hci_filter::opcode.
|
inlinestatic |
Definition at line 197 of file hci_lib.h.
References hci_clear_bit(), HCI_FLT_TYPE_BITS, HCI_VENDOR_PKT, and hci_filter::type_mask.
|
inlinestatic |
Definition at line 209 of file hci_lib.h.
References hci_filter::event_mask, HCI_FLT_EVENT_BITS, and hci_set_bit().
Referenced by hci_send_req().
|
inlinestatic |
Definition at line 225 of file hci_lib.h.
References opcode, and hci_filter::opcode.
Referenced by hci_send_req().
|
inlinestatic |
Definition at line 193 of file hci_lib.h.
References HCI_FLT_TYPE_BITS, hci_set_bit(), HCI_VENDOR_PKT, and hci_filter::type_mask.
Referenced by hci_send_req().
|
inlinestatic |
Definition at line 217 of file hci_lib.h.
References hci_filter::event_mask, HCI_FLT_EVENT_BITS, and hci_test_bit().
|
inlinestatic |
Definition at line 233 of file hci_lib.h.
References hci_filter::opcode.
|
inlinestatic |
Definition at line 201 of file hci_lib.h.
References HCI_FLT_TYPE_BITS, hci_test_bit(), HCI_VENDOR_PKT, and hci_filter::type_mask.
int hci_for_each_dev | ( | int | flag, |
int(*)(int dd, int dev_id, long arg) | func, | ||
long | arg | ||
) |
return the bt device number
flag | |
func | |
arg |
Definition at line 1019 of file hci.c.
References AF_BLUETOOTH, BTPROTO_HCI, hci_dev_req::dev_id, hci_dev_list_req::dev_num, hci_dev_req::dev_opt, hci_dev_list_req::dev_req, func, HCI_MAX_DEV, hci_test_bit(), and HCIGETDEVLIST.
Referenced by hci_devid(), and hci_get_route().
int hci_get_route | ( | bdaddr_t * | bdaddr | ) |
bdaddr |
Definition at line 1111 of file hci.c.
References __other_bdaddr(), __same_bdaddr(), BDADDR_ANY, hci_dev_info::dev_id, hci_for_each_dev(), and HCI_UP.
Referenced by hci_inquiry().
int hci_inquiry | ( | int | dev_id, |
int | len, | ||
int | nrsp, | ||
const uint8_t * | lap, | ||
inquiry_info ** | ii, | ||
long | flags | ||
) |
dev_id | |
len | |
nrsp | |
lap | |
ii | |
flags |
Definition at line 1212 of file hci.c.
References AF_BLUETOOTH, BTPROTO_HCI, hci_inquiry_req::dev_id, hci_inquiry_req::flags, hci_get_route(), HCIINQUIRY, hci_inquiry_req::lap, hci_inquiry_req::length, and hci_inquiry_req::num_rsp.
int hci_le_add_resolving_list | ( | int | dd, |
const bdaddr_t * | bdaddr, | ||
uint8_t | type, | ||
uint8_t * | peer_irk, | ||
uint8_t * | local_irk, | ||
int | to | ||
) |
dd | |
bdaddr | |
type | |
peer_irk | |
local_irk | |
to |
Definition at line 1764 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, hci_send_req(), LE_ADD_DEVICE_TO_RESOLV_LIST_CP_SIZE, hci_request::ocf, OCF_LE_ADD_DEVICE_TO_RESOLV_LIST, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, hci_request::rparam, and type.
int hci_le_add_white_list | ( | int | dd, |
const bdaddr_t * | bdaddr, | ||
uint8_t | type, | ||
int | to | ||
) |
dd | |
bdaddr | |
type | |
to |
Definition at line 1622 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, hci_send_req(), LE_ADD_DEVICE_TO_WHITE_LIST_CP_SIZE, hci_request::ocf, OCF_LE_ADD_DEVICE_TO_WHITE_LIST, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, hci_request::rparam, and type.
int hci_le_clear_resolving_list | ( | int | dd, |
int | to | ||
) |
dd | |
to |
Definition at line 1843 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_LE_CLEAR_RESOLV_LIST, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_clear_white_list | ( | int | dd, |
int | to | ||
) |
dd | |
to |
Definition at line 1731 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_LE_CLEAR_WHITE_LIST, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_conn_update | ( | int | dd, |
uint16_t | handle, | ||
uint16_t | min_interval, | ||
uint16_t | max_interval, | ||
uint16_t | latency, | ||
uint16_t | supervision_timeout, | ||
int | to | ||
) |
dd | |
handle | |
min_interval | |
max_interval | |
latency | |
supervision_timeout | |
to |
Definition at line 3936 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_request::event, EVT_LE_CONN_UPDATE_COMPLETE, hci_send_req(), htobs, LE_CONN_UPDATE_CP_SIZE, hci_request::ocf, OCF_LE_CONN_UPDATE, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_create_conn | ( | int | dd, |
uint16_t | interval, | ||
uint16_t | window, | ||
uint8_t | initiator_filter, | ||
uint8_t | peer_bdaddr_type, | ||
bdaddr_t | peer_bdaddr, | ||
uint8_t | own_bdaddr_type, | ||
uint16_t | min_interval, | ||
uint16_t | max_interval, | ||
uint16_t | latency, | ||
uint16_t | supervision_timeout, | ||
uint16_t | min_ce_length, | ||
uint16_t | max_ce_length, | ||
uint16_t * | handle, | ||
int | to | ||
) |
dd | |
interval | |
window | |
initiator_filter | |
peer_bdaddr_type | |
peer_bdaddr | |
own_bdaddr_type | |
min_interval | |
max_interval | |
latency | |
supervision_timeout | |
min_ce_length | |
max_ce_length | |
handle | |
to |
Definition at line 3875 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_request::event, EVT_CONN_COMPLETE_SIZE, EVT_LE_CONN_COMPLETE, hci_send_req(), LE_CREATE_CONN_CP_SIZE, hci_request::ocf, OCF_LE_CREATE_CONN, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_read_remote_features | ( | int | dd, |
uint16_t | handle, | ||
uint8_t * | features, | ||
int | to | ||
) |
dd | |
handle | |
features | |
to |
Definition at line 3982 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_request::event, EVT_LE_READ_REMOTE_USED_FEATURES_COMPLETE, EVT_LE_READ_REMOTE_USED_FEATURES_COMPLETE_SIZE, hci_send_req(), LE_READ_REMOTE_USED_FEATURES_CP_SIZE, hci_request::ocf, OCF_LE_READ_REMOTE_USED_FEATURES, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_read_resolving_list_size | ( | int | dd, |
uint8_t * | size, | ||
int | to | ||
) |
dd | |
size | |
to |
Definition at line 1873 of file hci.c.
References hci_send_req(), LE_READ_RESOLV_LIST_SIZE_RP_SIZE, hci_request::ocf, OCF_LE_READ_RESOLV_LIST_SIZE, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_read_white_list_size | ( | int | dd, |
uint8_t * | size, | ||
int | to | ||
) |
dd | |
size | |
to |
Definition at line 1697 of file hci.c.
References hci_send_req(), LE_READ_WHITE_LIST_SIZE_RP_SIZE, hci_request::ocf, OCF_LE_READ_WHITE_LIST_SIZE, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_rm_resolving_list | ( | int | dd, |
const bdaddr_t * | bdaddr, | ||
uint8_t | type, | ||
int | to | ||
) |
dd | |
bdaddr | |
type | |
to |
Definition at line 1807 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, hci_send_req(), LE_REMOVE_DEVICE_FROM_RESOLV_LIST_CP_SIZE, hci_request::ocf, OCF_LE_REMOVE_DEVICE_FROM_RESOLV_LIST, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, hci_request::rparam, and type.
int hci_le_rm_white_list | ( | int | dd, |
const bdaddr_t * | bdaddr, | ||
uint8_t | type, | ||
int | to | ||
) |
dd | |
bdaddr | |
type | |
to |
Definition at line 1660 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, hci_send_req(), LE_REMOVE_DEVICE_FROM_WHITE_LIST_CP_SIZE, hci_request::ocf, OCF_LE_REMOVE_DEVICE_FROM_WHITE_LIST, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, hci_request::rparam, and type.
int hci_le_set_address_resolution_enable | ( | int | dd, |
uint8_t | enable, | ||
int | to | ||
) |
dd | |
enable | |
to |
Definition at line 1908 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), LE_SET_ADDRESS_RESOLUTION_ENABLE_CP_SIZE, hci_request::ocf, OCF_LE_SET_ADDRESS_RESOLUTION_ENABLE, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_set_advertise_enable | ( | int | dd, |
uint8_t | enable, | ||
int | to | ||
) |
dd | |
enable | |
to |
Definition at line 3827 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), LE_SET_ADVERTISE_ENABLE_CP_SIZE, hci_request::ocf, OCF_LE_SET_ADVERTISE_ENABLE, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_set_scan_enable | ( | int | dd, |
uint8_t | enable, | ||
uint8_t | filter_dup, | ||
int | to | ||
) |
dd | |
enable | |
filter_dup | |
to |
Definition at line 3744 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), LE_SET_SCAN_ENABLE_CP_SIZE, hci_request::ocf, OCF_LE_SET_SCAN_ENABLE, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, and hci_request::rparam.
int hci_le_set_scan_parameters | ( | int | dd, |
uint8_t | type, | ||
uint16_t | interval, | ||
uint16_t | window, | ||
uint8_t | own_type, | ||
uint8_t | filter, | ||
int | to | ||
) |
dd | |
type | |
interval | |
window | |
own_type | |
filter | |
to |
Definition at line 3785 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), LE_SET_SCAN_PARAMETERS_CP_SIZE, hci_request::ocf, OCF_LE_SET_SCAN_PARAMETERS, hci_request::ogf, OGF_LE_CTL, hci_request::rlen, hci_request::rparam, and type.
char* hci_lmtostr | ( | unsigned int | lm | ) |
return the Link mode mapping string given the code
lm | Link mode mapping code |
Definition at line 415 of file hci.c.
References bt_free(), bt_malloc(), hci_bit2str(), and HCI_LM_MASTER.
char* hci_lptostr | ( | unsigned int | lp | ) |
return the Link policy mapping string given the code
lp | Link policy mapping code |
Definition at line 379 of file hci.c.
References hci_bit2str().
int hci_open_dev | ( | int | dev_id | ) |
Open HCI device.
dev_id | integer device address |
Definition at line 1287 of file hci.c.
References AF_BLUETOOTH, BTPROTO_HCI, sockaddr_hci::hci_dev, and sockaddr_hci::hci_family.
int hci_park_mode | ( | int | dd, |
uint16_t | handle, | ||
uint16_t | max_interval, | ||
uint16_t | min_interval, | ||
int | to | ||
) |
dd | |
handle | |
max_interval | |
min_interval | |
to |
Definition at line 2841 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_request::event, EVT_MODE_CHANGE, EVT_MODE_CHANGE_SIZE, hci_send_req(), hci_request::ocf, OCF_PARK_MODE, hci_request::ogf, OGF_LINK_POLICY, PARK_MODE_CP_SIZE, hci_request::rlen, and hci_request::rparam.
char* hci_ptypetostr | ( | unsigned int | ptype | ) |
return the HCI packet type string given the code
ptype | HCI packet type |
Definition at line 323 of file hci.c.
References hci_bit2str().
int hci_read_afh_map | ( | int | dd, |
uint16_t | handle, | ||
uint8_t * | mode, | ||
uint8_t * | map, | ||
int | to | ||
) |
dd | |
handle | |
mode | |
map | |
to |
Definition at line 3665 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_READ_AFH_MAP, hci_request::ogf, OGF_STATUS_PARAM, READ_AFH_MAP_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_afh_mode | ( | int | dd, |
uint8_t * | mode, | ||
int | to | ||
) |
dd | |
mode | |
to |
Definition at line 3052 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_AFH_MODE, hci_request::ogf, OGF_HOST_CTL, READ_AFH_MODE_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_bd_addr | ( | int | dd, |
bdaddr_t * | bdaddr, | ||
int | to | ||
) |
dd | |
bdaddr | |
to |
Definition at line 2412 of file hci.c.
References bacpy(), hci_send_req(), hci_request::ocf, OCF_READ_BD_ADDR, hci_request::ogf, OGF_INFO_PARAM, READ_BD_ADDR_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_class_of_dev | ( | int | dd, |
uint8_t * | cls, | ||
int | to | ||
) |
dd | |
cls | |
to |
Definition at line 2445 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_CLASS_OF_DEV, hci_request::ogf, OGF_HOST_CTL, READ_CLASS_OF_DEV_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_clock | ( | int | dd, |
uint16_t | handle, | ||
uint8_t | which, | ||
uint32_t * | clock, | ||
uint16_t * | accuracy, | ||
int | to | ||
) |
dd | |
handle | |
which | |
clock | |
accuracy | |
to |
Definition at line 3703 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_READ_CLOCK, hci_request::ogf, OGF_STATUS_PARAM, READ_CLOCK_CP_SIZE, READ_CLOCK_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_clock_offset | ( | int | dd, |
uint16_t | handle, | ||
uint16_t * | clkoffset, | ||
int | to | ||
) |
dd | |
handle | |
clkoffset | |
to |
Definition at line 2229 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_request::event, EVT_READ_CLOCK_OFFSET_COMPLETE, EVT_READ_CLOCK_OFFSET_COMPLETE_SIZE, hci_send_req(), hci_request::ocf, OCF_READ_CLOCK_OFFSET, hci_request::ogf, OGF_LINK_CTL, READ_CLOCK_OFFSET_CP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_current_iac_lap | ( | int | dd, |
uint8_t * | num_iac, | ||
uint8_t * | lap, | ||
int | to | ||
) |
dd | |
num_iac | |
lap | |
to |
Definition at line 2555 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_CURRENT_IAC_LAP, hci_request::ogf, OGF_HOST_CTL, READ_CURRENT_IAC_LAP_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_ext_inquiry_response | ( | int | dd, |
uint8_t * | fec, | ||
uint8_t * | data, | ||
int | to | ||
) |
dd | |
fec | |
data | |
to |
Definition at line 3120 of file hci.c.
References HCI_MAX_EIR_LENGTH, hci_send_req(), hci_request::ocf, OCF_READ_EXT_INQUIRY_RESPONSE, hci_request::ogf, OGF_HOST_CTL, READ_EXT_INQUIRY_RESPONSE_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_inq_response_tx_power_level | ( | int | dd, |
int8_t * | level, | ||
int | to | ||
) |
dd | |
level | |
to |
Definition at line 3291 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_INQ_RESPONSE_TX_POWER_LEVEL, hci_request::ogf, OGF_HOST_CTL, READ_INQ_RESPONSE_TX_POWER_LEVEL_RP_SIZE, hci_request::rlen, and hci_request::rparam.
Referenced by hci_read_inquiry_transmit_power_level().
int hci_read_inquiry_mode | ( | int | dd, |
uint8_t * | mode, | ||
int | to | ||
) |
dd | |
mode | |
to |
Definition at line 2985 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_INQUIRY_MODE, hci_request::ogf, OGF_HOST_CTL, READ_INQUIRY_MODE_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_inquiry_scan_type | ( | int | dd, |
uint8_t * | type, | ||
int | to | ||
) |
dd | |
type | |
to |
Definition at line 2918 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_INQUIRY_SCAN_TYPE, hci_request::ogf, OGF_HOST_CTL, READ_INQUIRY_SCAN_TYPE_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_inquiry_transmit_power_level | ( | int | dd, |
int8_t * | level, | ||
int | to | ||
) |
dd | |
level | |
to |
Definition at line 3322 of file hci.c.
References hci_read_inq_response_tx_power_level().
int hci_read_link_policy | ( | int | dd, |
uint16_t | handle, | ||
uint16_t * | policy, | ||
int | to | ||
) |
dd | |
handle | |
policy | |
to |
Definition at line 3413 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_READ_LINK_POLICY, hci_request::ogf, OGF_LINK_POLICY, READ_LINK_POLICY_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_link_quality | ( | int | dd, |
uint16_t | handle, | ||
uint8_t * | link_quality, | ||
int | to | ||
) |
dd | |
handle | |
link_quality | |
to |
Definition at line 3595 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_READ_LINK_QUALITY, hci_request::ogf, OGF_STATUS_PARAM, READ_LINK_QUALITY_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_link_supervision_timeout | ( | int | dd, |
uint16_t | handle, | ||
uint16_t * | timeout, | ||
int | to | ||
) |
dd | |
handle | |
timeout | |
to |
Definition at line 3485 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_READ_LINK_SUPERVISION_TIMEOUT, hci_request::ogf, OGF_HOST_CTL, READ_LINK_SUPERVISION_TIMEOUT_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_local_commands | ( | int | dd, |
uint8_t * | commands, | ||
int | to | ||
) |
dd | |
commands | |
to |
Definition at line 2302 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_LOCAL_COMMANDS, hci_request::ogf, OGF_INFO_PARAM, READ_LOCAL_COMMANDS_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_local_ext_features | ( | int | dd, |
uint8_t | page, | ||
uint8_t * | max_page, | ||
uint8_t * | features, | ||
int | to | ||
) |
dd | |
page | |
max_page | |
features | |
to |
Definition at line 2370 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_READ_LOCAL_EXT_FEATURES, hci_request::ogf, OGF_INFO_PARAM, READ_LOCAL_EXT_FEATURES_CP_SIZE, READ_LOCAL_EXT_FEATURES_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_local_features | ( | int | dd, |
uint8_t * | features, | ||
int | to | ||
) |
dd | |
features | |
to |
Definition at line 2335 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_LOCAL_FEATURES, hci_request::ogf, OGF_INFO_PARAM, READ_LOCAL_FEATURES_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_local_name | ( | int | dd, |
int | len, | ||
char * | name, | ||
int | to | ||
) |
dd | |
len | |
name | |
to |
Definition at line 1943 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_LOCAL_NAME, hci_request::ogf, OGF_HOST_CTL, READ_LOCAL_NAME_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_local_oob_data | ( | int | dd, |
uint8_t * | hash, | ||
uint8_t * | randomizer, | ||
int | to | ||
) |
dd | |
hash | |
randomizer | |
to |
Definition at line 3259 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_LOCAL_OOB_DATA, hci_request::ogf, OGF_HOST_CTL, READ_LOCAL_OOB_DATA_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_local_version | ( | int | dd, |
struct hci_version * | ver, | ||
int | to | ||
) |
dd | |
ver | |
to |
Definition at line 2267 of file hci.c.
References btohs, hci_version::hci_rev, hci_send_req(), hci_version::hci_ver, hci_version::lmp_subver, hci_version::lmp_ver, hci_version::manufacturer, hci_request::ocf, OCF_READ_LOCAL_VERSION, hci_request::ogf, OGF_INFO_PARAM, READ_LOCAL_VERSION_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_remote_ext_features | ( | int | dd, |
uint16_t | handle, | ||
uint8_t | page, | ||
uint8_t * | max_page, | ||
uint8_t * | features, | ||
int | to | ||
) |
dd | |
handle | |
page | |
max_page | |
features | |
to |
Definition at line 2182 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_request::event, EVT_READ_REMOTE_EXT_FEATURES_COMPLETE, EVT_READ_REMOTE_EXT_FEATURES_COMPLETE_SIZE, hci_send_req(), hci_request::ocf, OCF_READ_REMOTE_EXT_FEATURES, hci_request::ogf, OGF_LINK_CTL, READ_REMOTE_EXT_FEATURES_CP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_remote_features | ( | int | dd, |
uint16_t | handle, | ||
uint8_t * | features, | ||
int | to | ||
) |
dd | |
handle | |
features | |
to |
Definition at line 2139 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_request::event, EVT_READ_REMOTE_FEATURES_COMPLETE, EVT_READ_REMOTE_FEATURES_COMPLETE_SIZE, hci_send_req(), hci_request::ocf, OCF_READ_REMOTE_FEATURES, hci_request::ogf, OGF_LINK_CTL, READ_REMOTE_FEATURES_CP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_remote_name | ( | int | dd, |
const bdaddr_t * | bdaddr, | ||
int | len, | ||
char * | name, | ||
int | to | ||
) |
dd | |
bdaddr | |
len | |
name | |
to |
Definition at line 2053 of file hci.c.
References hci_read_remote_name_with_clock_offset().
int hci_read_remote_name_cancel | ( | int | dd, |
const bdaddr_t * | bdaddr, | ||
int | to | ||
) |
dd | |
bdaddr | |
to |
Definition at line 2068 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_REMOTE_NAME_REQ_CANCEL, hci_request::ogf, OGF_LINK_CTL, and REMOTE_NAME_REQ_CANCEL_CP_SIZE.
int hci_read_remote_name_with_clock_offset | ( | int | dd, |
const bdaddr_t * | bdaddr, | ||
uint8_t | pscan_rep_mode, | ||
uint16_t | clkoffset, | ||
int | len, | ||
char * | name, | ||
int | to | ||
) |
dd | |
bdaddr | |
pscan_rep_mode | |
clkoffset | |
len | |
name | |
to |
Definition at line 2007 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, hci_request::event, EVT_REMOTE_NAME_REQ_COMPLETE, EVT_REMOTE_NAME_REQ_COMPLETE_SIZE, hci_send_req(), hci_request::ocf, OCF_REMOTE_NAME_REQ, hci_request::ogf, OGF_LINK_CTL, REMOTE_NAME_REQ_CP_SIZE, hci_request::rlen, and hci_request::rparam.
Referenced by hci_read_remote_name().
int hci_read_remote_version | ( | int | dd, |
uint16_t | handle, | ||
struct hci_version * | ver, | ||
int | to | ||
) |
dd | |
handle | |
ver | |
to |
Definition at line 2097 of file hci.c.
References btohs, hci_request::clen, hci_request::cparam, hci_request::event, EVT_READ_REMOTE_VERSION_COMPLETE, EVT_READ_REMOTE_VERSION_COMPLETE_SIZE, hci_send_req(), hci_version::lmp_subver, hci_version::lmp_ver, hci_version::manufacturer, hci_request::ocf, OCF_READ_REMOTE_VERSION, hci_request::ogf, OGF_LINK_CTL, READ_REMOTE_VERSION_CP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_rssi | ( | int | dd, |
uint16_t | handle, | ||
int8_t * | rssi, | ||
int | to | ||
) |
dd | |
handle | |
rssi | |
to |
Definition at line 3630 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_READ_RSSI, hci_request::ogf, OGF_STATUS_PARAM, READ_RSSI_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_simple_pairing_mode | ( | int | dd, |
uint8_t * | mode, | ||
int | to | ||
) |
dd | |
mode | |
to |
Definition at line 3191 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_SIMPLE_PAIRING_MODE, hci_request::ogf, OGF_HOST_CTL, READ_SIMPLE_PAIRING_MODE_RP_SIZE, hci_request::rlen, and hci_request::rparam.
int hci_read_stored_link_key | ( | int | dd, |
bdaddr_t * | bdaddr, | ||
uint8_t | all, | ||
int | to | ||
) |
dd | |
bdaddr | |
all | |
to |
Definition at line 2615 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_READ_STORED_LINK_KEY, hci_request::ogf, OGF_HOST_CTL, and READ_STORED_LINK_KEY_CP_SIZE.
int hci_read_transmit_power_level | ( | int | dd, |
uint16_t | handle, | ||
uint8_t | type, | ||
int8_t * | level, | ||
int | to | ||
) |
dd | |
handle | |
type | |
level | |
to |
Definition at line 3373 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_READ_TRANSMIT_POWER_LEVEL, hci_request::ogf, OGF_HOST_CTL, READ_TRANSMIT_POWER_LEVEL_CP_SIZE, READ_TRANSMIT_POWER_LEVEL_RP_SIZE, hci_request::rlen, hci_request::rparam, and type.
int hci_read_voice_setting | ( | int | dd, |
uint16_t * | vs, | ||
int | to | ||
) |
dd | |
vs | |
to |
Definition at line 2500 of file hci.c.
References hci_send_req(), hci_request::ocf, OCF_READ_VOICE_SETTING, hci_request::ogf, OGF_HOST_CTL, READ_VOICE_SETTING_RP_SIZE, hci_request::rlen, and hci_request::rparam.
char* hci_scoptypetostr | ( | unsigned int | ptype | ) |
return the SCO (synchronous connection orientated) links string given the code
ptype | SCO type code |
Definition at line 346 of file hci.c.
References hci_bit2str().
int hci_send_cmd | ( | int | dd, |
uint16_t | ogf, | ||
uint16_t | ocf, | ||
uint8_t | plen, | ||
void * | param | ||
) |
dd | Device descriptor returned by hci_open_dev. |
ogf | |
ocf | |
plen | |
param |
Definition at line 1343 of file hci.c.
References cmd_opcode_pack, HCI_COMMAND_HDR_SIZE, HCI_COMMAND_PKT, htobs, and type.
Referenced by hci_send_req().
int hci_send_req | ( | int | dd, |
struct hci_request * | r, | ||
int | to | ||
) |
dd | |
r | |
to |
Definition at line 1381 of file hci.c.
References bacmp(), hci_request::clen, cmd_opcode_pack, hci_request::cparam, hci_request::event, EVT_CMD_COMPLETE, EVT_CMD_COMPLETE_SIZE, EVT_CMD_STATUS, EVT_LE_META_EVENT, EVT_REMOTE_NAME_REQ_COMPLETE, HCI_EVENT_HDR_SIZE, HCI_EVENT_PKT, HCI_FILTER, hci_filter_clear(), hci_filter_set_event(), hci_filter_set_opcode(), hci_filter_set_ptype(), HCI_MAX_EVENT_SIZE, hci_send_cmd(), htobs, MIN, hci_request::ocf, hci_request::ogf, opcode, hci_request::rlen, hci_request::rparam, and SOL_HCI.
Referenced by hci_authenticate_link(), hci_change_link_key(), hci_create_connection(), hci_delete_stored_link_key(), hci_disconnect(), hci_encrypt_link(), hci_exit_park_mode(), hci_le_add_resolving_list(), hci_le_add_white_list(), hci_le_clear_resolving_list(), hci_le_clear_white_list(), hci_le_conn_update(), hci_le_create_conn(), hci_le_read_remote_features(), hci_le_read_resolving_list_size(), hci_le_read_white_list_size(), hci_le_rm_resolving_list(), hci_le_rm_white_list(), hci_le_set_address_resolution_enable(), hci_le_set_advertise_enable(), hci_le_set_scan_enable(), hci_le_set_scan_parameters(), hci_park_mode(), hci_read_afh_map(), hci_read_afh_mode(), hci_read_bd_addr(), hci_read_class_of_dev(), hci_read_clock(), hci_read_clock_offset(), hci_read_current_iac_lap(), hci_read_ext_inquiry_response(), hci_read_inq_response_tx_power_level(), hci_read_inquiry_mode(), hci_read_inquiry_scan_type(), hci_read_link_policy(), hci_read_link_quality(), hci_read_link_supervision_timeout(), hci_read_local_commands(), hci_read_local_ext_features(), hci_read_local_features(), hci_read_local_name(), hci_read_local_oob_data(), hci_read_local_version(), hci_read_remote_ext_features(), hci_read_remote_features(), hci_read_remote_name_cancel(), hci_read_remote_name_with_clock_offset(), hci_read_remote_version(), hci_read_rssi(), hci_read_simple_pairing_mode(), hci_read_stored_link_key(), hci_read_transmit_power_level(), hci_read_voice_setting(), hci_set_afh_classification(), hci_switch_role(), hci_write_afh_mode(), hci_write_class_of_dev(), hci_write_current_iac_lap(), hci_write_ext_inquiry_response(), hci_write_inquiry_mode(), hci_write_inquiry_scan_type(), hci_write_inquiry_transmit_power_level(), hci_write_link_policy(), hci_write_link_supervision_timeout(), hci_write_local_name(), hci_write_simple_pairing_mode(), hci_write_stored_link_key(), and hci_write_voice_setting().
int hci_set_afh_classification | ( | int | dd, |
uint8_t * | map, | ||
int | to | ||
) |
dd | |
map | |
to |
Definition at line 3558 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_SET_AFH_CLASSIFICATION, hci_request::ogf, OGF_HOST_CTL, hci_request::rlen, hci_request::rparam, SET_AFH_CLASSIFICATION_CP_SIZE, and SET_AFH_CLASSIFICATION_RP_SIZE.
|
inlinestatic |
Definition at line 173 of file hci_lib.h.
Referenced by hci_filter_set_event(), and hci_filter_set_ptype().
int hci_strtolm | ( | char * | str, |
unsigned int * | val | ||
) |
retrun Link mode mapping code given the tring
str | Link mode mapping string |
val | Link mode mapping code |
Definition at line 443 of file hci.c.
References hci_str2bit().
int hci_strtolp | ( | char * | str, |
unsigned int * | val | ||
) |
return Link policy mapping code given the string
str | Link policy mapping string |
val | Link policy mapping code |
Definition at line 391 of file hci.c.
References hci_str2bit().
int hci_strtoptype | ( | char * | str, |
unsigned int * | val | ||
) |
return the HCI packet type code given the string
str | HCI packet type string |
val | HCI packet type code |
Definition at line 335 of file hci.c.
References hci_str2bit().
int hci_strtoscoptype | ( | char * | str, |
unsigned int * | val | ||
) |
return the SCO (synchronous connection orientated) links code given the string
str | SCO (synchronous connection orientated) links string |
val | SCO (synchronous connection orientated) links code |
Definition at line 358 of file hci.c.
References hci_str2bit().
int hci_strtover | ( | char * | str, |
unsigned int * | ver | ||
) |
return the version code given the string
str | version string |
ver | version code |
Definition at line 809 of file hci.c.
References hci_str2uint().
int hci_switch_role | ( | int | dd, |
bdaddr_t * | bdaddr, | ||
uint8_t | role, | ||
int | to | ||
) |
dd | |
bdaddr | |
role | |
to |
Definition at line 2804 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, hci_request::event, EVT_ROLE_CHANGE, EVT_ROLE_CHANGE_SIZE, hci_send_req(), hci_request::ocf, OCF_SWITCH_ROLE, hci_request::ogf, OGF_LINK_POLICY, hci_request::rlen, hci_request::rparam, and SWITCH_ROLE_CP_SIZE.
|
inlinestatic |
Definition at line 183 of file hci_lib.h.
Referenced by __other_bdaddr(), hci_devba(), hci_dflagstostr(), hci_filter_test_event(), hci_filter_test_ptype(), and hci_for_each_dev().
char* hci_typetostr | ( | int | type | ) |
char* hci_vertostr | ( | unsigned int | ver | ) |
translate a version code into a mapping string
ver | version code |
Definition at line 797 of file hci.c.
References hci_uint2str().
int hci_write_afh_mode | ( | int | dd, |
uint8_t | mode, | ||
int | to | ||
) |
dd | |
mode | |
to |
Definition at line 3083 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_AFH_MODE, hci_request::ogf, OGF_HOST_CTL, hci_request::rlen, hci_request::rparam, WRITE_AFH_MODE_CP_SIZE, and WRITE_AFH_MODE_RP_SIZE.
int hci_write_class_of_dev | ( | int | dd, |
uint32_t | cls, | ||
int | to | ||
) |
dd | |
cls | |
to |
Definition at line 2476 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_CLASS_OF_DEV, hci_request::ogf, OGF_HOST_CTL, and WRITE_CLASS_OF_DEV_CP_SIZE.
int hci_write_current_iac_lap | ( | int | dd, |
uint8_t | num_iac, | ||
uint8_t * | lap, | ||
int | to | ||
) |
dd | |
num_iac | |
lap | |
to |
Definition at line 2588 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_CURRENT_IAC_LAP, hci_request::ogf, and OGF_HOST_CTL.
int hci_write_ext_inquiry_response | ( | int | dd, |
uint8_t | fec, | ||
uint8_t * | data, | ||
int | to | ||
) |
dd | |
fec | |
data | |
to |
Definition at line 3154 of file hci.c.
References hci_request::clen, hci_request::cparam, HCI_MAX_EIR_LENGTH, hci_send_req(), hci_request::ocf, OCF_WRITE_EXT_INQUIRY_RESPONSE, hci_request::ogf, OGF_HOST_CTL, hci_request::rlen, hci_request::rparam, WRITE_EXT_INQUIRY_RESPONSE_CP_SIZE, and WRITE_EXT_INQUIRY_RESPONSE_RP_SIZE.
int hci_write_inquiry_mode | ( | int | dd, |
uint8_t | mode, | ||
int | to | ||
) |
dd | |
mode | |
to |
Definition at line 3016 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_INQUIRY_MODE, hci_request::ogf, OGF_HOST_CTL, hci_request::rlen, hci_request::rparam, WRITE_INQUIRY_MODE_CP_SIZE, and WRITE_INQUIRY_MODE_RP_SIZE.
int hci_write_inquiry_scan_type | ( | int | dd, |
uint8_t | type, | ||
int | to | ||
) |
dd | |
type | |
to |
Definition at line 2949 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_INQUIRY_SCAN_TYPE, hci_request::ogf, OGF_HOST_CTL, hci_request::rlen, hci_request::rparam, type, WRITE_INQUIRY_SCAN_TYPE_CP_SIZE, and WRITE_INQUIRY_SCAN_TYPE_RP_SIZE.
int hci_write_inquiry_transmit_power_level | ( | int | dd, |
int8_t | level, | ||
int | to | ||
) |
dd | |
level | |
to |
Definition at line 3335 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_INQUIRY_TRANSMIT_POWER_LEVEL, hci_request::ogf, OGF_HOST_CTL, hci_request::rlen, hci_request::rparam, WRITE_INQUIRY_TRANSMIT_POWER_LEVEL_CP_SIZE, and WRITE_INQUIRY_TRANSMIT_POWER_LEVEL_RP_SIZE.
int hci_write_link_policy | ( | int | dd, |
uint16_t | handle, | ||
uint16_t | policy, | ||
int | to | ||
) |
dd | |
handle | |
policy | |
to |
Definition at line 3447 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_LINK_POLICY, hci_request::ogf, OGF_LINK_POLICY, hci_request::rlen, hci_request::rparam, WRITE_LINK_POLICY_CP_SIZE, and WRITE_LINK_POLICY_RP_SIZE.
int hci_write_link_supervision_timeout | ( | int | dd, |
uint16_t | handle, | ||
uint16_t | timeout, | ||
int | to | ||
) |
dd | |
handle | |
timeout | |
to |
Definition at line 3520 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_LINK_SUPERVISION_TIMEOUT, hci_request::ogf, OGF_HOST_CTL, hci_request::rlen, hci_request::rparam, WRITE_LINK_SUPERVISION_TIMEOUT_CP_SIZE, and WRITE_LINK_SUPERVISION_TIMEOUT_RP_SIZE.
int hci_write_local_name | ( | int | dd, |
const char * | name, | ||
int | to | ||
) |
dd | |
name | |
to |
Definition at line 1975 of file hci.c.
References CHANGE_LOCAL_NAME_CP_SIZE, hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_CHANGE_LOCAL_NAME, hci_request::ogf, and OGF_HOST_CTL.
int hci_write_simple_pairing_mode | ( | int | dd, |
uint8_t | mode, | ||
int | to | ||
) |
dd | |
mode | |
to |
Definition at line 3222 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_SIMPLE_PAIRING_MODE, hci_request::ogf, OGF_HOST_CTL, hci_request::rlen, hci_request::rparam, WRITE_SIMPLE_PAIRING_MODE_CP_SIZE, and WRITE_SIMPLE_PAIRING_MODE_RP_SIZE.
int hci_write_stored_link_key | ( | int | dd, |
bdaddr_t * | bdaddr, | ||
uint8_t * | key, | ||
int | to | ||
) |
dd | |
bdaddr | |
key | |
to |
Definition at line 2642 of file hci.c.
References bacpy(), hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_STORED_LINK_KEY, hci_request::ogf, OGF_HOST_CTL, and WRITE_STORED_LINK_KEY_CP_SIZE.
int hci_write_voice_setting | ( | int | dd, |
uint16_t | vs, | ||
int | to | ||
) |
dd | |
vs | |
to |
Definition at line 2531 of file hci.c.
References hci_request::clen, hci_request::cparam, hci_send_req(), hci_request::ocf, OCF_WRITE_VOICE_SETTING, hci_request::ogf, OGF_HOST_CTL, and WRITE_VOICE_SETTING_CP_SIZE.
char* lmp_featurestostr | ( | uint8_t * | features, |
char * | pref, | ||
int | width | ||
) |
Link Manager Protocol feature string given code
features | Link Manager Protocol feature code |
pref | prefix |
width |
Definition at line 962 of file hci.c.
References bt_malloc(), hci_map::str, and hci_map::val.
int lmp_strtover | ( | char * | str, |
unsigned int * | ver | ||
) |
Link Manager Protocol code given the string
str | version string |
ver | version code |
Definition at line 832 of file hci.c.
References hci_str2uint().
char* lmp_vertostr | ( | unsigned int | ver | ) |
Link Manager Protocol version (same as hci) string given the code
ver | version code |
Definition at line 820 of file hci.c.
References hci_uint2str().
int pal_strtover | ( | char * | str, |
unsigned int * | ver | ||
) |
pal version code given string
str | pal version string |
ver | pal version code |
Definition at line 860 of file hci.c.
References hci_str2uint().
char* pal_vertostr | ( | unsigned int | ver | ) |
pal version string given code
ver | pal version code |
Definition at line 848 of file hci.c.
References hci_uint2str().