How to rename similar USB audio devices in pipewire/wireplumber?

I probably have a unique issue, due to me volunteering as interpreter and therefore using 3 different soundcards at once…

Hardware setup:
1x built-in soundcard on ASUS TUF Mainboard
1x USB soundcard Behringer UCA 200
1x USB soundcard Behringer UCA 222 (replacement for logilink soundcard)

I installed Manjaro-pipewire with the corresponding dependecies and also Wireplumber instead of Pipewire-Sessions as recommended by the Arch Wiki in order to transition from Pulseaudio to Pipewire.
Transistion went smooth and everything worked good (and still does) until I had to replace my logilink soundcard.

My issue:
Both Behringer USB soundcards show up as “PCM 2902 Audio Codec Analog Stereo” in Pavucontrol and all other programs.
I would like to be able to distinguish the two USB soundcards by name, instead of having to guess which PCM2902 is the one I have plugged into a certain channel on my hardware audio mixer.
(The logilink showed up as “CM106-linke sound device”, so I could easily distinguish the cards)

What I tried so far:

  1. created a udev rule 91-usb-sound.rules in order to rename the cards in ALSA → success, aplay -l lists the cards as I wanted to name them:
**** Liste der Hardware-Geräte (PLAYBACK) ****
Karte 0: NVidia [HDA NVidia], Gerät 3: HDMI 0 [HDMI 0]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 0: NVidia [HDA NVidia], Gerät 7: HDMI 1 [HDMI 1]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 0: NVidia [HDA NVidia], Gerät 8: HDMI 2 [HDMI 2]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 0: NVidia [HDA NVidia], Gerät 9: HDMI 3 [HDMI 3]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 1: Generic [HD-Audio Generic], Gerät 0: ALC887-VD Analog [ALC887-VD Analog]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 1: Generic [HD-Audio Generic], Gerät 1: ALC887-VD Digital [ALC887-VD Digital]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 3: CODEC [USB Audio CODEC], Gerät 0: USB Audio [USB Audio]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 4: Behringer [USB Audio CODEC], Gerät 0: USB Audio [USB Audio]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
  1. Tried to write a default.pa as proposed by the Arch Wiki in PulseAudio/Examples in order to rename the Pulseaudio devices → failed, pavucontrol showed no devices at all, so I removed the file and rebooted.

  2. Tried to copy the lua script 50-alsa-config.lua from /usr/share/wireplumber/main.lua.d to /etc/wireplumber/main-lua.d and adding a section to the alsa_monitor.rules:

