Xruns and crackling: I can't get my usb microphone to record good audio
Fixed (I hope)
Ok, I think I have found my issue for good.
ADB (which I need to use my phone as a camera) is the root cause.
It is an issue that is around from 2 years (and this explains my recordings in the last year):
https://issuetracker.google.com/issues/150888445?pli=1
It seems that Linux + ADB + NVIDIA's USB C controller destroys my audio.
Disabling NVIDIA's USB C controller as said here solves the problem for me:
https://www.reddit.com/r/linuxquestions/comments/qlrcfj/comment/j1fnp4b
But really, this is was so convoluted that it hurts:
- On Windows seems a non issue.
- My videocard doesn't have a USB C port but only the hardware capabilities.
- ADB with the NVIDIA USB controller disabled doesn't cause the issue.
- Using Nouveau doesn't help, because it is an USB controller.
- It was enabled by OBS (which I use often) and remained there the whole time ruining the whole system.
So at the end it wasn't pipewire fault, it wasn't broken hardware, it wasn't a bug that only I have, but some convoluted and pretty difficult to track interaction of software and hardware, sorry for all the messages.
PS: Even trying to understand "who is guilty" is funny, the last comment on the issue says ADB constantly opens his USB devices, so is it ADB's fault? but disabling the USB C controller fixes the crackling... so is this NVIDIA's fault? could be even Linux's fault?
Time to go to bed for me I guess.
Original Post
- PipeWire version: 0.3.70
- Distribution and distribution version: Fedora Linux 37 (Thirty Seven)
- Desktop Environment: i3-wm
- Kernel version: 6.2.13-200.fc37.x86_64
Description of Problem:
I get crackling/xruns both on output and input audio, I need some help to troubleshoot/fix this mess.
This happens with many applications and varies in severity.
It seems that xruns almost disappear on the output with min-quantum = 1024 in pipewire.conf.
Instead I have tried many things for the input (an USB microphone) but it just crackles very often.
I like to record me with OBS and this is getting me insane, I'll attach a 20 seconds video where you can ear the issue, it doesn't produce any errors for some reason.
2023-05-01_22-48-13
How Reproducible:
Regarding the output Discord voice-chat can easily trigger xruns, mpv too (vlc seems to not do this), it can be just that many applications behave badly on their own?
Regarding the input, recording both with OBS or Audacity produces crackling (Audacity seems less noticeable).
My setup (maybe someone knows some weird bug with this):
CPU: AMD Ryzen 3500X
Motherboard: MSI B450 Gaming PLUS Max
RAM: 2x8 GB 3000 MHZ
Graphics Card: NVIDIA RTX 2060 Super (driver 525.116.03 from NVIDIA)
Sound card (PCI-E): ASUS Xonar DGX
USB microphone: Fifine T669
I have tried a lot of stuff from pipewire troubleshooting, tuning and also latest git version without resolving the mic problem.
Thanks for your help!