From 2c4ff18695e1f324ebb9419a68082e60f6fe2cfe Mon Sep 17 00:00:00 2001 From: Jakub Tyszkowski Date: Wed, 26 Feb 2014 09:41:10 +0100 Subject: [PATCH] android/hal-gatt-api: Add Client Get Descriptor --- android/hal-ipc-api.txt | 13 +++++++++++++ android/hal-msg.h | 8 ++++++++ 2 files changed, 21 insertions(+) diff --git a/android/hal-ipc-api.txt b/android/hal-ipc-api.txt index e490bd152..a6d23dd01 100644 --- a/android/hal-ipc-api.txt +++ b/android/hal-ipc-api.txt @@ -1517,6 +1517,19 @@ Android HAL name: "gatt" (BT_PROFILE_GATT_ID) In case of an error, the error response will be returned. Opcode 0x0b - Get Descriptor command/response + + Command parameters: Connection ID (4 octets) + Service ID (18 octets) + Number of GATT ID Elements (1 octet) + GATT ID Elements (variable) + Valid Service ID: as described in Get Included Service + Valid Number of GATT ID Elements: 0x01 + 0x02 + Valid GATT ID Element: as described in Get Included Service + Response parameters: + + In case of an error, the error response will be returned. + Opcode 0x0c - Read Characteristic command/response Opcode 0x0d - Write Characteristic command/response Opcode 0x0e - Read Descriptor command/response diff --git a/android/hal-msg.h b/android/hal-msg.h index 8f0a2b957..e0cee6f05 100644 --- a/android/hal-msg.h +++ b/android/hal-msg.h @@ -592,6 +592,14 @@ struct hal_cmd_gatt_client_get_characteristic { struct hal_gatt_gatt_id gatt_id[0]; } __attribute__((packed)); +#define HAL_OP_GATT_CLIENT_GET_DESCRIPTOR 0x0b +struct hal_cmd_gatt_client_get_descriptor { + int32_t conn_id; + struct hal_gatt_srvc_id srvc_id; + uint8_t number; + struct hal_gatt_gatt_id gatt_id[0]; +} __attribute__((packed)); + /* Notifications and confirmations */ #define HAL_POWER_OFF 0x00 -- 2.47.3