Resolve call audio refactoring issues.
As part of the new call audio refactor changes that were introduced,
this CL resolves the issues that were found during testing as well as
other known issues that were originally found in the legacy code.
In the new code path, BT SCO was leveraging setCommunicationDevice but
this currently isn't available so explicit connection has to be
established as is done in the legacy path. There were also problems with
switching between LE/HFP devices which is being addressed in this CL. It
also takes care of ignoring auto routing to wearable devices as well as
ensuring that audio routing to HA devices is working as intended.
Bug: 328287261
Test: Manual testing with single case scenario of
connecting/disconnecting HFP/LE/HA devices as well as testing switching
between LE/HFP devices. Testing was also done to ensure auto-routing to
wearable devices is ignored unless explicitly requested by the user.
Test: atest CallAudioRouteControllerTest
Change-Id: I989b2d018512e73b11a597a1d688faf88a8433c2
10 files changed