phhusson / treble_experimentations

Notes about tinkering with Android Project Treble
3.41k stars 660 forks source link

Cubot Pocket: USB Audio (UAC) misses output device #2504

Open ari-s opened 1 year ago

ari-s commented 1 year ago

Current Behavior:

When I attach a USB audio device (UAC) to my cubot pocket, it doesn't play media over it. There's no output device added in media.audio_policy. The device also has media control buttons via an HID function: those work. An input device is added: that presumably works as well.

The UAC device works on another Android phone (some Asus Zenphone with vendor ROM) as well as on a linux laptop, so I don't think it's the device. I've also tried two other UAC devices, those don't work either (but I haven't double-checked those with the other phone + laptop)

Describe the bug

somehow the device's audio configuration does not change appropriately.

dumpsys media.audio_policy with UAC connected dumpsys media.audio_policy with nothing connected

To Reproduce

  1. Cubot Pocket with GSI
  2. plug a UAC device and play some audio
  3. output is still from the internal speaker

Expected behavior

Audio plays via UAC device, probably also a second audio device becomes visible in the volume settings.

Smartphone (please complete the following information):