Lazy activation of A2DP or HFP
If a BT classic that supports both A2DP and HFP is connected when LE audio is active and music is playing, we should be careful on deactivating of LE audio otherwise audio could come from phone speaker. This CL fixes following audio leak from phone speaker by pending the activation of HFP and deactivation of LE audio till A2DP is available. Before the CL: 1. HFP is activated 2. LE audio is deactivated 3. Music comes from DUT (Audio leak) 4. A2DP is activated 5. Music comes from A2DP After the CL: 1. HFP is connected, but not activated if HFP is not in use 2. A2DP is connected, activated if A2DP is in use 3. HFP is activated if its activation was pending 4. LE audio is deactivated. Bug: 247453067 Tag: #refactor Test: atest BluetoothInstrumentationTests:ActiveDeviceManager Change-Id: Iee2442b3cc6aeecce4a0ec1e87f1b477c894199b
Showing
- android/app/src/com/android/bluetooth/btservice/ActiveDeviceManager.java 115 additions, 15 deletions.../com/android/bluetooth/btservice/ActiveDeviceManager.java
- android/app/tests/unit/src/com/android/bluetooth/btservice/ActiveDeviceManagerTest.java 11 additions, 1 deletion.../android/bluetooth/btservice/ActiveDeviceManagerTest.java
Loading
Please register or sign in to comment