Commit Graph

896 Commits

Author SHA1 Message Date
Jakub Pawlowski
7800604d0d Merge "LE Maximum Advertising Data Length (1/4)" am: 74f2e1a303 am: 2fc3834f4d
am: 066e8551f1

Change-Id: If9ee85705e7c47820e23ad79a048e4c04c4cc11a
2017-03-17 05:31:07 +00:00
Jakub Pawlowski
2fc3834f4d Merge "LE Maximum Advertising Data Length (1/4)"
am: 74f2e1a303

Change-Id: I3b6599937ddd04a9c13573d156cc721152c0005a
2017-03-17 05:19:57 +00:00
Jakub Pawlowski
ad10affa4e LE Maximum Advertising Data Length (1/4)
Add ability to check maximum advertising data length.

Bug: 30622771
Test: manual
Change-Id: I281f7e9f294c40a47a67a22809cc753b6693f7c4
2017-03-16 18:27:01 -07:00
Jakub Pawlowski
9f9597e248 Merge "Bluetooth 5 AdvertisingSet implementation (1/4)" am: 15e69df921 am: 45e0c6ea7f
am: d2da3a7874

Change-Id: I3b14feb1d470f818b48acf99b32785f653790cc2
2017-03-17 01:21:38 +00:00
Jakub Pawlowski
45e0c6ea7f Merge "Bluetooth 5 AdvertisingSet implementation (1/4)"
am: 15e69df921

Change-Id: I585fc900b4a153744116fa87764db98b038184d5
2017-03-17 01:09:02 +00:00
Jakub Pawlowski
5f00f173fb Bluetooth 5 AdvertisingSet implementation (1/4)
This patch wires up fist methods of AdvertisingSet, making it possible
to start advertising and stop advertising. It also replaces legacy
implemementation with calls to new implementation.

Bug: 30622771
Test: sl4a ConcurrentBleAdvertisingTest
Change-Id: I80a4b1b2b632d5ef8a80d958615897684cfa0c16
2017-03-16 22:17:09 +00:00
Jakub Pawlowski
58569de4de Merge "Bluetooth 5 spelling fixes"
am: 5465fe0a2d

Change-Id: Ibef8ee6a56bf1f8c695e07e4ba61c015054eee13
2017-03-13 18:11:58 +00:00
Jakub Pawlowski
bc2991e866 Bluetooth 5 spelling fixes
Bug: 30622771
Test: manual
Change-Id: I46b6486619cc7366e56b25ca48937e6792f53e1d
(cherry picked from commit 53501ad210)
2017-03-13 17:48:42 +00:00
Jakub Pawlowski
83c4712abd Merge "Bluetooth 5 spelling fixes" 2017-03-11 02:22:39 +00:00
Jakub Pawlowski
53501ad210 Bluetooth 5 spelling fixes
Bug: 30622771
Test: manual
Change-Id: I46b6486619cc7366e56b25ca48937e6792f53e1d
2017-03-11 00:30:17 +00:00
Eugene Susla
36e866b8e0 Support multiple filters per association request
By supporting multiple filters per one request we should be able to cover
multiple kinds of use cases such as:
 - Letting the user select from a list of devices of more then one medium
 type (e.g. Bluetooth and BLE)
 - Allowing to provide multiple criteria for any field (e.g. filtering by
 more than one service UUID)

Bug: 30932767
Test: Provide multiple filters and ensure that devices matching either are
shown in the list to choose from.
Ensure wifi SSIDs are shown in the list if wifi filter is provided

Change-Id: I0a978787551a1ee5750ec5544b241d3bbfed5a7c
2017-03-09 17:52:49 -08:00
Hector Tellez
d66c95fa90 Revert "Support multiple filters per association request"
This reverts commit e70e6aa62c.

Change-Id: I12857cbbea0a0c74521191ab5e3713db230626ab
2017-03-09 17:55:43 +00:00
Eugene Susla
e70e6aa62c Support multiple filters per association request
By supporting multiple filters per one request we should be able to cover
multiple kinds of use cases such as:
 - Letting the user select from a list of devices of more then one medium
 type (e.g. Bluetooth and BLE)
 - Allowing to provide multiple criteria for any field (e.g. filtering by
 more than one service UUID)