matches = {
      {
        { "alsa.card", "matches", "3" },
      },
    },
  apply_properties = {
      {
      [device.nick] = "UCA222",
      [device.description] = "Behringer UCA222 DE"
      },
  matches = {
      {
        { "alsa.card", "matches", "4" },
      },
    },
  apply_properties = {
      {
      [device.nick] = "Behringer",
      [device.description] = "Behringer UCA200 EN"
      },
  },

This also had the effect that after rebooting the system, pavucontrol showed no devices at all, only the dummy-device and no sound output possible.
So I removed that file too and I’m back to square one.
All cards are working fine, so technically my problem does not really qualifiy as “sound issue” .
Maybe anyone can give me a hint how to rename the devices for pulseaudio and pipewire and wireplumber or how to manage that the ALSA card names will be used?
Output of pact list cards

Card #49
	Name: alsa_card.usb-Burr-Brown_from_TI_USB_Audio_CODEC-00
	Driver: alsa
	Owner Module: n/a
	Properties:
		api.acp.auto-port = "false"
		api.acp.auto-profile = "false"
		api.alsa.card = "4"
		api.alsa.card.longname = "Burr-Brown from TI USB Audio CODEC at usb-0000:02:00.0-6, full speed"
		api.alsa.card.name = "USB Audio CODEC"
		api.alsa.path = "hw:4"
		api.alsa.use-acp = "true"
		api.dbus.ReserveDevice1 = "Audio4"
		device.api = "alsa"
		device.bus = "usb"
		device.bus-id = "usb-Burr-Brown_from_TI_USB_Audio_CODEC-00"
		device.bus_path = "pci-0000:02:00.0-usb-0:6:1.0"
		device.description = "PCM2902 Audio Codec"
		device.enum.api = "udev"
		device.icon_name = "audio-card-analog-usb"
		device.name = "alsa_card.usb-Burr-Brown_from_TI_USB_Audio_CODEC-00"
		device.nick = "USB Audio CODEC"
		device.plugged.usec = "7256547"
		device.product.id = "0x2902"
		device.product.name = "PCM2902 Audio Codec"
		device.profile-set = "texas-instruments-pcm2902.conf"
		device.serial = "Burr-Brown_from_TI_USB_Audio_CODEC"
		device.subsystem = "sound"
		sysfs.path = "/devices/pci0000:00/0000:00:01.3/0000:02:00.0/usb1/1-6/1-6:1.0/sound/card4"
		device.vendor.id = "0x08bb"
		device.vendor.name = "Texas Instruments"
		media.class = "Audio/Device"
		factory.id = "14"
		client.id = "35"
		object.id = "49"
		object.serial = "49"
		object.path = "alsa:pcm:4"
		alsa.card = "4"
		alsa.card_name = "USB Audio CODEC"
		alsa.long_card_name = "Burr-Brown from TI USB Audio CODEC at usb-0000:02:00.0-6, full speed"
		alsa.driver_name = "snd_usb_audio"
		device.string = "4"
	Profiles:
		off: Aus (sinks: 0, sources: 0, priority: 0, available: yes)
		output:analog-stereo-output+input:analog-stereo-input: Analog Stereo-Ausgabe + Analog Stereo-Eingabe (sinks: 1, sources: 1, priority: 5054, available: yes)
		output:analog-stereo-output+input:analog-mono-left: Analog Stereo-Ausgabe + Analog Mono (Left)-Eingabe (sinks: 1, sources: 1, priority: 5032, available: yes)
		output:analog-stereo-output+input:analog-mono-right: Analog Stereo-Ausgabe + Analog Mono (Right)-Eingabe (sinks: 1, sources: 1, priority: 5031, available: yes)
		output:analog-stereo-output+input:analog-mono: Analog Stereo-Ausgabe + Analog Mono-Eingabe (sinks: 1, sources: 1, priority: 5003, available: yes)
		output:analog-stereo-output: Analog Stereo-Ausgabe (sinks: 1, sources: 0, priority: 5000, available: yes)
		input:analog-stereo-input: Analog Stereo-Eingabe (sinks: 0, sources: 1, priority: 54, available: yes)
		input:analog-mono-left: Analog Mono (Left)-Eingabe (sinks: 0, sources: 1, priority: 32, available: yes)
		input:analog-mono-right: Analog Mono (Right)-Eingabe (sinks: 0, sources: 1, priority: 31, available: yes)
		input:analog-mono: Analog Mono-Eingabe (sinks: 0, sources: 1, priority: 3, available: yes)
		pro-audio: Pro Audio (sinks: 1, sources: 1, priority: 1, available: yes)
	Active Profile: output:analog-stereo-output+input:analog-stereo-input
	Ports:
		analog-input: Analoger Eingang (type: Analog, priority: 10000, latency offset: 0 usec, availability unknown)
			Properties:
				port.type = "analog"
				card.profile.port = "0"
			Part of profile(s): input:analog-stereo-input, input:analog-mono, input:analog-mono-left, input:analog-mono-right, output:analog-stereo-output+input:analog-stereo-input, output:analog-stereo-output+input:analog-mono, output:analog-stereo-output+input:analog-mono-left, output:analog-stereo-output+input:analog-mono-right
		analog-output: Analoge Ausgabe (type: Analog, priority: 9900, latency offset: 0 usec, availability unknown)
			Properties:
				port.type = "analog"
				card.profile.port = "1"
			Part of profile(s): output:analog-stereo-output, output:analog-stereo-output+input:analog-stereo-input, output:analog-stereo-output+input:analog-mono, output:analog-stereo-output+input:analog-mono-left, output:analog-stereo-output+input:analog-mono-right

Card #50
	Name: alsa_card.pci-0000_09_00.1
	Driver: alsa
	Owner Module: n/a
	Properties:
		api.acp.auto-port = "false"
		api.acp.auto-profile = "false"
		api.alsa.card = "0"
		api.alsa.card.longname = "HDA NVidia at 0xf6080000 irq 81"
		api.alsa.card.name = "HDA NVidia"
		api.alsa.path = "hw:0"
		api.alsa.use-acp = "true"
		api.dbus.ReserveDevice1 = "Audio0"
		device.api = "alsa"
		device.bus = "pci"
		device.bus_path = "pci-0000:09:00.1"
		device.description = "GK208 HDMI/DP Audio Controller"
		device.enum.api = "udev"
		device.icon_name = "audio-card-analog-pci"
		device.name = "alsa_card.pci-0000_09_00.1"
		device.nick = "HDA NVidia"
		device.plugged.usec = "5148405"
		device.product.id = "0x0e0f"
		device.product.name = "GK208 HDMI/DP Audio Controller"
		device.subsystem = "sound"
		sysfs.path = "/devices/pci0000:00/0000:00:03.1/0000:09:00.1/sound/card0"
		device.vendor.id = "0x10de"
		device.vendor.name = "NVIDIA Corporation"
		media.class = "Audio/Device"
		factory.id = "14"
		client.id = "35"
		object.id = "50"
		object.serial = "50"
		object.path = "alsa:pcm:0"
		alsa.card = "0"
		alsa.card_name = "HDA NVidia"
		alsa.long_card_name = "HDA NVidia at 0xf6080000 irq 81"
		alsa.driver_name = "snd_hda_intel"
		device.string = "0"
	Profiles:
		off: Aus (sinks: 0, sources: 0, priority: 0, available: yes)
		output:hdmi-stereo: Digital Stereo (HDMI)-Ausgabe (sinks: 1, sources: 0, priority: 5900, available: no)
		output:hdmi-stereo-extra1: Digital Stereo (HDMI 2)-Ausgabe (sinks: 1, sources: 0, priority: 5700, available: no)
		output:hdmi-stereo-extra2: Digital Stereo (HDMI 3)-Ausgabe (sinks: 1, sources: 0, priority: 5700, available: no)
		output:hdmi-stereo-extra3: Digital Stereo (HDMI 4)-Ausgabe (sinks: 1, sources: 0, priority: 5700, available: no)
		output:hdmi-surround: Digital Surround 5.1 (HDMI)-Ausgabe (sinks: 1, sources: 0, priority: 800, available: no)
		output:hdmi-surround71: Digital Surround 7.1 (HDMI)-Ausgabe (sinks: 1, sources: 0, priority: 800, available: no)
		output:hdmi-surround-extra1: Digital Surround 5.1 (HDMI 2)-Ausgabe (sinks: 1, sources: 0, priority: 600, available: no)
		output:hdmi-surround71-extra1: Digital Surround 7.1 (HDMI 2)-Ausgabe (sinks: 1, sources: 0, priority: 600, available: no)
		output:hdmi-surround-extra2: Digital Surround 5.1 (HDMI 3)-Ausgabe (sinks: 1, sources: 0, priority: 600, available: no)
		output:hdmi-surround71-extra2: Digital Surround 7.1 (HDMI 3)-Ausgabe (sinks: 1, sources: 0, priority: 600, available: no)
		output:hdmi-surround-extra3: Digital Surround 5.1 (HDMI 4)-Ausgabe (sinks: 1, sources: 0, priority: 600, available: no)
		output:hdmi-surround71-extra3: Digital Surround 7.1 (HDMI 4)-Ausgabe (sinks: 1, sources: 0, priority: 600, available: no)
		pro-audio: Pro Audio (sinks: 4, sources: 0, priority: 1, available: yes)
	Active Profile: off
	Ports:
		hdmi-output-0: HDMI / DisplayPort (type: HDMI, priority: 5900, latency offset: 0 usec, availability group: Legacy 1, not available)
			Properties:
				port.type = "hdmi"
				port.availability-group = "Legacy 1"
				device.icon_name = "video-display"
				card.profile.port = "0"
			Part of profile(s): output:hdmi-stereo, output:hdmi-surround, output:hdmi-surround71
		hdmi-output-1: HDMI / DisplayPort 2 (type: HDMI, priority: 5800, latency offset: 0 usec, availability group: Legacy 2, not available)
			Properties:
				port.type = "hdmi"
				port.availability-group = "Legacy 2"
				device.icon_name = "video-display"
				card.profile.port = "1"
			Part of profile(s): output:hdmi-stereo-extra1, output:hdmi-surround-extra1, output:hdmi-surround71-extra1
		hdmi-output-2: HDMI / DisplayPort 3 (type: HDMI, priority: 5700, latency offset: 0 usec, availability group: Legacy 3, not available)
			Properties:
				port.type = "hdmi"
				port.availability-group = "Legacy 3"
				device.icon_name = "video-display"
				card.profile.port = "2"
			Part of profile(s): output:hdmi-stereo-extra2, output:hdmi-surround-extra2, output:hdmi-surround71-extra2
		hdmi-output-3: HDMI / DisplayPort 4 (type: HDMI, priority: 5600, latency offset: 0 usec, availability group: Legacy 4, not available)
			Properties:
				port.type = "hdmi"
				port.availability-group = "Legacy 4"
				device.icon_name = "video-display"
				card.profile.port = "3"
			Part of profile(s): output:hdmi-stereo-extra3, output:hdmi-surround-extra3, output:hdmi-surround71-extra3

Card #51
	Name: alsa_card.usb-SunplusIT_Inc_FHD_Camera_Microphone_01.00.00-02
	Driver: alsa
	Owner Module: n/a
	Properties:
		api.acp.auto-port = "false"
		api.acp.auto-profile = "false"
		api.alsa.card = "2"
		api.alsa.card.longname = "SunplusIT Inc FHD Camera Microphone at usb-0000:0b:00.3-1, high speed"
		api.alsa.card.name = "FHD Camera Microphone"
		api.alsa.path = "hw:2"
		api.alsa.use-acp = "true"
		api.dbus.ReserveDevice1 = "Audio2"
		device.api = "alsa"
		device.bus = "usb"
		device.bus-id = "usb-SunplusIT_Inc_FHD_Camera_Microphone_01.00.00-02"
		device.bus_path = "pci-0000:0b:00.3-usb-0:1:1.2"
		device.description = "FHD Camera Microphone"
		device.enum.api = "udev"
		device.form_factor = "webcam"
		device.icon_name = "camera-web-analog-usb"
		device.name = "alsa_card.usb-SunplusIT_Inc_FHD_Camera_Microphone_01.00.00-02"
		device.nick = "FHD Camera Microphone"
		device.plugged.usec = "7256473"
		device.product.id = "0x28c4"
		device.product.name = "FHD Camera Microphone"
		device.serial = "SunplusIT_Inc_FHD_Camera_Microphone_01.00.00"
		device.subsystem = "sound"
		sysfs.path = "/devices/pci0000:00/0000:00:08.1/0000:0b:00.3/usb5/5-1/5-1:1.2/sound/card2"
		device.vendor.id = "0x1bcf"
		device.vendor.name = "Sunplus Innovation Technology Inc."
		media.class = "Audio/Device"
		factory.id = "14"
		client.id = "35"
		object.id = "51"
		object.serial = "51"
		object.path = "alsa:pcm:2"
		alsa.card = "2"
		alsa.card_name = "FHD Camera Microphone"
		alsa.long_card_name = "SunplusIT Inc FHD Camera Microphone at usb-0000:0b:00.3-1, high speed"
		alsa.driver_name = "snd_usb_audio"
		device.string = "2"
	Profiles:
		off: Aus (sinks: 0, sources: 0, priority: 0, available: yes)
		input:analog-stereo: Analog Stereo-Eingabe (sinks: 0, sources: 1, priority: 65, available: yes)
		input:iec958-stereo: Digital Stereo (IEC958)-Eingabe (sinks: 0, sources: 1, priority: 55, available: yes)
		pro-audio: Pro Audio (sinks: 0, sources: 1, priority: 1, available: yes)
	Active Profile: input:analog-stereo
	Ports:
		analog-input-mic: Mikrofon (type: Mic, priority: 8700, latency offset: 0 usec, availability unknown)
			Properties:
				port.type = "mic"
				device.icon_name = "audio-input-microphone"
				card.profile.port = "0"
			Part of profile(s): input:analog-stereo
		iec958-stereo-input: Digitaleingang (S/PDIF) (type: SPDIF, priority: 0, latency offset: 0 usec, availability unknown)
			Properties:
				port.type = "spdif"
				card.profile.port = "1"
			Part of profile(s): input:iec958-stereo

Card #52
	Name: alsa_card.usb-Burr-Brown_from_TI_USB_Audio_CODEC-00.2
	Driver: alsa
	Owner Module: n/a
	Properties:
		api.acp.auto-port = "false"
		api.acp.auto-profile = "false"
		api.alsa.card = "3"
		api.alsa.card.longname = "Burr-Brown from TI USB Audio CODEC at usb-0000:0b:00.3-2, full speed"
		api.alsa.card.name = "USB Audio CODEC"
		api.alsa.path = "hw:3"
		api.alsa.use-acp = "true"
		api.dbus.ReserveDevice1 = "Audio3"
		device.api = "alsa"
		device.bus = "usb"
		device.bus-id = "usb-Burr-Brown_from_TI_USB_Audio_CODEC-00"
		device.bus_path = "pci-0000:0b:00.3-usb-0:2:1.0"
		device.description = "PCM2902 Audio Codec"
		device.enum.api = "udev"
		device.icon_name = "audio-card-analog-usb"
		device.name = "alsa_card.usb-Burr-Brown_from_TI_USB_Audio_CODEC-00.2"
		device.nick = "USB Audio CODEC"
		device.plugged.usec = "7257812"
		device.product.id = "0x2902"
		device.product.name = "PCM2902 Audio Codec"
		device.profile-set = "texas-instruments-pcm2902.conf"
		device.serial = "Burr-Brown_from_TI_USB_Audio_CODEC"
		device.subsystem = "sound"
		sysfs.path = "/devices/pci0000:00/0000:00:08.1/0000:0b:00.3/usb5/5-2/5-2:1.0/sound/card3"
		device.vendor.id = "0x08bb"
		device.vendor.name = "Texas Instruments"
		media.class = "Audio/Device"
		factory.id = "14"
		client.id = "35"
		object.id = "52"
		object.serial = "52"
		object.path = "alsa:pcm:3"
		alsa.card = "3"
		alsa.card_name = "USB Audio CODEC"
		alsa.long_card_name = "Burr-Brown from TI USB Audio CODEC at usb-0000:0b:00.3-2, full speed"
		alsa.driver_name = "snd_usb_audio"
		device.string = "3"
	Profiles:
		off: Aus (sinks: 0, sources: 0, priority: 0, available: yes)
		output:analog-stereo-output+input:analog-stereo-input: Analog Stereo-Ausgabe + Analog Stereo-Eingabe (sinks: 1, sources: 1, priority: 5054, available: yes)
		output:analog-stereo-output+input:analog-mono-left: Analog Stereo-Ausgabe + Analog Mono (Left)-Eingabe (sinks: 1, sources: 1, priority: 5032, available: yes)
		output:analog-stereo-output+input:analog-mono-right: Analog Stereo-Ausgabe + Analog Mono (Right)-Eingabe (sinks: 1, sources: 1, priority: 5031, available: yes)
		output:analog-stereo-output+input:analog-mono: Analog Stereo-Ausgabe + Analog Mono-Eingabe (sinks: 1, sources: 1, priority: 5003, available: yes)
		output:analog-stereo-output: Analog Stereo-Ausgabe (sinks: 1, sources: 0, priority: 5000, available: yes)
		input:analog-stereo-input: Analog Stereo-Eingabe (sinks: 0, sources: 1, priority: 54, available: yes)
		input:analog-mono-left: Analog Mono (Left)-Eingabe (sinks: 0, sources: 1, priority: 32, available: yes)
		input:analog-mono-right: Analog Mono (Right)-Eingabe (sinks: 0, sources: 1, priority: 31, available: yes)
		input:analog-mono: Analog Mono-Eingabe (sinks: 0, sources: 1, priority: 3, available: yes)
		pro-audio: Pro Audio (sinks: 1, sources: 1, priority: 1, available: yes)
	Active Profile: output:analog-stereo-output+input:analog-stereo-input
	Ports:
		analog-input: Analoger Eingang (type: Analog, priority: 10000, latency offset: 0 usec, availability unknown)
			Properties:
				port.type = "analog"
				card.profile.port = "0"
			Part of profile(s): input:analog-stereo-input, input:analog-mono, input:analog-mono-left, input:analog-mono-right, output:analog-stereo-output+input:analog-stereo-input, output:analog-stereo-output+input:analog-mono, output:analog-stereo-output+input:analog-mono-left, output:analog-stereo-output+input:analog-mono-right
		analog-output: Analoge Ausgabe (type: Analog, priority: 9900, latency offset: 0 usec, availability unknown)
			Properties:
				port.type = "analog"
				card.profile.port = "1"
			Part of profile(s): output:analog-stereo-output, output:analog-stereo-output+input:analog-stereo-input, output:analog-stereo-output+input:analog-mono, output:analog-stereo-output+input:analog-mono-left, output:analog-stereo-output+input:analog-mono-right

Card #53
	Name: alsa_card.pci-0000_0b_00.4
	Driver: alsa
	Owner Module: n/a
	Properties:
		api.acp.auto-port = "false"
		api.acp.auto-profile = "false"
		api.alsa.card = "1"
		api.alsa.card.longname = "HD-Audio Generic at 0xf6400000 irq 83"
		api.alsa.card.name = "HD-Audio Generic"
		api.alsa.path = "hw:1"
		api.alsa.use-acp = "true"
		api.dbus.ReserveDevice1 = "Audio1"
		device.api = "alsa"
		device.bus = "pci"
		device.bus_path = "pci-0000:0b:00.4"
		device.description = "Starship/Matisse HD Audio Controller"
		device.enum.api = "udev"
		device.icon_name = "audio-card-analog-pci"
		device.name = "alsa_card.pci-0000_0b_00.4"
		device.nick = "HD-Audio Generic"
		device.plugged.usec = "5169196"
		device.product.id = "0x1487"
		device.product.name = "Starship/Matisse HD Audio Controller"
		device.subsystem = "sound"
		sysfs.path = "/devices/pci0000:00/0000:00:08.1/0000:0b:00.4/sound/card1"
		device.vendor.id = "0x1022"
		device.vendor.name = "Advanced Micro Devices, Inc. [AMD]"
		media.class = "Audio/Device"
		factory.id = "14"
		client.id = "35"
		object.id = "53"
		object.serial = "53"
		object.path = "alsa:pcm:1"
		alsa.card = "1"
		alsa.card_name = "HD-Audio Generic"
		alsa.long_card_name = "HD-Audio Generic at 0xf6400000 irq 83"
		alsa.driver_name = "snd_hda_intel"
		device.string = "1"
	Profiles:
		off: Aus (sinks: 0, sources: 0, priority: 0, available: yes)
		output:analog-stereo+input:analog-stereo: Analog Stereo Duplex (sinks: 1, sources: 1, priority: 6565, available: yes)
		output:analog-stereo: Analog Stereo-Ausgabe (sinks: 1, sources: 0, priority: 6500, available: yes)
		output:iec958-stereo+input:analog-stereo: Digital Stereo (IEC958)-Ausgabe + Analog Stereo-Eingabe (sinks: 1, sources: 1, priority: 5565, available: yes)
		output:iec958-stereo: Digital Stereo (IEC958)-Ausgabe (sinks: 1, sources: 0, priority: 5500, available: yes)
		output:iec958-ac3-surround-51+input:analog-stereo: Digital Surround 5.1 (IEC958/AC3)-Ausgabe + Analog Stereo-Eingabe (sinks: 1, sources: 1, priority: 365, available: yes)
		output:iec958-ac3-surround-51: Digital Surround 5.1 (IEC958/AC3)-Ausgabe (sinks: 1, sources: 0, priority: 300, available: yes)
		input:analog-stereo: Analog Stereo-Eingabe (sinks: 0, sources: 1, priority: 65, available: yes)
		pro-audio: Pro Audio (sinks: 2, sources: 2, priority: 1, available: yes)
	Active Profile: output:analog-stereo+input:analog-stereo
	Ports:
		analog-input-front-mic: Vorderes Mikrofon (type: Mic, priority: 8500, latency offset: 0 usec, availability group: Legacy 1, not available)
			Properties:
				port.type = "mic"
				port.availability-group = "Legacy 1"
				device.icon_name = "audio-input-microphone"
				card.profile.port = "0"
			Part of profile(s): input:analog-stereo, output:analog-stereo+input:analog-stereo, output:iec958-stereo+input:analog-stereo, output:iec958-ac3-surround-51+input:analog-stereo
		analog-input-rear-mic: Rückwärtiges Mikrofon (type: Mic, priority: 8200, latency offset: 0 usec, availability group: Legacy 2, not available)
			Properties:
				port.type = "mic"
				port.availability-group = "Legacy 2"
				device.icon_name = "audio-input-microphone"
				card.profile.port = "1"
			Part of profile(s): input:analog-stereo, output:analog-stereo+input:analog-stereo, output:iec958-stereo+input:analog-stereo, output:iec958-ac3-surround-51+input:analog-stereo
		analog-input-linein: Line-Eingang (type: Line, priority: 8100, latency offset: 0 usec, availability group: Legacy 3, available)
			Properties:
				port.type = "line"
				port.availability-group = "Legacy 3"
				card.profile.port = "2"
			Part of profile(s): input:analog-stereo, output:analog-stereo+input:analog-stereo, output:iec958-stereo+input:analog-stereo, output:iec958-ac3-surround-51+input:analog-stereo
		analog-output-lineout: Line-Ausgang (type: Line, priority: 9000, latency offset: 0 usec, availability group: Legacy 4, available)
			Properties:
				port.type = "line"
				port.availability-group = "Legacy 4"
				card.profile.port = "3"
			Part of profile(s): output:analog-stereo, output:analog-stereo+input:analog-stereo
		analog-output-headphones: Kopfhörer (type: Headphones, priority: 9900, latency offset: 0 usec, availability group: Legacy 5, not available)
			Properties:
				port.type = "headphones"
				port.availability-group = "Legacy 5"
				device.icon_name = "audio-headphones"
				card.profile.port = "4"
			Part of profile(s): output:analog-stereo, output:analog-stereo+input:analog-stereo
		iec958-stereo-output: Digitalausgang (S/PDIF) (type: SPDIF, priority: 0, latency offset: 0 usec, availability unknown)
			Properties:
				port.type = "spdif"
				card.profile.port = "5"
			Part of profile(s): output:iec958-stereo, output:iec958-stereo+input:analog-stereo

Output of wpctl status:

PipeWire 'pipewire-0' [0.3.65, wuschel@box, cookie:1721285349]
 └─ Clients:
        32. pipewire                            [0.3.65, wuschel@box, pid:1763]
        33. xfwm4                               [0.3.65, wuschel@box, pid:1751]
        34. WirePlumber                         [0.3.65, wuschel@box, pid:1762]
        35. WirePlumber [export]                [0.3.65, wuschel@box, pid:1762]
        38. xfce4-pulseaudio-plugin             [0.3.65, wuschel@box, pid:1797]
        43. xdg-desktop-portal                  [0.3.65, wuschel@box, pid:1849]
        44. Viber                               [0.3.65, wuschel@box, pid:1826]
        45. viber                               [0.3.65, wuschel@box, pid:1826]
        67. viber                               [0.3.65, wuschel@box, pid:1826]
        85. Chromium input                      [0.3.65, wuschel@box, pid:1826]
        86. Thunar                              [0.3.65, wuschel@box, pid:1786]
        87. TzClock                             [0.3.65, wuschel@box, pid:2210]
        88. wrapper-2.0                         [0.3.65, wuschel@box, pid:1797]
        89. Thunderbird                         [0.3.65, wuschel@box, pid:3884]
        90. wrapper-2.0                         [0.3.65, wuschel@box, pid:1795]
        95. Firefox                             [0.3.65, wuschel@box, pid:4208]
        96. PipeWire ALSA [audacious]           [0.3.65, wuschel@box, pid:4600]
        97. Chromium input                      [0.3.65, wuschel@box, pid:3806]
       114. WEBRTC VoiceEngine                  [0.3.65, wuschel@box, pid:3774]
       119. Thunderbird                         [0.3.65, wuschel@box, pid:3884]
       121. Chromium input                      [0.3.65, wuschel@box, pid:4834]
       134. wrapper-2.0                         [0.3.65, wuschel@box, pid:1796]
       135. wpctl                               [0.3.65, wuschel@box, pid:32764]
       136. xfce4-panel                         [0.3.65, wuschel@box, pid:1781]
       138. Firefox                             [0.3.65, wuschel@box, pid:4208]
       139. Firefox                             [0.3.65, wuschel@box, pid:4208]

Audio
 ├─ Devices:
 │      49. PCM2902 Audio Codec                 [alsa]
 │      50. GK208 HDMI/DP Audio Controller      [alsa]
 │      51. FHD Camera Microphone               [alsa]
 │      52. PCM2902 Audio Codec                 [alsa]
 │      53. Starship/Matisse HD Audio Controller [alsa]
 │  
 ├─ Sinks:
 │  *   36. Starship/Matisse HD Audio Controller Analog Stereo [vol: 1.05]
 │      62. PCM2902 Audio Codec Analog Stereo   [vol: 0.60]
 │      65. PCM2902 Audio Codec Analog Stereo   [vol: 1.00]
 │  
 ├─ Sink endpoints:
 │  
 ├─ Sources:
 │      61. Starship/Matisse HD Audio Controller Analog Stereo [vol: 1.00]
 │  *   63. PCM2902 Audio Codec Analog Stereo   [vol: 1.00]
 │      64. FHD Camera Microphone Analog Stereo [vol: 1.00]
 │      66. PCM2902 Audio Codec Analog Stereo   [vol: 1.00]
 │  
 ├─ Source endpoints:
 │  
 └─ Streams:

Video
 ├─ Devices:
 │      46. FHD Camera Microphone: FHD Came     [libcamera]
 │      47. FHD Camera Microphone               [v4l2]
 │      48. FHD Camera Microphone               [v4l2]
 │  
 ├─ Sinks:
 │  
 ├─ Sink endpoints:
 │  
 ├─ Sources:
 │      54. FHD Camera Microphone  FHD Came    
 │  *   56. FHD Camera Microphone (V4L2)       
 │  
 ├─ Source endpoints:
 │  
 └─ Streams:

Settings
 └─ Default Configured Node Names:
         0. Audio/Sink    alsa_output.pci-0000_0b_00.4.analog-stereo
         1. Audio/Source  alsa_input.usb-Burr-Brown_from_TI_USB_Audio_CODEC-00.analog-stereo-input

Sorry for the long post, and thanks in advance for any help.

Hi there.

This may not help but I found it & thought I’d share, just in case you find something that works…

https://unix.stackexchange.com/questions/648666/rename-devices-in-pipewire

More power to you.

Ruziel :slight_smile:

1 Like

Thanks for pointing me to this post.

Either I misread the pipewire instructions about the order in which configuration is processed or something else, but the clue was to put the renaming procedure for each device into it’s own .lua script in ~/.config/wireplumber/main.lua.d/5x-alsa-rename.lua

rule = {
  matches = {
    {
      { "api.alsa.path", "equals", "hw:4" },
    },
  },
  apply_properties = {
    ["node.description"] = "Behringer",
    ["node.nick"] = "Behringer",
  },
}

table.insert(alsa_monitor.rules,rule)

works for me in renaming the input side. Will play around more to get the sinks renamed as well.

Placing similar scripts in /usr/share/wireplumber/config.lua.d/ or /etc/wireplumber/config.lua.d/ yielded no results for me.

Hi wuschel109,

I’m trying to do the same thing, but I’ve run into the following issues:

  1. I don’t have this directory ~/.config/wireplumber/
    Maybe you just need to create it yourself

  2. I don’t know where I can find this information { “api.alsa.path”, “equals”, “hw:4” } on my hw?
    The hw I know is this:

Bus 001 Device 003: ID 1532:051e Razer USA, Ltd RC30-026902, Gaming Headset [Nari Essential, Wireless, Receiver]

but I don’t know where to find information about the other peripherals
Screenshot from 2024-04-03 12-15-15

My distro is:

OS: Manjaro Linux x86_64
Kernel: 6.6.19-1-MANJARO
Shell: zsh 5.9
DE: GNOME 45.4
Terminal: gnome-terminal

Any help?

Use pactl list cards or pw-cli list-objects to find out more information about PipeWire audio devices

1 Like

Hi nikgnomic,

I followed the steps step by step:

  1. I made the directory ‘~/.config/wireplumber/wireplumber.conf.d’
  2. I made the file nari-essential-rename.conf
    and I wrote the rule:
monitor.alsa.rules = [
    {
        matches = [
            {
            	node.name = "alsa_output.usb-Razer_Razer_Nari_Essential-00.analog-stereo"
        	}
        ],
        actions = {
            update-props = {
            	node.description = "Gaming Nari Essential"
            	device.description = "Gaming Nari Essential"
                device.form-factor = "headset",
                device.icon-name   = "audio-headset-symbolic",
            }
        }
    }
]

This is the file I created, but when I restart the service the name remains
the same as the image of before.

After several attempts and reading several guides
I discovered this article that indicates a GNOME extension
that does everything in a simple way

enjoy