Kubuntu 17.10 下 PulseAudio 环回模块发出噼啪声/噪音

Kubuntu 17.10 下 PulseAudio 环回模块发出噼啪声/噪音

我尝试通过线路输入立体声插孔将音频从我的第二台显示器传输到 Kubuntu,经过一番摆弄alsamixer(取消静音线路并正确设置音量)并添加load-module module-loopback到我的/etc/pulse/default.pa

我目前遇到的最大问题是播放音频时会发出噼啪声/噪音 - 即使在将线路输入音量调整到约 5%(高于这个音量会很痛苦)并增加外部放大器的音量后也是如此。(在 Windows 10 下,即使线路输入音量为 100%,使用此设置也不会出现噼啪声/声音问题)

到目前为止我已经尝试过:

1)在 PulseAudio 中,添加用于停用基于计时器的调度,这有助于其他遇到噼啪声的人load-module module-udev-detect tsched=0tsched=0/etc/pulse/default.pa

2)合并1)/etc/pulse/daemon.conf对 PulseAudio 中的默认片段数和缓冲区大小进行设置进行了修改(如下所示:https://wiki.archlinux.org/index.php/PulseAudio/Troubleshooting#Static_noise_when_using_headphones

3)明确写出环回源和环回接收器及其速率和通道:

load-module module-loopback source=alsa_input.pci-0000_12_00.3.analog-stereo sink=alsa_output.usb-FiiO_DigiHug_USB_Audio-01.analog-stereo rate=44100 channels=2

4)修改或/etc/modprobe.d/alsa-base.conf按照这里建议的方式进行:options snd-hda-intel position_fix=1options snd-hda-intel position_fix=2https://wiki.ubuntu.com/Audio/PositionReporting

我的系统:

  • Kubuntu 17.10,64 位
  • 内核版本 4.13.0-36-generic
  • AMD Ryzen 7 1700X CPU
  • 16 GB 内存
  • 华擎 X370 Taichi 主板
  • Nvidia GTX 1070 GPU

lspci -nnk | grep -i audio -A2
0e:00.1 Audio device [0403]: NVIDIA Corporation GP104 High Definition Audio Controller [10de:10f0] (rev a1)
        Subsystem: CardExpert Technology GP104 High Definition Audio Controller [10b0:1b81]
        Kernel driver in use: snd_hda_intel
        Kernel modules: snd_hda_intel
--
12:00.3 Audio device [0403]: Advanced Micro Devices, Inc. [AMD] Device [1022:1457]
        Subsystem: ASRock Incorporation Device [1849:1220]
        Kernel driver in use: snd_hda_intel

cat /proc/asound/cards
 0 [NVidia         ]: HDA-Intel - HDA NVidia
                      HDA NVidia at 0xfd080000 irq 329                                                                                                                                  
 1 [Audio          ]: USB-Audio - DigiHug USB Audio                                                                                                                                     
                      FiiO DigiHug USB Audio at usb-0000:11:00.3-2, full speed
 2 [Generic        ]: HDA-Intel - HD-Audio Generic
                      HD-Audio Generic at 0xfd900000 irq 331

pactl list sources
Quelle #0
        Status: RUNNING
        Name: alsa_output.usb-FiiO_DigiHug_USB_Audio-01.analog-stereo.monitor
        Beschreibung: Monitor of DigiHug USB Audio Analog Stereo
        Treiber: module-alsa-card.c
        Abtastwert-Angabe: s16le 2ch 44100Hz
        Kanalzuordnung: front-left,front-right
        Besitzer-Modul: 7
        Stumm: ja
        Lautstärke: front-left: 65536 / 100% / 0,00 dB,   front-right: 65536 / 100% / 0,00 dB
                Verteilung 0,00
        Basis-Lautstärke: 65536 / 100% / 0,00 dB
        Ziel-Monitor: alsa_output.usb-FiiO_DigiHug_USB_Audio-01.analog-stereo
        Latenz: 0 usec, eingestellt 40000 usec
        Flags: DECIBEL_VOLUME LATENCY 
        Eigenschaften:
                device.description = "Monitor of DigiHug USB Audio Analog Stereo"
                device.class = "monitor"
                alsa.card = "1"
                alsa.card_name = "DigiHug USB Audio"
                alsa.long_card_name = "FiiO DigiHug USB Audio at usb-0000:11:00.3-2, full speed"
                alsa.driver_name = "snd_usb_audio"
                device.bus_path = "pci-0000:11:00.3-usb-0:2:1.1"
                sysfs.path = "/devices/pci0000:00/0000:00:07.1/0000:11:00.3/usb3/3-2/3-2:1.1/sound/card1"
                udev.id = "usb-FiiO_DigiHug_USB_Audio-01"
                device.bus = "usb"
                device.vendor.id = "1852"
                device.vendor.name = "GYROCOM C&C Co., LTD"
                device.product.id = "7022"
                device.product.name = "DigiHug USB Audio"
                device.serial = "FiiO_DigiHug_USB_Audio"
                device.string = "1"
                module-udev-detect.discovered = "1"
                device.icon_name = "audio-card-usb"
        Formate:
                pcm