Bug: 30932767
Test: Provide multiple filters and ensure that devices matching either are
shown in the list to choose from.
Ensure wifi SSIDs are shown in the list if wifi filter is provided
Change-Id: I6621da388e2bf4ed97c5af2692629a321d0b63c7
2017-03-08 16:52:14 -08:00
Jakub Pawlowski
fc3c9d0e9e Merge "Bluetooth 5 Advertising API"
am: 1bb08c25b8

Change-Id: Ifd95aacf025929d3c9f5a1762f31ed20c26fabfd
2017-03-08 19:21:03 +00:00
Jakub Pawlowski
4f6034160c Merge "Bluetooth 5 PHY selection API"
am: 104eeedb42

Change-Id: I0ee2daaf0771b405c8a14598a70459879d31c953
2017-03-08 19:18:50 +00:00
Jakub Pawlowski
8acd7391bd Merge "Bluetooth 5 periodc scan API (1/2)"
am: f1d76a71c8

Change-Id: I7b68746e3dc02a12d13380a90bcf26cebfd31f16
2017-03-08 19:14:22 +00:00
Jakub Pawlowski
71760b71fd Merge "Bluetooth 5 enhanced scanning API"
am: bed6fb3f5a

Change-Id: I27d61ec7446c36143dcd5a94158451e1be9a5411
2017-03-08 19:12:08 +00:00
Jakub Pawlowski
e9bd9be3cb Merge "Bluetooth 5 feature check API (1/2)"
am: a06a0dfdb7

Change-Id: I59cf0e8f496e6a1201a3a6ec832c33cd1c8972df
2017-03-08 19:09:43 +00:00
Jakub Pawlowski
a9d1a32e5e Bluetooth 5 Advertising API
Test: manual
Bug: 30622771
Change-Id: Id6856e6110872ec50ff1af54ddc75c0104a6459c
(cherry picked from commit 5324a14cf4)
2017-03-08 19:04:49 +00:00
Jakub Pawlowski
409cee69b2 Bluetooth 5 PHY selection API
Bug: 30622771
Test: manual
Change-Id: I50262a56a70466439f9700549c3c0e7bd49e2e8d
(cherry picked from commit db5a87d50d)
2017-03-08 19:04:06 +00:00
Jakub Pawlowski
ac7fcfa361 Bluetooth 5 periodc scan API (1/2)
Bug: 30622771
Test: manual
Change-Id: I61853bc71f6013e9406d1d151bb51ea4484bb92c
(cherry picked from commit a48e03745b)
2017-03-08 19:03:12 +00:00
Jakub Pawlowski
3aca933861 Bluetooth 5 enhanced scanning API
Bug: 30622771
Test: manual
Change-Id: I2c8065fbcedf48777ce18c7d8fe621e568b3fd75
(cherry picked from commit 9de522c6e4)
2017-03-08 19:02:25 +00:00
Jakub Pawlowski
48091bbd78 Bluetooth 5 feature check API (1/2)
Bug: 30622771
Test: manual
Change-Id: I90e2efe989745c07c2f2fb8f4ea5bc3b718382f6
(cherry picked from commit 79d66495c3)
2017-03-08 18:20:03 +00:00
Srinivas Visvanathan
3b12f4cf02 Merge "Adding handle extra in unread-message broadcast" 2017-03-08 02:14:22 +00:00
Jakub Pawlowski
5324a14cf4 Bluetooth 5 Advertising API
Test: manual
Bug: 30622771
Change-Id: Id6856e6110872ec50ff1af54ddc75c0104a6459c
2017-03-08 01:12:16 +00:00
Jakub Pawlowski
db5a87d50d Bluetooth 5 PHY selection API
Bug: 30622771
Test: manual
Change-Id: I50262a56a70466439f9700549c3c0e7bd49e2e8d
2017-03-08 01:09:04 +00:00
Jakub Pawlowski
a48e03745b Bluetooth 5 periodc scan API (1/2)
Bug: 30622771
Test: manual
Change-Id: I61853bc71f6013e9406d1d151bb51ea4484bb92c
2017-03-08 01:06:25 +00:00
Jakub Pawlowski
9de522c6e4 Bluetooth 5 enhanced scanning API
Bug: 30622771
Test: manual
Change-Id: I2c8065fbcedf48777ce18c7d8fe621e568b3fd75
2017-03-08 01:05:13 +00:00
Jakub Pawlowski
2844a30f6c Merge "Bluetooth 5 feature check API (1/2)" 2017-03-08 01:02:15 +00:00
Hemant Gupta
87d48cdeae Merge "Bluetooth: Expose L2CAP API to support OPP 1.2" am: 79eb213a98 am: 12358b4057
am: 31428b1e6d

Change-Id: Ic2ff9eb34ebc8aada030f5e3e8d040c29f9b7186
2017-03-08 00:48:54 +00:00
Hemant Gupta
12358b4057 Merge "Bluetooth: Expose L2CAP API to support OPP 1.2"
am: 79eb213a98

Change-Id: I5f82a0c40c64fca0701abba44693b2892209acf3
2017-03-08 00:38:14 +00:00
Jakub Pawlowski
79d66495c3 Bluetooth 5 feature check API (1/2)
Bug: 30622771
Test: manual
Change-Id: I90e2efe989745c07c2f2fb8f4ea5bc3b718382f6
2017-03-07 23:57:58 +00:00
Srinivas Visvanathan
86a8c1cabb Adding handle extra in unread-message broadcast
- Handle will be useful for messaging apps.

Bug: 33280056
Test: Manually
Change-Id: Id4b1bf2d90d9eaea1504cc270a922a1d6f1c468b
2017-03-07 10:22:53 -08:00
Hemant Gupta
ef3e0dbf00 Bluetooth: Expose L2CAP API to support OPP 1.2
Add changes to expose L2CAP API to create an insecure L2CAP socket
for supporting OPP 1.2.

Test: Connect with Remote OPP Client supporting OPP 1.2 and verify
that connection and transfer happens over L2CAP. Connect with Remote
OPP Client supporting OPP 1.1 and verify that connection and transfer
happens over RFCOMM.

Bug: 33010988
Change-Id: I21ed672afb4ed5d2355ff0a0f9691af220921c1f
2017-03-07 02:30:52 +00:00
Srinivas Visvanathan
ad90338d2b Defining extras for New Unread-Message Broadcast
- Defining extras for sender fields in the Broadcast intent.

Bug: 33280056
Test: Manually
Change-Id: Ie77bee498141c079f6f2ec811e527230c95e8831
2017-03-03 09:57:18 -08:00
Pavlin Radoslavov
489ce07b81 Merge "Add a mechanism to configure the default A2DP codec priorities" am: acf34d8b62 am: cd6e0ee19d am: b7067e2b6c
am: 537eaf0f6e

Change-Id: I42186a561d59decb0d811b3f5b8d5bf96df53152
2017-02-07 14:05:43 +00:00
Pavlin Radoslavov
b7067e2b6c Merge "Add a mechanism to configure the default A2DP codec priorities" am: acf34d8b62
am: cd6e0ee19d

Change-Id: I6fb8a3a35451cf2d1e228466ef4a4d4e89d1d4ca
2017-02-07 00:10:21 +00:00
Pavlin Radoslavov
2199339c39 Add a mechanism to configure the default A2DP codec priorities
Previously, the relative codec priorities were hard-codec internally.
The new mechanism uses the following configurable resources in
packages/apps/Bluetooth/res/values/config.xml to re-assign the
default codec priorities per device, or to explicitly disable a codec.

 - a2dp_source_codec_priority_sbc
 - a2dp_source_codec_priority_aac
 - a2dp_source_codec_priority_aptx
 - a2dp_source_codec_priority_aptx_hd
 - a2dp_source_codec_priority_ldac

Those values are assigned on startup.
Also, they can be changed per device by using an overlay:
device/<VENDOR>/<DEVICE>/overlay/packages/apps/Bluetooth/res/values/config.xml

Test: Manually streaming to a headset
Change-Id: Ic4da3a51ac73f00cbae731156cb7878c8fadee06
2017-02-06 13:07:23 -08:00
Eugene Susla
6ed45d8cd3 CompanionDeviceManager
This introduces an API for apps that support companion devices to provide a
more streamlined flow for pairing and setting up the device

Bug: 30932767
Test: Using a toy app, invoke the newly introduced API (CompanionDeviceManager),
 and go through the flow. Ensure filtering works, and device is returned to
 the calling app. Ensure the calling app can pair to the selected device.
Change-Id: I0aeb653afd65e4adead13ea9c7248ec20971b04a
2017-02-06 12:50:55 -08:00
Pavlin Radoslavov
45250aca6d Merge "Update the A2DP Codec Config API" am: ccd60f7cbe am: f0096fb868 am: 91707989c4
am: 1ef3c9888e

