Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(45)

Issue 2501983002: Adds basic Bluetooth support to AppRTCMobile (Closed)

Created:
4 years, 1 month ago by henrika_webrtc
Modified:
4 years ago
Reviewers:
magjed_webrtc
CC:
webrtc-reviews_webrtc.org
Target Ref:
refs/pending/heads/master
Project:
webrtc
Visibility:
Public.

Description

Adds basic Bluetooth support to AppRTCMobile BUG=webrtc:6649 - Supports Bluetooth Headset profile. - Detects new BT headset: + enabled at start, and + powered on during active call. - Enables/disables BT SCO channel when BT device is selected. - Removes proximity sensor usage to avoid conflicts (will be added again later). - Adds new (unused) APIs to explicitly select audio device. - Starts routing audio to BT headset when enabled, i.e, BT is default. Committed: https://crrev.com/c3c2f318521270ac42e3721d707259a29288e98c Cr-Commit-Position: refs/heads/master@{#15610}

Patch Set 1 #

Patch Set 2 : Modified the device selection code #

Patch Set 3 : Added user selection #

Patch Set 4 : nit #

Patch Set 5 : BluetoothHeadset.ACTION_CONNECTION_STATE_CHANGED #

Patch Set 6 : First working version #

Patch Set 7 : Improved comments #

Patch Set 8 : Removed proximity sensor #

Total comments: 7

Patch Set 9 : First working version with new AppRTCBluetoothManager.java (no timer) #

Patch Set 10 : Cleaned up AppRTCBluetoothManager.java #

Total comments: 10

Patch Set 11 : Simplifies diff and adds base for unit test #

Patch Set 12 : Added more tests #

Patch Set 13 : Finalized the test suite. Now contains seven tests #

Total comments: 26

Patch Set 14 : Final comments from magjed@ #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1103 lines, -141 lines) Patch
M webrtc/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M webrtc/examples/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -0 lines 0 comments Download
M webrtc/examples/androidapp/AndroidManifest.xml View 1 chunk +1 line, -0 lines 0 comments Download
M webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 9 chunks +287 lines, -128 lines 0 comments Download
A webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCBluetoothManager.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +521 lines, -0 lines 0 comments Download
M webrtc/examples/androidapp/src/org/appspot/apprtc/CallActivity.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 4 chunks +21 lines, -13 lines 0 comments Download
A webrtc/examples/androidjunit/src/org/appspot/apprtc/BluetoothManagerTest.java View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +271 lines, -0 lines 0 comments Download

Messages

Total messages: 34 (16 generated)
henrika_webrtc
PTAL
4 years ago (2016-11-23 10:03:04 UTC) #4
magjed_webrtc
AppRTCAudioManager has too much stuff in it now. Add the Bluetooth logic to a new ...
4 years ago (2016-11-28 12:59:46 UTC) #6
henrika_webrtc
Thanks, given the scope of proposed changes, would it be OK if I try to ...
4 years ago (2016-11-28 14:06:08 UTC) #7
henrika_webrtc
https://codereview.webrtc.org/2501983002/diff/140001/webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java File webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java (right): https://codereview.webrtc.org/2501983002/diff/140001/webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java#newcode37 webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java:37: // AppRTCAudioManager manages all audio related parts of the ...
4 years ago (2016-11-28 14:06:19 UTC) #8
magjed_webrtc
On 2016/11/28 14:06:08, henrika_webrtc wrote: > Thanks, > > given the scope of proposed changes, ...
4 years ago (2016-11-29 19:59:52 UTC) #9
henrika_webrtc
Thanks, working on the new class now. Let me upload it when done and see ...
4 years ago (2016-11-30 08:30:10 UTC) #10
henrika_webrtc
Main BT functionality is now broken out in a separate class. Hope it is OK ...
4 years ago (2016-12-02 13:08:03 UTC) #11
henrika_webrtc
PTAL
4 years ago (2016-12-02 13:08:13 UTC) #12
magjed_webrtc
https://codereview.webrtc.org/2501983002/diff/180001/webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java File webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java (left): https://codereview.webrtc.org/2501983002/diff/180001/webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java#oldcode62 webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java:62: // Proximity sensor object. It measures the proximity of ...
4 years ago (2016-12-07 11:09:43 UTC) #13
henrika_webrtc
Thanks! Did my best to simplify the diff. Also added first version of unit test. ...
4 years ago (2016-12-07 12:55:42 UTC) #14
henrika_webrtc
PTAL (exclude unit test for now)
4 years ago (2016-12-07 12:56:54 UTC) #15
henrika_webrtc
Finalized the tests. Now contains seven tests in total. Hope you like them ;-) PTAL
4 years ago (2016-12-08 11:50:35 UTC) #18
magjed_webrtc
This looks good overall, especially the new AppRTCBluetoothManager.java and BluetoothManagerTest.java. My comments are mainly nits, ...
4 years ago (2016-12-10 19:34:45 UTC) #21
henrika_webrtc
Many thanks Magnus. Should be perfect now ;-) PTAL https://codereview.webrtc.org/2501983002/diff/240001/webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java File webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java (right): https://codereview.webrtc.org/2501983002/diff/240001/webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java#newcode81 webrtc/examples/androidapp/src/org/appspot/apprtc/AppRTCAudioManager.java:81: ...
4 years ago (2016-12-12 14:13:25 UTC) #22
magjed_webrtc
lgtm
4 years ago (2016-12-14 10:35:45 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.webrtc.org/2501983002/260001
4 years ago (2016-12-14 15:00:34 UTC) #29
commit-bot: I haz the power
Committed patchset #14 (id:260001)
4 years ago (2016-12-14 15:37:00 UTC) #32
commit-bot: I haz the power
4 years ago (2016-12-14 15:37:07 UTC) #34
Message was sent while issue was closed.
Patchset 14 (id:??) landed as
https://crrev.com/c3c2f318521270ac42e3721d707259a29288e98c
Cr-Commit-Position: refs/heads/master@{#15610}

Powered by Google App Engine
This is Rietveld 408576698