Quelle #1
        Status: RUNNING
        Name: alsa_input.pci-0000_12_00.3.analog-stereo
        Beschreibung: HD-Audio Generic Analog Stereo
        Treiber: module-alsa-card.c
        Abtastwert-Angabe: s16le 2ch 44100Hz
        Kanalzuordnung: front-left,front-right
        Besitzer-Modul: 8
        Stumm: nein
        Lautstärke: front-left: 6554 /  10% / -60,00 dB,   front-right: 6554 /  10% / -60,00 dB
                Verteilung 0,00
        Basis-Lautstärke: 6554 /  10% / -60,00 dB
        Ziel-Monitor: k. A.
        Latenz: 30 usec, eingestellt 40000 usec
        Flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY 
        Eigenschaften:
                alsa.resolution_bits = "16"
                device.api = "alsa"
                device.class = "sound"
                alsa.class = "generic"
                alsa.subclass = "generic-mix"
                alsa.name = "ALC1220 Analog"
                alsa.id = "ALC1220 Analog"
                alsa.subdevice = "0"
                alsa.subdevice_name = "subdevice #0"
                alsa.device = "0"
                alsa.card = "2"
                alsa.card_name = "HD-Audio Generic"
                alsa.long_card_name = "HD-Audio Generic at 0xfd900000 irq 331"
                alsa.driver_name = "snd_hda_intel"
                device.bus_path = "pci-0000:12:00.3"
                sysfs.path = "/devices/pci0000:00/0000:00:08.1/0000:12:00.3/sound/card2"
                device.bus = "pci"
                device.vendor.id = "1022"
                device.vendor.name = "Advanced Micro Devices, Inc. [AMD]"
                device.product.id = "1457"
                device.string = "front:2"
                device.buffering.buffer_size = "65536"
                device.buffering.fragment_size = "32768"
                device.access_mode = "mmap+timer"
                device.profile.name = "analog-stereo"
                device.profile.description = "Analog Stereo"
                device.description = "HD-Audio Generic Analog Stereo"
                alsa.mixer_name = "Realtek ALC1220"
                alsa.components = "HDA:10ec1220,18491220,00100003"
                module-udev-detect.discovered = "1"
                device.icon_name = "audio-card-pci"
        Ports:
                analog-input-front-mic: Vorderes Mikrofon (priority: 8500, not available)
                analog-input-rear-mic: Rückwärtiges Mikrofon (priority: 8200, not available)
                analog-input-linein: Eingang (priority: 8100, available)
        Aktiver Port: analog-input-linein
        Formate:
                pcm