Change-Id: If69bfe9839a35dc141d741695a217fa4805d46cc
2017-01-31 19:25:11 +00:00
Pavlin Radoslavov
91707989c4 Merge "Update the A2DP Codec Config API" am: ccd60f7cbe
am: f0096fb868

Change-Id: Ibc7d4b500adc4451978f366557b93dc6b6d3da63
2017-01-31 19:13:05 +00:00
Pavlin Radoslavov
b37f181c98 Update the A2DP Codec Config API
Previously, the JNI upcall would contain only the current codec config.
In the new API, the upcall contains:
 1. The current codec config
 2. The list of codecs containing the local codecs capabilities
 3. The list of codecs containing the selectable codecs capabilities.
    This list is the intersection of the local codecs capabilities
    and the capabilities of the paired device.

Also, refactored the Java internals to accomodate the extra information:
 * Added new class BluetoothCodecStatus that contains the extra info:
   current codec config, local codecs capabilities and selectable
   codecs capabilities
 * Renamed method getCodecConfig() to getCodecStatus() and return the
   corresponding BluetoothCodecStatus object.
 * Updates to class BluetoothCodecConfig:
   new methods isValid(), getCodecName(), and updated toString()
   so it is more user friendly
 * Removed BluetoothCodecConfig.EXTRA_CODEC_CONFIG and
   EXTRA_PREVIOUS_CODEC_CONFIG.
   The former is superseded by BluetoothCodecStatus.EXTRA_CODEC_STATUS;
   the latter is not really used.

Test: A2DP streaming with headsets and switching the codecs
Change-Id: Ia1af2c22e521e863e28a360610aca49f7e62d31b
2017-01-31 18:58:27 +00:00
Marie Janssen
2db3f99cfe Merge "Bluetooth: add getDiscoveryEndMillis() call" am: 1785fc4eea am: 7f8d8638eb am: ca312c1cd3
am: 9eb3d7e335

Change-Id: I45a29862c9a841b68bee41daff1d8e46145cbd79
2017-01-30 19:11:46 +00:00
Marie Janssen
ca312c1cd3 Merge "Bluetooth: add getDiscoveryEndMillis() call" am: 1785fc4eea
am: 7f8d8638eb

Change-Id: I6f02c4ddc0fe56cda5af2dcf2f5193ba13522792
2017-01-30 17:57:02 +00:00
Marie Janssen
23a4833157 Bluetooth: add getDiscoveryEndMillis() call
Method to tell when the adapter finished (or will finish) being in
discovery mode.

Test: compiles and still can scan
Bug: 34395439
Change-Id: I41b48c2b934c0a1d5e1727cec08f3f762e3cb309
2017-01-27 18:48:11 -08:00
Pavlin Radoslavov
02e806550c Merge "Integration of the AAC codec for A2DP source" am: 22f97c83fb am: f23e80bb9b am: d364208388
am: 78798cc13d

Change-Id: Ic645f9ee2eb090fc805a25a1449642dad021db4e
2017-01-26 19:42:16 +00:00
Pavlin Radoslavov
d364208388 Merge "Integration of the AAC codec for A2DP source" am: 22f97c83fb
am: f23e80bb9b

Change-Id: If2d85eba17f7ece5b3d19e3ee8fc86b7cf9bc062
2017-01-26 19:25:37 +00:00
Pavlin Radoslavov
b33bd5bc2e Integration of the AAC codec for A2DP source
Test: A2DP streaming to AAC headsets
Bug: 30958229
Change-Id: I1b530f1c5c495b8231fd68bed788d4567096683d
2017-01-26 09:06:02 -08:00
Sanket Agarwal
c8399321e9 Change HFP Client API to support multi device
- Adds BluetoothDevice as a parameter where required
- Gets rid of device management APIs that can be done via
  BluetoothProfiles instead

Test: Manual sanity tests
Bug: b/33554547
Bug: b/30984220
Change-Id: I3485ac5bfe1fcb29c774ad040fdd608e1cacb8df
(cherry picked from commit 039eeb81b5)
2017-01-23 22:53:58 +00:00
Sanket Agarwal
a3ae5c4e24 Change HFP Client API to support multi device
- Adds BluetoothDevice as a parameter where required
- Gets rid of device management APIs that can be done via
  BluetoothProfiles instead

Test: Manual sanity tests
Bug: b/33554547
Bug: b/30984220
Change-Id: I3485ac5bfe1fcb29c774ad040fdd608e1cacb8df
(cherry picked from commit 039eeb81b5)
2017-01-20 19:30:35 -08:00