Bluetooth headset doesn't work properly

Hi!

I want my headset to work with mic and good audio quality, but can’t figure out how to do it, since I’m a newbie to Linux.
I’m currently on Kernel: 5.10.60-1-MANJARO and using Sony MDR-XB950N1 headset with TP-Link UB400 BT adapter.

So I found out that PulseAudio doesn’t support bi-directional sound, so I installed PipeWire instead.

I tried enabling mSBC codec in /usr/share/pipewire/mediasession.d/bluez-monitor.conf. It appeared in pavucontrol, but when I’m trying to turn it on, mic works fine but there is no sound at all.

The headset works fine on Win10, I don’t understand why it doesn’t work on Linux. So I will be immensely grateful if you help me)

pactl list sinks

	State: IDLE
	Name: alsa_output.pci-0000_00_1b.0.analog-stereo
	Description: Built-in Audio Analog Stereo
	Driver: PipeWire
	Sample Specification: s32le 2ch 48000Hz
	Channel Map: front-left,front-right
	Owner Module: 4294967295
	Mute: no
	Volume: front-left: 29490 /  45% / -20.81 dB,   front-right: 29490 /  45% / -20.81 dB
	        balance 0.00
	Base Volume: 63069 /  96% / -1.00 dB
	Monitor Source: alsa_output.pci-0000_00_1b.0.analog-stereo.monitor
	Latency: 0 usec, configured 0 usec
	Flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY 
	Properties:
		object.path = "alsa:pcm:0:front:0:playback"
		api.alsa.path = "front:0"
		api.alsa.pcm.card = "0"
		api.alsa.pcm.stream = "playback"
		audio.channels = "2"
		audio.position = "FL,FR"
		device.routes = "2"
		alsa.resolution_bits = "16"
		device.api = "alsa"
		device.class = "sound"
		alsa.class = "generic"
		alsa.subclass = "generic-mix"
		alsa.name = "ALC269 Analog"
		alsa.id = "ALC269 Analog"
		alsa.subdevice = "0"
		alsa.subdevice_name = "subdevice #0"
		alsa.device = "0"
		alsa.card = "0"
		alsa.card_name = "HDA Intel MID"
		alsa.long_card_name = "HDA Intel MID at 0xf0b00000 irq 30"
		alsa.driver_name = "snd_hda_intel"
		device.profile.name = "analog-stereo"
		device.profile.description = "Analog Stereo"
		card.profile.device = "3"
		device.id = "42"
		factory.name = "api.alsa.pcm.sink"
		priority.driver = "1009"
		priority.session = "1009"
		media.class = "Audio/Sink"
		node.nick = "HDA Intel MID"
		node.name = "alsa_output.pci-0000_00_1b.0.analog-stereo"
		device.description = "Built-in Audio Analog Stereo"
		device.icon_name = "audio-card-analog"
		node.pause-on-idle = "false"
		factory.id = "18"
		client.id = "32"
		node.driver = "true"
		factory.mode = "merge"
		audio.adapt.follower = ""
		library.name = "audioconvert/libspa-audioconvert"
		object.id = "45"
		node.max-latency = "8192/48000"
	Ports:
		analog-output-speaker: Speakers (type: Speaker, priority: 10000, availability group: Legacy 3, availability unknown)
		analog-output-headphones: Headphones (type: Headphones, priority: 9900, availability group: Legacy 4, not available)
	Active Port: analog-output-speaker
	Formats:
		pcm

Sink #59
	State: SUSPENDED
	Name: bluez_output.CC_98_8B_7F_A2_98.headset-head-unit
	Description: MDR-XB950N1
	Driver: PipeWire
	Sample Specification: s16le 1ch 16000Hz
	Channel Map: mono
	Owner Module: 4294967295
	Mute: no
	Volume: mono: 48060 /  73% / -8.08 dB
	        balance 0.00
	Base Volume: 65536 / 100% / 0.00 dB
	Monitor Source: bluez_output.CC_98_8B_7F_A2_98.headset-head-unit.monitor
	Latency: 0 usec, configured 0 usec
	Flags: HARDWARE HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY 
	Properties:
		api.bluez5.transport = ""
		api.bluez5.profile = "headset-head-unit"
		api.bluez5.codec = "msbc"
		api.bluez5.address = "CC:98:8B:7F:A2:98"
		device.routes = "1"
		card.profile.device = "1"
		device.form_factor = "headset"
		device.bus = "bluetooth"
		device.id = "54"
		device.description = "MDR-XB950N1"
		node.name = "bluez_output.CC_98_8B_7F_A2_98.headset-head-unit"
		factory.name = "api.bluez5.sco.sink"
		priority.driver = "1010"
		priority.session = "1010"
		device.icon_name = "audio-headset-bluetooth"
		node.pause-on-idle = "false"
		factory.id = "8"
		device.api = "bluez5"
		media.class = "Audio/Sink"
		node.driver = "true"
		factory.mode = "merge"
		audio.adapt.follower = ""
		library.name = "audioconvert/libspa-audioconvert"
		object.id = "59"
		client.id = "31"
	Ports:
		headset-output: Headset (type: Headset, priority: 0, available)
	Active Port: headset-output
	Formats:
		pcm

inxi -AE

Audio:     Device-1: Intel 5 Series/3400 Series High Definition Audio driver: snd_hda_intel 
           Device-2: NVIDIA High Definition Audio driver: snd_hda_intel 
           Sound Server-1: ALSA v: k5.10.60-1-MANJARO running: yes 
           Sound Server-2: PipeWire v: 0.3.33 running: yes 
Bluetooth: Device-1: Cambridge Silicon Radio Bluetooth Dongle (HCI mode) type: USB driver: btusb 
           Report: rfkill ID: hci0 state: up address: see --recommends 

In pavucontrol have you tried switching to any of the Headset Head Unit profiles on the Configuration tab? On my headphones it works with Headset Head Unit (HSP/HFP, codec CVSD).

It doesn’t work. There is a volume line (idk if it’s correct way to call it) in pavucontrol on both mSBC and CVSD and I can see how it bumps when I turn on the music, but I can’t hear anything.

On the playback tab have you set it so that it outputs to the headset?
Does the sound work when you use the AAC or aptX profiles?

Just to correct the record

PulseAudio has supported HSP/HFP for telephony and A2DP for audio playback for many years
Latest release v15.0 added support for mSBC

That is all