pactl list sinks
Ziel #0
        Status: RUNNING
        Name: alsa_output.usb-FiiO_DigiHug_USB_Audio-01.analog-stereo
        Beschreibung: DigiHug USB Audio Analog Stereo
        Treiber: module-alsa-card.c
        Abtastwert-Angabe: s16le 2ch 44100Hz
        Kanalzuordnung: front-left,front-right
        Besitzer-Modul: 7
        Stumm: nein
        Lautstärke: front-left: 65536 / 100% / 0,00 dB,   front-right: 65536 / 100% / 0,00 dB
                Verteilung 0,00
        Basis-Lautstärke: 65536 / 100% / 0,00 dB
        Quellen-Monitor: alsa_output.usb-FiiO_DigiHug_USB_Audio-01.analog-stereo.monitor
        Latenz: 46296 usec, eingestellt 40000 usec
        Flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY 
        Eigenschaften:
                alsa.resolution_bits = "16"
                device.api = "alsa"
                device.class = "sound"
                alsa.class = "generic"
                alsa.subclass = "generic-mix"
                alsa.name = "USB Audio"
                alsa.id = "USB Audio"
                alsa.subdevice = "0"
                alsa.subdevice_name = "subdevice #0"
                alsa.device = "0"
                alsa.card = "1"
                alsa.card_name = "DigiHug USB Audio"
                alsa.long_card_name = "FiiO DigiHug USB Audio at usb-0000:11:00.3-2, full speed"
                alsa.driver_name = "snd_usb_audio"
                device.bus_path = "pci-0000:11:00.3-usb-0:2:1.1"
                sysfs.path = "/devices/pci0000:00/0000:00:07.1/0000:11:00.3/usb3/3-2/3-2:1.1/sound/card1"
                udev.id = "usb-FiiO_DigiHug_USB_Audio-01"
                device.bus = "usb"
                device.vendor.id = "1852"
                device.vendor.name = "GYROCOM C&C Co., LTD"
                device.product.id = "7022"
                device.product.name = "DigiHug USB Audio"
                device.serial = "FiiO_DigiHug_USB_Audio"
                device.string = "front:1"
                device.buffering.buffer_size = "352800"
                device.buffering.fragment_size = "176400"
                device.access_mode = "mmap+timer"
                device.profile.name = "analog-stereo"
                device.profile.description = "Analog Stereo"
                device.description = "DigiHug USB Audio Analog Stereo"
                alsa.mixer_name = "USB Mixer"
                alsa.components = "USB1852:7022"
                module-udev-detect.discovered = "1"
                device.icon_name = "audio-card-usb"
        Ports:
                analog-output: Analoge Ausgabe (priority: 9900)
        Aktiver Port: analog-output
        Formate:
                pcm

我的基本音频设置:

输入:

  • 来自第二台显示器的音频进入计算机线路输入
  • 所有其他音频均来自系统/应用程序/音乐

输出:

  • 我的耳机连接到的 USB-DAC/AMP

答案1

帮我修复这个问题的关键项如下。

案例修改

  1. 拆下 GPU 风扇外壳,我的 GPU 上有一个保护性塑料外壳,听外壳内部物理声音时会发现它发出一些噪音。
  2. 重新安置 RAM,我的 RAM 位于 NVMe 卡的正旁边,所以我将其移至下一个插槽。
  3. 移除 NVMe GPU 附近的防护罩,主板上的 NVMe 棒顶部有一个保护罩

电源改造

  1. 将两台机器的电源移至不同的插座。当我了解接地后,这实际上有助于减少很多反馈噪音。

PulseAudio 修改

load-module module-loopback source=alsa_input.usb-Corsair_CORSAIR_VOID_ELITE_Wireless_Gaming_Dongle-00.multichannel-input sink=alsa_output.pci-0000_09_00.3.analog-stereo
load-module module-loopback source=alsa_input.pci-0000_09_00.3.analog-stereo sink=alsa_output.usb-Corsair_CORSAIR_VOID_ELITE_Wireless_Gaming_Dongle-00.iec958-stereo


set-default-sink alsa_output.usb-Corsair_CORSAIR_VOID_ELITE_Wireless_Gaming_Dongle-00.iec958-stereo
set-default-source alsa_input.usb-Corsair_CORSAIR_VOID_ELITE_Wireless_Gaming_Dongle-00.multichannel-input
set-source-volume alsa_input.pci-0000_09_00.3.analog-stereo 5000

set-card-profile alsa_card.usb-HD_Webcam_USB_HD_Webcam_USB_HD_Webcam_USB-02 off
set-card-profile alsa_card.pci-0000_07_00.1 off
set-card-profile alsa_card.pci-0000_09_00.3 output:analog-stereo+input:analog-stereo

set-sink-port alsa_output.pci-0000_09_00.3.analog-stereo analog-output-lineout
set-source-port alsa_input.pci-0000_09_00.3.analog-stereo analog-input-linein

尽管如此,我仍然会听到一些反馈噪音,但仅限于高 GPU 帧速率期间。我相信这是电源问题,并订购了另一个部件来帮助减少这种反馈。基本上是一个接地环路辅助设备。

这也是我对这个问题的挣扎的参考。 https://bbs.archlinux.org/viewtopic.php?pid=1917945#p1917945

编辑1 事实证明,这实际上与软件无关,而是硬件问题。我买了 2 个,将它们插在两台机器之间,问题就完全解决了。即使在高音量下也不会再有反馈。 https://www.amazon.com/gp/product/B019393MV2/ref=ppx_yo_dt_b_asin_title_o03_s00?ie=UTF8&psc=1

相关内容