I managed to achieve true mono output by combining the stereo stream into a mono sink Pipewire - Module Combine Stream:
use $ wpctl status
to get the sink id of your desired sink and $ wpctl inspect [ID]
to get the node.name variable to use on the configuration file.
$ wpctl status
PipeWire 'pipewire-0' [0.3.56, user@hostname, cookie:1163266174]
Audio
├─ Devices:
│ 42. HD Audio Controller [alsa]
│ 105. USB PnP Audio Device [alsa]
│
├─ Sinks:
│ * 48. HD Audio Controller Analog Stereo [vol: 0.50]
│
├─ ...
│
├─ Sources:
│ * 101. USB PnP Audio Device Mono [vol: 0.74]
│
└─ ...
$ wpctl inspect 48
id 48, type PipeWire:Interface:Node
...
...
* factory.id = "18"
factory.mode = "merge"
factory.name = "api.alsa.pcm.sink"
...
* media.class = "Audio/Sink"
* node.description = "HD Audio Controller Analog Stereo"
* node.name = "alsa_output.pci-0000_08_00.4.analog-stereo"
* node.nick = "ALC1220 Analog"
...
* object.path = "alsa:pcm:1:front:1:playback"
* object.serial = "49"
...
In your distribution folder of pipewire(usually /usr/share/pipewire
), find the pipewire.conf
file and add this configuration with the modifications that suits your needs. You can either just copy the part inside context.modules=[]
or create a new file and add to the ~/.config/pipewire/pipewire.conf.d/
or ~/.config/pipewire/pipewire-pulse.conf.d
directories.
At the context.modules
section:
context.modules = [
{ name = libpipewire-module-combine-stream
args = {
combine.mode = sink
node.name = "combine_stereo_to_mono_sink" # Can be any name of your choice
node.description = "Mono Speakers" # This is the name that will appear in the sound settings
combine.latency-compensate = false
combine.props = {
audio.position = [ MONO ]
}
stream.props = {
stream.dont-remix = true
}
stream.rules = [
{ matches = [
{ media.class = "Audio/Sink"
node.name = "alsa_output.pci-0000_08_00.4.analog-stereo" # Your node.name here
} ]
actions = { create-stream = {
audio.position = [ FL FR ]
combine.audio.position = [ MONO ] # These both are what combine both channels into one
} } }
]
}
}
]
After saving the file, either reboot your system or restart pipewire and wireplumber:
$ systemctl --user restart pipewire pipewire-pulse wireplumber
This is my sound settings:
Mono Speakers
Mono Speakers2