Skip to content
Snippets Groups Projects
Commit f1fb822c authored by Sungsoo Lim's avatar Sungsoo Lim
Browse files

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
parent 6d42d9c5
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment