BUG: A2DP profile does not get connected when BT headphones are turned on

asked 2019-05-14 16:54:21 +0300

saso gravatar image

I have this same problem with Sony headphones and Pioneer car stereo. When the BT device is switched on, only HFP profile is connected. A2DP does not get connected, so music does not get routed to the bluetooth device. But if I go to sailfish bluetooth settings and first disconnect and then connect the device again from there, A2DP is also connected. So I think the problem is that when connection is initiated from the other device, only HFP profile is connected, and when connection is initiated from the sailfish device, both profiles are connected.

Here is pactl list cards output after headphones are switched on:

Card #24
    Name: bluez_card.04_5D_XX_XX_XX_XX
    Driver: module-bluez5-device.c
    Owner Module: 48
    Properties:
            device.description = "MDR-ZX770BN"
            device.string = "04:5D:XX:XX:XX:XX"
            device.api = "bluez"
            device.class = "sound"
            device.bus = "bluetooth"
            device.form_factor = "headset"
            bluez.path = "/org/bluez/hci0/dev_04_5D_XX_XX_XX_XX"
            bluez.class = "0x240404"
            bluez.alias = "MDR-ZX770BN"
            device.icon_name = "audio-headset-bluetooth"
            device.intended_roles = "phone"
    Profiles:
            headset_head_unit: Headset Head Unit (HSP/HFP) (sinks: 1, sources: 1, priority: 30, available: yes)
            a2dp_sink: High Fidelity Playback (A2DP Sink) (sinks: 1, sources: 0, priority: 40, available: no)
            off: Off (sinks: 0, sources: 0, priority: 0, available: yes)
    Active Profile: off
    Ports:
            headset-output: Headset (priority: 0, latency offset: 0 usec)
                    Part of profile(s): headset_head_unit, a2dp_sink
            headset-input: Headset (priority: 0, latency offset: 0 usec)
                    Part of profile(s): headset_head_unit

And here is the output after disconnecting and connecting from sailfish:

Card #26
    Name: bluez_card.04_5D_XX_XX_XX_XX
    Driver: module-bluez5-device.c
    Owner Module: 50
    Properties:
            device.description = "MDR-ZX770BN"
            device.string = "04:5D:XX:XX:XX:XX"
            device.api = "bluez"
            device.class = "sound"
            device.bus = "bluetooth"
            device.form_factor = "headset"
            bluez.path = "/org/bluez/hci0/dev_04_5D_XX_XX_XX_XX"
            bluez.class = "0x240404"
            bluez.alias = "MDR-ZX770BN"
            device.icon_name = "audio-headset-bluetooth"
            device.intended_roles = "phone"
    Profiles:
            headset_head_unit: Headset Head Unit (HSP/HFP) (sinks: 1, sources: 1, priority: 30, available: yes)
            a2dp_sink: High Fidelity Playback (A2DP Sink) (sinks: 1, sources: 0, priority: 40, available: yes)
            off: Off (sinks: 0, sources: 0, priority: 0, available: yes)
    Active Profile: a2dp_sink
    Ports:
            headset-output: Headset (priority: 0, latency offset: 0 usec)
                    Part of profile(s): headset_head_unit, a2dp_sink
            headset-input: Headset (priority: 0, latency offset: 0 usec)
                    Part of profile(s): headset_head_unit
edit retag flag offensive close delete