Home | History | Annotate | Download | only in gatt

Lines Matching full:p_data

54                                   tGATT_CL_COMPLETE *p_data);
57 tGATT_CL_COMPLETE *p_data);
185 void bta_gattc_register(tBTA_GATTC_CB *p_cb, tBTA_GATTC_DATA *p_data)
189 tBT_UUID *p_app_uuid = &p_data->api_reg.app_uuid;
214 p_cb->cl_rcb[i].p_cback = p_data->api_reg.p_cback;
233 if (p_data->api_reg.p_cback)
239 (*p_data->api_reg.p_cback)(BTA_GATTC_REG_EVT, (tBTA_GATTC *)&cb_data);
450 void bta_gattc_cancel_open_error(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
453 UNUSED(p_data);
470 void bta_gattc_open_error(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
472 UNUSED(p_data);
492 void bta_gattc_open_fail(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
494 UNUSED(p_data);
515 void bta_gattc_open(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
520 if (!GATT_Connect(p_clcb->p_rcb->client_if, p_data->api_conn.remote_bda,
521 true, p_data->api_conn.transport, false))
525 bta_gattc_sm_execute(p_clcb, BTA_GATTC_INT_OPEN_FAIL_EVT, p_data);
531 p_data->api_conn.remote_bda,
533 p_data->api_conn.transport))
551 void bta_gattc_init_bk_conn(tBTA_GATTC_API_OPEN *p_data, tBTA_GATTC_RCB *p_clreg)
558 if (bta_gattc_mark_bg_conn(p_data->client_if, p_data->remote_bda, TRUE, FALSE))
561 if (!GATT_Connect(p_data->client_if, p_data->remote_bda, false, p_data->transport, false))
563 uint8_t *bda = (uint8_t *)p_data->remote_bda;
574 if (GATT_GetConnIdIfConnected(p_data->client_if,
575 p_data->remote_bda,
577 p_data->transport))
579 if ((p_clcb = bta_gattc_find_alloc_clcb(p_data->client_if, p_data->remote_bda,
595 bta_gattc_send_open_cback(p_clreg, status, p_data->remote_bda,
608 void bta_gattc_cancel_bk_conn(tBTA_GATTC_API_CANCEL_OPEN *p_data)
615 if (bta_gattc_mark_bg_conn(p_data->client_if, p_data->remote_bda, FALSE, FALSE))
617 if (GATT_CancelConnect(p_data->client_if, p_data->remote_bda, FALSE))
626 p_clreg = bta_gattc_cl_get_regcb(p_data->client_if);
643 void bta_gattc_cancel_open_ok(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
646 UNUSED(p_data);
665 void bta_gattc_cancel_open(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
669 if (GATT_CancelConnect(p_clcb->p_rcb->client_if, p_data->api_cancel_conn.remote_bda, TRUE))
671 bta_gattc_sm_execute(p_clcb, BTA_GATTC_INT_CANCEL_OPEN_OK_EVT, p_data);
691 void bta_gattc_conn(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
696 if (p_data != NULL)
698 APPL_TRACE_DEBUG("bta_gattc_conn conn_id=%d",p_data->hdr.layer_specific);
699 p_clcb->bta_conn_id = p_data->int_conn.hdr.layer_specific;
701 GATT_GetConnectionInfor(p_data->hdr.layer_specific,
763 void bta_gattc_close_fail(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
771 cb_data.close.conn_id = p_data->hdr.layer_specific;
788 void bta_gattc_close(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
807 if (p_data->hdr.event == BTA_GATTC_API_CLOSE_EVT)
809 cb_data.close.status = GATT_Disconnect(p_data->hdr.layer_specific);
811 else if (p_data->hdr.event == BTA_GATTC_INT_DISCONN_EVT)
813 cb_data.close.status = p_data->int_conn.reason;
814 cb_data.close.reason = p_data->int_conn.reason;
857 void bta_gattc_disc_close(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
874 bta_gattc_close(p_clcb, p_data);
915 void bta_gattc_restart_discover(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
917 UNUSED(p_data);
932 void bta_gattc_cfg_mtu(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
936 if (bta_gattc_enqueue(p_clcb, p_data))
938 status = GATTC_ConfigureMTU (p_clcb->bta_conn_id, p_data->api_mtu.mtu);
944 if (p_clcb->p_q_cmd == p_data)
960 void bta_gattc_start_discover(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
962 UNUSED(p_data);
1024 void bta_gattc_disc_cmpl(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1027 UNUSED(p_data);
1084 void bta_gattc_read(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1086 if (!bta_gattc_enqueue(p_clcb, p_data))
1091 read_param.by_handle.handle = p_data->api_read.handle;
1092 read_param.by_handle.auth_req = p_data->api_read.auth_req;
1100 if (p_clcb->p_q_cmd == p_data)
1114 void bta_gattc_read_multi(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1119 if (bta_gattc_enqueue(p_clcb, p_data))
1125 read_param.read_multiple.num_handles = p_data->api_read_multi.num_attr;
1126 read_param.read_multiple.auth_req = p_data->api_read_multi.auth_req;
1127 memcpy(&read_param.read_multiple.handles, p_data->api_read_multi.handles,
1128 sizeof(UINT16) * p_data->api_read_multi.num_attr);
1137 if (p_clcb->p_q_cmd == p_data)
1153 void bta_gattc_write(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1155 if (!bta_gattc_enqueue(p_clcb, p_data))
1162 attr.handle = p_data->api_write.handle;
1163 attr.offset = p_data->api_write.offset;
1164 attr.len = p_data->api_write.len;
1165 attr.auth_req = p_data->api_write.auth_req;
1167 if (p_data->api_write.p_value)
1168 memcpy(attr.value, p_data->api_write.p_value, p_data->api_write.len);
1170 status = GATTC_Write(p_clcb->bta_conn_id, p_data->api_write.write_type, &attr);
1176 if (p_clcb->p_q_cmd == p_data)
1190 void bta_gattc_execute(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1194 if (bta_gattc_enqueue(p_clcb, p_data))
1196 status = GATTC_ExecuteWrite(p_clcb->bta_conn_id, p_data->api_exec.is_execute);
1201 if (p_clcb->p_q_cmd == p_data)
1217 void bta_gattc_confirm(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1219 UINT16 handle = p_data->api_confirm.handle;
1221 if (GATTC_SendHandleValueConfirm(p_data->api_confirm.hdr.layer_specific, handle)
1241 void bta_gattc_read_cmpl(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_OP_CMPL *p_data)
1250 cb_data.read.status = p_data->status;
1252 if (p_data->p_cmpl != NULL && p_data->status == BTA_GATT_OK)
1254 cb_data.read.handle = p_data->p_cmpl->att_value.handle;
1256 read_value.len = p_data->p_cmpl->att_value.len;
1257 read_value.p_value = p_data->p_cmpl->att_value.value;
1280 void bta_gattc_write_cmpl(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_OP_CMPL *p_data)
1287 cb_data.write.status = p_data->status;
1288 cb_data.write.handle = p_data->p_cmpl->att_value.handle;
1313 void bta_gattc_exec_cmpl(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_OP_CMPL *p_data)
1322 cb_data.exec_cmpl.status = p_data->status;
1337 void bta_gattc_cfg_mtu_cmpl(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_OP_CMPL *p_data)
1343 if (p_data->p_cmpl && p_data->status == BTA_GATT_OK)
1344 p_clcb->p_srcb->mtu = p_data->p_cmpl->mtu;
1347 p_clcb->status = p_data->status;
1349 cb_data.cfg_mtu.status = p_data->status;
1364 void bta_gattc_op_cmpl(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1366 UINT8 op = (UINT8)p_data->op_cmpl.op_code;
1402 p_data->op_cmpl.status = GATT_ERROR;
1407 bta_gattc_read_cmpl(p_clcb, &p_data->op_cmpl);
1410 bta_gattc_write_cmpl(p_clcb, &p_data->op_cmpl);
1413 bta_gattc_exec_cmpl(p_clcb, &p_data->op_cmpl);
1416 bta_gattc_cfg_mtu_cmpl(p_clcb, &p_data->op_cmpl);
1434 void bta_gattc_ignore_op_cmpl(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1440 APPL_TRACE_DEBUG("bta_gattc_ignore_op_cmpl op = %d", p_data->hdr.layer_specific);
1452 void bta_gattc_search(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1461 bta_gattc_search_service(p_clcb, p_data->api_search.p_srvc_uuid);
1479 void bta_gattc_q_cmd(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1481 bta_gattc_enqueue(p_clcb, p_data);
1493 void bta_gattc_fail(tBTA_GATTC_CLCB *p_clcb, tBTA_GATTC_DATA *p_data)
1495 UNUSED(p_data);
1754 tGATT_CL_COMPLETE *p_data,
1758 p_data->att_value.handle=%d p_data->handle=%d",
1759 p_data->att_value.handle, p_data->handle);
1763 p_notify->len = p_data->att_value.len;
1765 memcpy(p_notify->value, p_data->att_value.value, p_data->att_value.len);
1781 void bta_gattc_process_indicate(UINT16 conn_id, tGATTC_OPTYPE op, tGATT_CL_COMPLETE *p_data)
1783 UINT16 handle = p_data->att_value.handle;
1820 if (!bta_gattc_process_srvc_chg_ind(conn_id, p_clrcb, p_srcb, p_clcb, &notify, &p_data->att_value))
1842 bta_gattc_proc_other_indication(p_clcb, op, p_data, &notify);
1862 tGATT_CL_COMPLETE *p_data)
1871 bta_gattc_process_indicate(conn_id, op, p_data);
1888 bta_gattc_cmpl_sendmsg(conn_id, op, status, p_data);
1902 tGATT_CL_COMPLETE *p_data)
1912 if (p_data != NULL) {
1914 memcpy(p_buf->p_cmpl, p_data, sizeof(tGATT_CL_COMPLETE));