HIDD: Add support for HID Device Role
This patch adds support for HID Device role in bluedroid stack allowing
DUT to be used as Keyboard or Mouse.
Bug: 33011576
Change-Id: I45b581a54f6c7bbc1f25226715a7ea23e34255c0
diff --git a/bta/include/bta_api.h b/bta/include/bta_api.h
index c9c81ed..5de85ae 100644
--- a/bta/include/bta_api.h
+++ b/bta/include/bta_api.h
@@ -85,13 +85,14 @@
#define BTA_MAP_SERVICE_ID 25 /* Message Access Profile */
#define BTA_MN_SERVICE_ID 26 /* Message Notification Service */
#define BTA_HDP_SERVICE_ID 27 /* Health Device Profile */
-#define BTA_PCE_SERVICE_ID 28 /* PhoneBook Access Client*/
-#define BTA_SDP_SERVICE_ID 29 /* SDP Search*/
+#define BTA_PCE_SERVICE_ID 28 /* PhoneBook Access Client */
+#define BTA_SDP_SERVICE_ID 29 /* SDP Search */
+#define BTA_HIDD_SERVICE_ID 30 /* HID Device */
/* BLE profile service ID */
-#define BTA_BLE_SERVICE_ID 30 /* GATT profile */
-#define BTA_USER_SERVICE_ID 31 /* User requested UUID */
-#define BTA_MAX_SERVICE_ID 32
+#define BTA_BLE_SERVICE_ID 31 /* GATT profile */
+#define BTA_USER_SERVICE_ID 32 /* User requested UUID */
+#define BTA_MAX_SERVICE_ID 33
/* service IDs (BTM_SEC_SERVICE_FIRST_EMPTY + 1) to (BTM_SEC_MAX_SERVICES - 1)
* are used by BTA JV */
@@ -130,10 +131,11 @@
#define BTA_MN_SERVICE_MASK 0x04000000 /* Message Notification Profile */
#define BTA_HL_SERVICE_MASK 0x08000000 /* Health Device Profile */
#define BTA_PCE_SERVICE_MASK 0x10000000 /* Phone Book Client */
+#define BTA_HIDD_SERVICE_MASK 0x20000000 /* HID Device */
-#define BTA_BLE_SERVICE_MASK 0x20000000 /* GATT based service */
-#define BTA_ALL_SERVICE_MASK 0x3FFFFFFF /* All services supported by BTA. */
-#define BTA_USER_SERVICE_MASK 0x40000000 /* Message Notification Profile */
+#define BTA_BLE_SERVICE_MASK 0x40000000 /* GATT based service */
+#define BTA_ALL_SERVICE_MASK 0x7FFFFFFF /* All services supported by BTA. */
+#define BTA_USER_SERVICE_MASK 0x80000000 /* Message Notification Profile */
typedef uint32_t tBTA_SERVICE_MASK;
@@ -1083,8 +1085,8 @@
#endif
#ifndef BTA_DM_PM_SNIFF2_MAX
-#define BTA_DM_PM_SNIFF2_MAX 180
-#define BTA_DM_PM_SNIFF2_MIN 150
+#define BTA_DM_PM_SNIFF2_MAX 54
+#define BTA_DM_PM_SNIFF2_MIN 30
#define BTA_DM_PM_SNIFF2_ATTEMPT 4
#define BTA_DM_PM_SNIFF2_TIMEOUT 1
#endif