BLE characteristics UUID
Posted: Mon Apr 10, 2017 11:50 am
How can I know the UUID of the characteristic when ESP_GATTS_READ_EVT occurs in GATTS SERVER operation?
plz..help..
Code: Select all
case ESP_GATTS_READ_EVT:
ESP_LOGI(DEBUG_TAG, "GATT_READ_EVT, conn_id %d, trans_id %d, handle %d\n", param->read.conn_id, param->read.trans_id, param->read.handle);
esp_gatt_rsp_t rsp;
memset(&rsp, 0, sizeof(esp_gatt_rsp_t));
rsp.attr_value.len = 4;
rsp.attr_value.value[0] = 0xde;
rsp.attr_value.value[1] = 0xed;
rsp.attr_value.value[2] = 0xbe;
rsp.attr_value.value[3] = 0xef;
esp_ble_gatts_send_response(gatts_if, param->read.conn_id, param->read.trans_id,
ESP_GATT_OK, &rsp);
break;