diff options
author | Matthew Xie <mattx@google.com> | 2014-05-07 05:47:38 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2014-05-07 05:47:38 +0000 |
commit | b8fd4eedcaa052126de22c070c6640f9a084c659 (patch) | |
tree | 91cc41f920cd0a9c92cabd815f901741ca484d23 /include | |
parent | 2f8787b8bc89d594384e0ebc8e76281e955d020f (diff) | |
parent | f9f4d10c4a742e58a465279a116ee0266578c0bc (diff) | |
download | hardware_libhardware-b8fd4eedcaa052126de22c070c6640f9a084c659.zip hardware_libhardware-b8fd4eedcaa052126de22c070c6640f9a084c659.tar.gz hardware_libhardware-b8fd4eedcaa052126de22c070c6640f9a084c659.tar.bz2 |
Merge "Add transport param to Connect APIs"
Diffstat (limited to 'include')
-rw-r--r-- | include/hardware/bt_gatt_client.h | 3 | ||||
-rw-r--r-- | include/hardware/bt_gatt_server.h | 4 | ||||
-rw-r--r-- | include/hardware/bt_gatt_types.h | 8 |
3 files changed, 13 insertions, 2 deletions
diff --git a/include/hardware/bt_gatt_client.h b/include/hardware/bt_gatt_client.h index 11b146d..f709e2c 100644 --- a/include/hardware/bt_gatt_client.h +++ b/include/hardware/bt_gatt_client.h @@ -195,7 +195,7 @@ typedef struct { /** Create a connection to a remote LE or dual-mode device */ bt_status_t (*connect)( int client_if, const bt_bdaddr_t *bd_addr, - bool is_direct ); + bool is_direct, int transport ); /** Disconnect a remote device or cancel a pending connection */ bt_status_t (*disconnect)( int client_if, const bt_bdaddr_t *bd_addr, @@ -291,6 +291,7 @@ typedef struct { /** Test mode interface */ bt_status_t (*test_command)( int command, btgatt_test_params_t* params); + } btgatt_client_interface_t; __END_DECLS diff --git a/include/hardware/bt_gatt_server.h b/include/hardware/bt_gatt_server.h index 1a5a400..32f8ef6 100644 --- a/include/hardware/bt_gatt_server.h +++ b/include/hardware/bt_gatt_server.h @@ -129,7 +129,8 @@ typedef struct { bt_status_t (*unregister_server)(int server_if ); /** Create a connection to a remote peripheral */ - bt_status_t (*connect)(int server_if, const bt_bdaddr_t *bd_addr, bool is_direct ); + bt_status_t (*connect)(int server_if, const bt_bdaddr_t *bd_addr, + bool is_direct, int transport); /** Disconnect an established connection or cancel a pending one */ bt_status_t (*disconnect)(int server_if, const bt_bdaddr_t *bd_addr, @@ -168,6 +169,7 @@ typedef struct { /** Send a response to a read/write operation */ bt_status_t (*send_response)(int conn_id, int trans_id, int status, btgatt_response_t *response); + } btgatt_server_interface_t; __END_DECLS diff --git a/include/hardware/bt_gatt_types.h b/include/hardware/bt_gatt_types.h index 0ac217e..e037ddc 100644 --- a/include/hardware/bt_gatt_types.h +++ b/include/hardware/bt_gatt_types.h @@ -43,6 +43,14 @@ typedef struct uint8_t is_primary; } btgatt_srvc_id_t; +/** Preferred physical Transport for GATT connection */ +typedef enum +{ + GATT_TRANSPORT_AUTO, + GATT_TRANSPORT_BREDR, + GATT_TRANSPORT_LE +} btgatt_transport_t; + __END_DECLS #endif /* ANDROID_INCLUDE_BT_GATT_TYPES_H */ |