GAP_ConnOpen() function
* Function GAP_ConnOpen * Description This function is called to open an L2CAP connection. * Parameters: is_server - If TRUE, the connection is not created * but put into a "listen" mode waiting for * the remote side to connect. * service_id - Unique service ID from * BTM_SEC_SERVICE_FIRST_EMPTY (6) * to BTM_SEC_MAX_SERVICE_RECORDS (32) * p_rem_bda - Pointer to remote BD Address. * If a server, and we don't care about the * remote BD Address, then NULL should be passed. * psm - the PSM used for the connection * p_config - Optional pointer to configuration structure. * If NULL, the default GAP configuration will * be used. * security - security flags * chan_mode_mask - (GAP_FCR_CHAN_OPT_BASIC, GAP_FCR_CHAN_OPT_ERTM, * GAP_FCR_CHAN_OPT_STREAM) * p_cb - Pointer to callback function for events. * Returns handle of the connection if successful, else GAP_INVALID_HANDLE
![]()
UINT16 GAP_ConnOpen (const char *p_serv_name, UINT8 service_id, BOOLEAN is_server,![]()
if ((handle = GAP_ConnOpen("", sec_id, 0, cc->peer_bd_addr, cc->remote_psm,![]()
(handle = GAP_ConnOpen("JV L2CAP", sec_id, 1, 0, ls->local_psm, &cfg, ertm_info,
GAP_ConnOpen() is called by 2 functions and calls 7 functions:
![]()
GAP_ConnOpen()
GAP_ConnOpen() reads 19 variables and writes 16 variables:
![]()
GAP_ConnOpen()