Sample Header Ad - 728x90

Unix & Linux Stack Exchange

Q&A for users of Linux, FreeBSD and other Unix-like operating systems

Latest Questions

0 votes
1 answers
358 views
linux record audio (arecord or similair) and separate left/right channel
I want to record (line in) from an audio device and separate the left and right channel each to a different process, or record them separately of course. What I want is something like that (play command just as example): either: ``` arecord (left channel only) -q -D plughw:1,0 -f S16_LE -r 22050 | p...
I want to record (line in) from an audio device and separate the left and right channel each to a different process, or record them separately of course. What I want is something like that (play command just as example): either:
arecord (left channel only) -q -D plughw:1,0 -f S16_LE -r 22050 | play -t raw -r 22050 -b 16 -e signed -q - 
arecord (right channel only) -q -D plughw:1,0 -f S16_LE -r 22050 | play -t raw -r 22050 -b 16 -e signed -q -
(may also result in device or resource busy?) or something like "arecord | splitchannels (leftchannel | process 1) (rightchannel | process 2)" or possibly more like that "arecord | tee >(getleftchannel | process1) >(getrightchannel | process2) > /dev/null" as intensive web searches didn't give any usable results. Any idea how I can accomplish that?
Paul Neuwirth (111 rep)
Dec 3, 2023, 02:05 PM • Last activity: Aug 5, 2025, 01:07 PM
4 votes
1 answers
3587 views
ALSA doesn't play on HDMI
I have Ubuntu 14.04.3 with kernel 3.16.0-48 installed on mini-PC Gigabyte GB-BXBT-2807. The chipset also integrates audio controller Realtek ALC283. I've been struggling to have my audio play over HDMI, with no luck. First of all, I removed PulseAudio and reinstalled ALSA as was recommended in multi...
I have Ubuntu 14.04.3 with kernel 3.16.0-48 installed on mini-PC Gigabyte GB-BXBT-2807. The chipset also integrates audio controller Realtek ALC283. I've been struggling to have my audio play over HDMI, with no luck. First of all, I removed PulseAudio and reinstalled ALSA as was recommended in multiple articles on the web: % dpkg -l | grep alsa ii alsa-base 1.0.25+dfsg-0ubuntu4 ... ii alsa-utils 1.0.27.2-1ubuntu2 ... After reboot all modules seem to be present: % lsmod | grep snd snd_hda_codec_hdmi 47548 1 snd_hda_codec_realtek 77561 1 snd_hda_codec_generic 69011 1 snd_hda_codec_realtek snd_hda_intel 30469 0 snd_soc_rt5640 93042 0 snd_soc_rl6231 13037 1 snd_soc_rt5640 snd_hda_controller 30228 1 snd_hda_intel snd_hda_codec 139719 5 snd_hda_codec_realtek,snd_hda_codec_hdmi,snd_hda_codec_generic,snd_hda_intel,snd_hda_controller snd_hwdep 17698 1 snd_hda_codec snd_soc_core 200204 1 snd_soc_rt5640 snd_compress 19200 1 snd_soc_core snd_pcm_dmaengine 15172 1 snd_soc_core snd_pcm 104112 7 snd_soc_rt5640,snd_soc_core,snd_hda_codec_hdmi,snd_hda_codec,snd_hda_intel,snd_hda_controller,snd_pcm_dmaengine snd_seq_midi 13564 0 snd_seq_midi_event 14899 1 snd_seq_midi snd_rawmidi 30876 1 snd_seq_midi snd_seq 63074 2 snd_seq_midi_event,snd_seq_midi snd_seq_device 14497 3 snd_seq,snd_rawmidi,snd_seq_midi snd_timer 29562 2 snd_pcm,snd_seq snd 79468 13 snd_hda_codec_realtek,snd_soc_core,snd_hwdep,snd_timer,snd_hda_codec_hdmi,snd_pcm,snd_seq,snd_rawmidi,snd_hda_codec_generic,snd_hda_codec,snd_hda_intel,snd_seq_device,snd_compress soundcore 15047 2 snd,snd_hda_codec snd_soc_sst_acpi 13007 0 % % aplay -l **** List of PLAYBACK Hardware Devices **** card 0: PCH [HDA Intel PCH], device 0: ALC283 Analog [ALC283 Analog] Subdevices: 1/1 Subdevice #0: subdevice #0 card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0] Subdevices: 1/1 Subdevice #0: subdevice #0 % I also added my account in audio group. Here is a list of PCMs: % aplay -L null Discard all samples (playback) or generate zero samples (capture) default:CARD=PCH HDA Intel PCH, ALC283 Analog Default Audio Device sysdefault:CARD=PCH HDA Intel PCH, ALC283 Analog Default Audio Device front:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog Front speakers surround40:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog 4.0 Surround output to Front and Rear speakers surround41:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog 4.1 Surround output to Front, Rear and Subwoofer speakers surround50:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog 5.0 Surround output to Front, Center and Rear speakers surround51:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog 5.1 Surround output to Front, Center, Rear and Subwoofer speakers surround71:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog 7.1 Surround output to Front, Center, Side, Rear and Woofer speakers hdmi:CARD=PCH,DEV=0 HDA Intel PCH, HDMI 0 HDMI Audio Output dmix:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog Direct sample mixing device dmix:CARD=PCH,DEV=3 HDA Intel PCH, HDMI 0 Direct sample mixing device dsnoop:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog Direct sample snooping device dsnoop:CARD=PCH,DEV=3 HDA Intel PCH, HDMI 0 Direct sample snooping device hw:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog Direct hardware device without any conversions hw:CARD=PCH,DEV=3 HDA Intel PCH, HDMI 0 Direct hardware device without any conversions plughw:CARD=PCH,DEV=0 HDA Intel PCH, ALC283 Analog Hardware device with all software conversions plughw:CARD=PCH,DEV=3 HDA Intel PCH, HDMI 0 Hardware device with all software conversions % What happens is that I'm able to play sounds via headset connected to audio jack, however I'm unable to do this via HDMI link hooked to a TV. I tried to run aplay -D for different devices marked as DEV=3 as listed above, but none of them worked. Also, it doesn't work in FireFox. Is there a special configuration to set audio play on HDMI? What else should I try?
Mark (1943 rep)
Sep 7, 2016, 12:48 AM • Last activity: Jul 29, 2025, 06:04 AM
0 votes
1 answers
32 views
Playing an audio file using Procmail does not work (no audio card found)
I have a strange issue on my Debian server. I am receiving mails with Postfix and "Procmail" for the user `notfall`. After a mail was received, the script from Procmail should play an audio file. But it does not find any audio card. If I issue the command `aplay -l` interactively, I can see the exis...
I have a strange issue on my Debian server. I am receiving mails with Postfix and "Procmail" for the user notfall. After a mail was received, the script from Procmail should play an audio file. But it does not find any audio card. If I issue the command aplay -l interactively, I can see the existing audio cards: $ aplay -l **** Liste der Hardware-Geräte (PLAYBACK) **** Karte 0: PCH [HDA Intel PCH], Gerät 0: 92HD81B1X5 Analog [92HD81B1X5 Analog] Sub-Geräte: 1/1 Sub-Gerät #0: subdevice #0 Karte 0: PCH [HDA Intel PCH], Gerät 3: HDMI 0 [HDMI 0] Sub-Geräte: 1/1 Sub-Gerät #0: subdevice #0 Karte 0: PCH [HDA Intel PCH], Gerät 7: HDMI 1 [HDMI 1] Sub-Geräte: 1/1 Sub-Gerät #0: subdevice #0 Karte 0: PCH [HDA Intel PCH], Gerät 8: HDMI 2 [HDMI 2] Sub-Geräte: 1/1 Sub-Gerät #0: subdevice #0 The first one is the correct one: Karte 0: PCH [HDA Intel PCH], Gerät 0: 92HD81B1X5 Analog [92HD81B1X5 Analog] The script is as follows: $ cat alarm.sh #!/bin/bash aplay -l ffplay -nodisp -autoexit /home/notfall/beep.wav sleep 1 Whenever a new mail from ilo@pentest.internal is received, the script is executed, but I get the following errors in the procmail.log file: From ilo@pentest.internal Fri Jul 25 13:22:07 2025 Subject: =?utf-8?q?HPE=20iLO=20AlertMail=2D058=3A=20=28INFO=29=20AlertMail=20T Folder: /home/notfall/alarm.sh 2223 aplay: device_list:279: no soundcards found... ffplay version 7.1.1-1+b1 Copyright (c) 2003-2025 the FFmpeg developers built with gcc 14 (Debian 14.2.0-19) configuration: --prefix=/usr --extra-version=1+b1 --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --disable-libmfx --disable-omx --enable-gnutls --enable-libaom --enable-libass --enable-libbs2b --enable-libcdio --enable-libcodec2 --enable-libdav1d --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libglslang --enable-libgme --enable-libgsm --enable-libharfbuzz --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzimg --enable-openal --enable-opencl --enable-opengl --disable-sndio --enable-libvpl --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-ladspa --enable-libbluray --enable-libcaca --enable-libdvdnav --enable-libdvdread --enable-libjack --enable-libpulse --enable-librabbitmq --enable-librist --enable-libsrt --enable-libssh --enable-libsvtav1 --enable-libx264 --enable-libzmq --enable-libzvbi --enable-lv2 --enable-sdl2 --enable-libplacebo --enable-librav1e --enable-pocketsphinx --enable-librsvg --enable-libjxl --enable-shared libavutil 59. 39.100 / 59. 39.100 libavcodec 61. 19.101 / 61. 19.101 libavformat 61. 7.100 / 61. 7.100 libavdevice 61. 3.100 / 61. 3.100 libavfilter 10. 4.100 / 10. 4.100 libswscale 8. 3.100 / 8. 3.100 libswresample 5. 3.100 / 5. 3.100 libpostproc 58. 3.100 / 58. 3.100 Input #0, wav, from '/home/notfall/beep.wav': 0KB sq= 0B Metadata: title : we5 Duration: 00:00:01.23, bitrate: 1411 kb/s Stream #0:0: Audio: pcm_s16le ( / 0x0001), 44100 Hz, 2 channels, s16, 1411 kb/s ALSA lib confmisc.c:855:(parse_card) cannot find card '0' ALSA lib conf.c:5205:(_snd_config_evaluate) function snd_func_card_inum returned error: No such file or directory ALSA lib confmisc.c:422:(snd_func_concat) error evaluating strings ALSA lib conf.c:5205:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory ALSA lib confmisc.c:1342:(snd_func_refer) error evaluating name ALSA lib conf.c:5205:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:5728:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2722:(snd_pcm_open_noupdate) Unknown PCM default SDL_OpenAudio (2 channels, 44100 Hz): ALSA: Couldn't open audio device: No such file or directory ALSA lib confmisc.c:855:(parse_card) cannot find card '0' ALSA lib conf.c:5205:(_snd_config_evaluate) function snd_func_card_inum returned error: No such file or directory ALSA lib confmisc.c:422:(snd_func_concat) error evaluating strings ALSA lib conf.c:5205:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory ALSA lib confmisc.c:1342:(snd_func_refer) error evaluating name ALSA lib conf.c:5205:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:5728:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2722:(snd_pcm_open_noupdate) Unknown PCM default SDL_OpenAudio (1 channels, 44100 Hz): ALSA: Couldn't open audio device: No such file or directory No more combinations to try, audio open failed Failed to open file '/home/notfall/beep.wav' or configure filtergraph nan : 0.000 fd= 0 aq= 0KB vq= 0KB sq= 0B The message aplay: device_list:279: no soundcards found... indicates that no audio cards were found. **This is the issue that I don't understand, since the script is executed by the same user.** Even more interestingly, the script works when being executed in a cronjob. The user is always logged in graphically. **Do you folks have any idea why the script can't find the audio card?** Thank you!
Michael Gierer (135 rep)
Jul 28, 2025, 11:20 AM • Last activity: Jul 28, 2025, 12:01 PM
6 votes
1 answers
1995 views
How to make Alsa Loopback device to work in Puredata
I'm trying to route an audio signal from an Airplay source (with Shairport-sync) to Puredata. To do so, I created a Loopback Device in Alsa. Then I set this virtual device as Shairport's output like this (hw:2 is the loopback device) : shairplay-sync -a -Airplay -- -d hw:2 But when I try to set the...
I'm trying to route an audio signal from an Airplay source (with Shairport-sync) to Puredata. To do so, I created a Loopback Device in Alsa. Then I set this virtual device as Shairport's output like this (hw:2 is the loopback device) : shairplay-sync -a -Airplay -- -d hw:2 But when I try to set the loopback device as Puredata's input I get the following message : audio I/O stuck... closing audio I wondered if this issue could come from my .asoundrc file ? Here it is : # playback PCM device: using loopback subdevice 0,0 pcm.amix { type dmix ipc_key 219345 slave { pcm "hw:Loopback,0,0" period_size 1024 buffer_size 2048 rate 44100 } } # capture PCM device: using loopback subdevice 0,1 pcm.asnoop { type dsnoop ipc_key 219346 slave.pcm "hw:Loopback,0,1" } # duplex device combining our PCM devices defined above pcm.aduplex { type asym playback.pcm "amix" capture.pcm "asnoop" } # ------------------------------------------------------ # for jack alsa_in and alsa_out: looped-back signal at other ends pcm.ploop { type plug slave.pcm "hw:Loopback,1,1" } pcm.cloop { type dsnoop ipc_key 219348 slave { pcm "hw:Loopback,1,0" period_size 1024 buffer_size 2048 rate 44100 } } # ------------------------------------------------------ # default device pcm.!default { type plug slave.pcm "aduplex" } Should I add things about format or anything else ? FYI, the Loopback device works well when used with jack audio. Pure data too. I'd like not to use Jack because It looks like It uses too much ressources (I was not able to make Jack, Puredata and the loopback device work together, it crashes each time...) Thank you for the help!
Corentoulf (61 rep)
Apr 23, 2015, 04:20 PM • Last activity: Jul 26, 2025, 11:06 PM
1 votes
1 answers
42 views
Whenever audio is playing, I'd like to close a relay powering a speaker. Where and how can I attach a hook to do that?
I'd like to run 32-bit Raspberry Pi OS Bullseye on a Raspberry Pi 2B system headless, with it receiving audio from various sources (e.g. S/PDIF input from TV, through acting as a Bluetooth speaker, or via running Spotify), apply some filters and EQ (using PulseEffects for example), and output balanc...
I'd like to run 32-bit Raspberry Pi OS Bullseye on a Raspberry Pi 2B system headless, with it receiving audio from various sources (e.g. S/PDIF input from TV, through acting as a Bluetooth speaker, or via running Spotify), apply some filters and EQ (using PulseEffects for example), and output balanced audio to the XLR inputs of mains-powered studio monitors (using a Raspberry Pi DAC Pro for example). Hardware selection and software configuration for this is relatively straightforward. The speakers constantly draw a few watts from the mains, even when idle. It would be nice if I could automate switching power to them on or off depending on whether there's an audible signal being played or not. I could easily build an analog level detection circuit for the task, but I wonder if it's possible to achieve the same in software. I've looked into ALSA documentation (https://www.alsa-project.org/alsa-doc/alsa-lib/) for a few hours, but I'm in over my head. Searching for similar questions from the past revealed two old yet relevant threads, but unfortunately they lack a satisfactory answer. On this site: https://unix.stackexchange.com/questions/203963/detect-when-audio-card-is-powered-using-alsa On the Raspberry Pi forums: [Audio Activation Switch](https://forums.raspberrypi.com/viewtopic.php?t=57808)
jms (113 rep)
Jul 13, 2025, 09:01 PM • Last activity: Jul 14, 2025, 12:13 PM
0 votes
1 answers
23 views
my synth that uses ALSA has poor audio quality on SOME pcs
I've written a softsynth on kubuntu (well, it's a flatpak) that uses ALSA to render the samples. On my main pc that goes to a USB mixer it works fine. On my second pc that goes to a straight audio device the audio is all scratchy and glitchy like the sample buffers aren't sync'd right. I'm sure this...
I've written a softsynth on kubuntu (well, it's a flatpak) that uses ALSA to render the samples. On my main pc that goes to a USB mixer it works fine. On my second pc that goes to a straight audio device the audio is all scratchy and glitchy like the sample buffers aren't sync'd right. I'm sure this is an issue with my code. But ALSA's help is a little slim :) On my main pc where alsa sounds great, the device has these properties:
08:15:05.950599 00:00.000786 PcSng Syn::Init - sound output='USB Audio CODEC|USB Audio' device='hw:6,0'
08:15:05.952192 00:00.001593 PcSng PCM handle name = 'hw:6,0'
08:15:05.952275 00:00.000083 PcSng PCM state = PREPARED
08:15:05.952313 00:00.000038 PcSng access type = RW_INTERLEAVED
08:15:05.952348 00:00.000035 PcSng format = 'S16_LE' (Signed 16 bit Little Endian)
08:15:05.952381 00:00.000033 PcSng subformat = 'STD' (Standard)
08:15:05.952413 00:00.000032 PcSng channels = 2
08:15:05.952445 00:00.000032 PcSng rate = 44100 bps
08:15:05.952477 00:00.000032 PcSng period time = 1451 us
08:15:05.952509 00:00.000032 PcSng period size = 64 frames
08:15:05.952540 00:00.000031 PcSng buffer time = 2902 us
08:15:05.952572 00:00.000032 PcSng buffer size = 128 frames
08:15:05.952604 00:00.000032 PcSng periods per buffer = 2 frames
08:15:05.952637 00:00.000033 PcSng exact rate = 44100/1 bps
08:15:05.952668 00:00.000031 PcSng significant bits = 16
08:15:05.952700 00:00.000032 PcSng is batch = 1
08:15:05.952731 00:00.000031 PcSng is block transfer = 1
08:15:05.952763 00:00.000032 PcSng is double = 0
08:15:05.952795 00:00.000032 PcSng is half duplex = 0
08:15:05.952826 00:00.000031 PcSng is joint duplex = 0
08:15:05.952857 00:00.000031 PcSng can overrange = 0
08:15:05.952925 00:00.000068 PcSng can mmap = 1
08:15:05.953041 00:00.000116 PcSng can pause = 1
08:15:05.953060 00:00.000019 PcSng can resume = 0
08:15:05.953077 00:00.000017 PcSng can sync start = 0
08:15:05.953119 00:00.000042 PcSng    nFr=64 frq=44100
On my second pc where it's scratchy/glitchy the device has these properties
07:30:45.583342 00:00.000356 PcSng Syn::Init - sound output='HDA Intel PCH|ALC256 Analog' device='hw:6,0'
07:30:45.624918 00:00.041576 PcSng PCM handle name = 'hw:6,0'
07:30:45.624946 00:00.000028 PcSng PCM state = PREPARED
07:30:45.624956 00:00.000010 PcSng access type = RW_INTERLEAVED
07:30:45.624966 00:00.000010 PcSng format = 'S16_LE' (Signed 16 bit Little Endian)
07:30:45.624975 00:00.000009 PcSng subformat = 'STD' (Standard)
07:30:45.624984 00:00.000009 PcSng channels = 2
07:30:45.624993 00:00.000009 PcSng rate = 44100 bps
07:30:45.625002 00:00.000009 PcSng period time = 1451 us
07:30:45.625010 00:00.000008 PcSng period size = 64 frames
07:30:45.625019 00:00.000009 PcSng buffer time = 2902 us
07:30:45.625027 00:00.000008 PcSng buffer size = 128 frames
07:30:45.625036 00:00.000009 PcSng periods per buffer = 2 frames
07:30:45.625045 00:00.000009 PcSng exact rate = 44100/1 bps
07:30:45.625054 00:00.000009 PcSng significant bits = 16
07:30:45.625063 00:00.000009 PcSng is batch = 0
07:30:45.625071 00:00.000008 PcSng is block transfer = 1
07:30:45.625080 00:00.000009 PcSng is double = 0
07:30:45.625089 00:00.000009 PcSng is half duplex = 0
07:30:45.625098 00:00.000009 PcSng is joint duplex = 0
07:30:45.625106 00:00.000008 PcSng can overrange = 0
07:30:45.625115 00:00.000009 PcSng can mmap = 1
07:30:45.625124 00:00.000009 PcSng can pause = 1
07:30:45.625132 00:00.000008 PcSng can resume = 0
07:30:45.625141 00:00.000009 PcSng can sync start = 1
07:30:45.625245 00:00.000104 PcSng    nFr=64 frq=44100
So the difference is ok:
08:15:05.952700 00:00.000032 PcSng is batch = 1
08:15:05.953077 00:00.000017 PcSng can sync start = 0
lame:
07:30:45.625063 00:00.000009 PcSng is batch = 0
07:30:45.625141 00:00.000009 PcSng can sync start = 1
Does this give any help on what my soft synth is doing wrong? I use 2 period buffers and my synth flips between generating samples into one then the next. And when I dump the audio, I'm using code like this: (sbyt2 is signed short int, ubyt4 is unsigned long int, etc) The code behaves and I don't see these DBG things in my debug log...
void SndO::Put (sbyt2 *buf)
{ ubyt4 p;
  int   e;
   for (p = 0;  p = 0)  p += e;
      else                          // oops - fixup stuff
         switch (e) {
            case -EAGAIN:
               if ((e = snd_pcm_wait    (_hnd, 1)) = MAX_DITHER)  _dth = 0;
      }
      _lok.Toss ();
DBG("  syn run put");
      _sn->Put ((sbyt2 *)o);           // this'll block us on 2nd call and on
DBG("  syn run bot");
   }
DBG("run end");
}
There is very little duration between "syn run top" and "syn run put". So my sample rendering is plenty fast on both pcs. Very little duration between "syn run bot" and "syn run top" as expected - nothin happens there but a jump :) All the duration is between "syn run put" and "syn run bot" where Put is called. The pc where it runs fine seems to have a more regular duration than on the pc where it doesn't run fine... Can somebody who knows ALSA help me out here, please? And if you know of a preferred audio api on linux, please let me know - I'm pretty sheltered and new to linux... I've heard of pipewire - should I prefer that audio api? Thanks much. oops - I open the alsa device with this code:
SndO::SndO (char *dev, ubyt4 inFr, ubyt4 ifrq)
// device to write,  frames in 1 period,  and frequency
// open up our alsa pcm device (audio out)
// always 2 periods of nFr frames - interleaved stereo s16
: _nFr (inFr), _frq (ifrq)             // what we ask fer.  what we get may diff
{ int   e;  // error
  sbyt4 dir  = 0;
  ubyt4 nPer = 2, nFr = inFr, frq = ifrq;
   StrCp (_dev, dev);
   _hnd = nullptr;
   if ((e = snd_pcm_open (& _hnd, _dev, SND_PCM_STREAM_PLAYBACK,
                                        SND_PCM_NONBLOCK))) {
      if (e == -EBUSY)
DBG("snd_pcm_open s - another app has it - s", _dev, snd_strerror (e));
      else
DBG("snd_pcm_open s died - s",                 _dev, snd_strerror (e));
      _hnd = nullptr;   return;
   }

// SHOISH !!!
  snd_pcm_hw_params_t *hw;
   snd_pcm_hw_params_alloca (& hw);
   snd_pcm_hw_params_any (_hnd, hw);
   if ((e = snd_pcm_hw_params_set_access (_hnd, hw,
                                          SND_PCM_ACCESS_RW_INTERLEAVED)) < 0) {
DBG("pcm_access rw_interleaved died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
   if ((e = snd_pcm_hw_params_set_format (_hnd, hw, SND_PCM_FORMAT_S16)) < 0) {
DBG("pcm_format s16 died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
   if ((e = snd_pcm_hw_params_set_channels (_hnd, hw, 2)) < 0) {
DBG("pcm_channels stereo died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }

   if ((e = snd_pcm_hw_params_set_rate_near (_hnd, hw, & frq, 0)) < 0) {
DBG("pcm_rate 44100 died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
   if (_frq != frq)  DBG("pcm_rate wanted d got d :/", _frq, frq);

   if ((e = snd_pcm_hw_params_set_period_size_near (_hnd, hw,
                                   (snd_pcm_uframes_t *)(& nFr), & dir)) < 0) {
DBG("pcm_period died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
   if (_nFr != nFr)  DBG("pcm_period wanted d got d :/", _nFr, nFr);

   if ((e = snd_pcm_hw_params_set_periods_near (_hnd, hw, & nPer, & dir)) < 0) {
DBG("pcm_periods died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
   if (nPer != 2) {
DBG("pcm_periods is `d not 2 :(", nPer);
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
   if ((e = snd_pcm_hw_params (_hnd, hw)) < 0) {
DBG("pcm_hw died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
Dump (hw);

  snd_pcm_sw_params_t *sw;
   snd_pcm_sw_params_alloca (& sw);
   snd_pcm_sw_params_current (_hnd, sw);
   if ((e = snd_pcm_sw_params_set_start_threshold (_hnd, sw, _nFr)) < 0) {
DBG("pcm_start_thresh died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
   if ((e = snd_pcm_sw_params_set_avail_min (_hnd, sw, _nFr)) < 0) {
DBG("pcm_avail_min died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
   if ((e = snd_pcm_sw_params (_hnd, sw)) < 0) {
DBG("pcm_sw died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }

   if ((e = snd_pcm_nonblock (_hnd, 0)) < 0) {
DBG("pcm_nonblock died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }

   if ((e = snd_pcm_prepare (_hnd)) < 0) {
DBG("pcm_prepare died - `s", snd_strerror (e));
      snd_pcm_close (_hnd);   _hnd = nullptr;   return;
   }
}
Stephen Hazel (111 rep)
Jul 9, 2025, 03:33 PM • Last activity: Jul 11, 2025, 02:46 PM
3 votes
1 answers
2410 views
GStreamer and sample rate conversion
I have a soundcard that is only partially supported in Alsa, i.e. playback is only working in 48 kHz. Most of my audio files are in 44.1 kHz, and I would like to use Exaile as my audio player, as it has all the functionality that I need. The problem is, that gstreamer - the backend for exaile - does...
I have a soundcard that is only partially supported in Alsa, i.e. playback is only working in 48 kHz. Most of my audio files are in 44.1 kHz, and I would like to use Exaile as my audio player, as it has all the functionality that I need. The problem is, that gstreamer - the backend for exaile - does not convert the sample rate with my current settings, so playing back the audio files will result in a speed up, while playing the files with mplayer works just fine, mplayer does sample rate conversion on playback. Is there a way to get gstreamer to convert the sample rate? **EDIT:** The sound card in question is an E-MU 0404 PCI express, see http://alsa-project.org/main/index.php/Matrix:Vendor-Creative_Labs and http://alsa-project.org/main/index.php/Matrix:Module-emu10k1-fpga
Residuum (1106 rep)
Nov 23, 2013, 12:42 PM • Last activity: Jul 3, 2025, 08:04 PM
2 votes
1 answers
4363 views
How to change the default soundcard in Debian to an external USB?
Running Jessie and `aplay -l` gives me this: **** List of PLAYBACK Hardware Devices **** card 0: PCH [HDA Intel PCH], device 0: ALC887-VD Analog [ALC887-VD Analog] Subdevices: 1/1 Subdevice #0: subdevice #0 card 0: PCH [HDA Intel PCH], device 1: ALC887-VD Digital [ALC887-VD Digital] Subdevices: 1/1...
Running Jessie and aplay -l gives me this: **** List of PLAYBACK Hardware Devices **** card 0: PCH [HDA Intel PCH], device 0: ALC887-VD Analog [ALC887-VD Analog] Subdevices: 1/1 Subdevice #0: subdevice #0 card 0: PCH [HDA Intel PCH], device 1: ALC887-VD Digital [ALC887-VD Digital] Subdevices: 1/1 Subdevice #0: subdevice #0 card 1: HDMI [HDA ATI HDMI], device 3: HDMI 0 [HDMI 0] Subdevices: 1/1 Subdevice #0: subdevice #0 card 2: Device [USB Advanced Audio Device], device 0: USB Audio [USB Audio] Subdevices: 1/1 Subdevice #0: subdevice #0 The usb card is my only working device (alsaplayer -o alsa -d hw:2,0 rocknroll.mp3 confirms this) so I came up with the following /etc/modprobe.d/sound file and restarted pulseaudio: options snd cards_limit=3 alias snd-card-0 snd-1 alias snd-card-1 snd-hdmi alias snd-card-2 snd-usb options snd slots=snd_usb_audio,snd_hd_intel,snd-1 But still no sound on my system. What am I not doing? I had to create the sound file above as there was none before. So maybe that's an outdated way of doing things.
user1561108 (1081 rep)
Jul 25, 2016, 11:45 PM • Last activity: Jul 3, 2025, 04:05 AM
0 votes
1 answers
1974 views
Suddenly no sound on Debian Stretch?
After a fresh Win10 installation on a 2nd SSD my speakers on Debian 9 aren't working anymore. Before I attached the 2nd SSD with Win10 the sound was working properly. Interestingly, with attached headphones I get a proper sound. When I switch to Windows the speakers are working as expected so it's n...
After a fresh Win10 installation on a 2nd SSD my speakers on Debian 9 aren't working anymore. Before I attached the 2nd SSD with Win10 the sound was working properly. Interestingly, with attached headphones I get a proper sound. When I switch to Windows the speakers are working as expected so it's not a hardware issue. Linux notebook 4.9.0-6-amd64 #1 SMP Debian 4.9.82-1+deb9u3 (2018-03-02) x86_64 GNU/Linux alsactl init gives Found hardware: "HDA-Intel" "Realtek ALC233" "HDA:10ec0235,1d721501,00100002 HDA:80862809,80860101,00100000" "0x1d72" "0x1501" Hardware is initialized using a generic method I tried the ./alsa-info_alsa-info.sh script whose output can be fetched under http://www.alsa-project.org/db/?f=41ca8f63e14ed055a8a45b4dde60a4d0606bfdb1 My user is added to the audio group and and all volume controls in plasma are at the highest level. Unfortunately I didn't find a proper solution for my problem so any help or ideas would be highly appreciated.
user283499
Mar 30, 2018, 09:36 AM • Last activity: Jun 24, 2025, 10:09 AM
2 votes
2 answers
1973 views
External Microphone not does not work on Linux Mint 20 Ulyana
**Issue** I cannot capture audio using an external microphone on my Linux Mint 20 Ulyana system. In `Sound Settings` under the `Input` tab, when I select the external microphone from the `Device` list, the `Input level` shows zero/nil, irrespective of the `Volume` slider position. [![Screenshot of `...
**Issue** I cannot capture audio using an external microphone on my Linux Mint 20 Ulyana system. In Sound Settings under the Input tab, when I select the external microphone from the Device list, the Input level shows zero/nil, irrespective of the Volume slider position. Screenshot of <code class=Sound Settings detailing the above issue." class="img-fluid rounded" style="max-width: 100%; height: auto; margin: 10px 0;" loading="lazy"> However, I can still use the internal microphone without any issue. **Things I have tried so far** 1. I have tried three different external microphones, including a bluetooth device. I have eliminated the possibility of an issue with Microphone jack and the microphone pin(s). 2. Checked whether the device is muted in alsamixer. It looks like the device is unmuted, as I did not see an MM under the device. Here's my system information: https://termbin.com/31ml
L&#39;Unit&#224; (63 rep)
Nov 2, 2020, 01:33 PM • Last activity: Jun 20, 2025, 12:07 AM
1 votes
1 answers
4096 views
Unable to use python speech_recognition lib Microphone class due to ALSA
I am attempting to write a speech recognition program for the raspberry pi, however I am facing some issues using python's speech_recognition library. From the error messages (posted below) I think the issue may be with the wrong sound card being accessed, however I am able to record with PyAudio (w...
I am attempting to write a speech recognition program for the raspberry pi, however I am facing some issues using python's speech_recognition library. From the error messages (posted below) I think the issue may be with the wrong sound card being accessed, however I am able to record with PyAudio (which I think the microphone class uses) as well as 'arecord' Below is the code I am trying to run: import speech_recognition as sr r = sr.Recognizer() with sr.Microphone() as source: while True: audio = r.listen(source) try: printf("You said " + r.recognize(audio)) except LookupError: printf("Could not understand audio") I have made some adjustments to which soundcard is used as default. My "/etc/modprobe.d/alsa-base.conf" file is untouched and standard. I have created a file in /home/pi under the name ".asoundrc" which contains: pcm.!default { type asym playback.pcm "hw:0,0" capture.pcm "hw:1,0" } This allows for recording from the USB microphone and playback through the on-board headphone jack port. Below is the error message I received when trying to run the python script: pi@raspberrypi ~/Desktop $ python speechtester.py ALSA lib confmisc.c:1286:(snd_func_refer) Unable to find definition 'cards.bcm2835.pcm.front.0:CARD=0' ALSA lib conf.c:4241:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:4720:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM front ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side ALSA lib confmisc.c:1286:(snd_func_refer) Unable to find definition 'cards.bcm2835.pcm.surround40.0:CARD=0' ALSA lib conf.c:4241:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:4720:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM surround40 ALSA lib confmisc.c:1286:(snd_func_refer) Unable to find definition 'cards.bcm2835.pcm.surround51.0:CARD=0' ALSA lib conf.c:4241:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:4720:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM surround41 ALSA lib confmisc.c:1286:(snd_func_refer) Unable to find definition 'cards.bcm2835.pcm.surround51.0:CARD=0' ALSA lib conf.c:4241:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:4720:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM surround50 ALSA lib confmisc.c:1286:(snd_func_refer) Unable to find definition 'cards.bcm2835.pcm.surround51.0:CARD=0' ALSA lib conf.c:4241:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:4720:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM surround51 ALSA lib confmisc.c:1286:(snd_func_refer) Unable to find definition 'cards.bcm2835.pcm.surround71.0:CARD=0' ALSA lib conf.c:4241:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:4720:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM surround71 ALSA lib confmisc.c:1286:(snd_func_refer) Unable to find definition 'cards.bcm2835.pcm.iec958.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2' ALSA lib conf.c:4241:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:4720:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM iec958 ALSA lib confmisc.c:1286:(snd_func_refer) Unable to find definition 'cards.bcm2835.pcm.iec958.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2' ALSA lib conf.c:4241:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:4720:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM spdif ALSA lib confmisc.c:1286:(snd_func_refer) Unable to find definition 'cards.bcm2835.pcm.iec958.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2' ALSA lib conf.c:4241:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory ALSA lib conf.c:4720:(snd_config_expand) Evaluate error: No such file or directory ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM spdif ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline ALSA lib pcm.c:2217:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline ALSA lib pcm_dmix.c:957:(snd_pcm_dmix_open) The dmix plugin supports only playback stream Cannot connect to server socket err = No such file or directory Cannot connect to server request channel jack server is not running or cannot be started Apologies for the relatively long post I just wanted to provide as much information as possible.
Aphire (131 rep)
Jan 22, 2015, 12:28 PM • Last activity: Jun 18, 2025, 06:09 AM
4 votes
2 answers
2063 views
Pulseaudio over network - change output on-the-fly
I successfully configured PulseAudio server and client to send audio over network. It uses direct connection: http://www.freedesktop.org/wiki/Software/PulseAudio/Documentation/User/Network/#index1h2 I'd like to have a possibility to switch between client and server sound card i.e. temporarily disabl...
I successfully configured PulseAudio server and client to send audio over network. It uses direct connection: http://www.freedesktop.org/wiki/Software/PulseAudio/Documentation/User/Network/#index1h2 I'd like to have a possibility to switch between client and server sound card i.e. temporarily disable network stream and go back to internal sound device. Using module-tunnel-sink I could simply move sink-input to desired device but is not an option since it doesn't work well with Flash: >they lead me to believe that Flash is somehow sending the sound to PulseAudio in such a way that it creates a lot of network traffic (think lots of tiny packets, not bandwidth); this overwhelms the network "tunnel" PulseAudio With direct connection I have to restart the application every time I want to switch the output. Any idea how can I solve this?
Blask Poranka (41 rep)
Sep 15, 2013, 05:37 PM • Last activity: Jun 14, 2025, 10:01 AM
3 votes
1 answers
2851 views
I'm trying to compile alsa-driver-RTv5.18 but get date-time error for gcc 4.9.2
/home/user/Downloads/Rt-Linux-HDaudio-5.18/alsa-driver-RTv5.18/alsa/acore/info.c:1065:22: error: macro "__DATE__" might prevent reproducible builds [-Werror=date-time] "Compiled on " __DATE__ " for kernel %s" ^ cc1: some warnings being treated as errors I've tried to export CFLAGS="-Wno-error=date-t...
/home/user/Downloads/Rt-Linux-HDaudio-5.18/alsa-driver-RTv5.18/alsa/acore/info.c:1065:22: error: macro "__DATE__" might prevent reproducible builds [-Werror=date-time] "Compiled on " __DATE__ " for kernel %s" ^ cc1: some warnings being treated as errors I've tried to export CFLAGS="-Wno-error=date-time" but nothing changed.
Vyacheslav (231 rep)
Oct 28, 2015, 04:19 PM • Last activity: Jun 8, 2025, 10:10 PM
3 votes
1 answers
1955 views
Setting up surround sound with optical out
I have Centos 6.3 running on this pc. The built in sound card is detected normally and is a 7.1 card with all speakers listed. It includes a optical out as well as HDMI for the built in video. It looks like pulse audio is automagically misconfiguring the optical out, as it is listed as stereo digita...
I have Centos 6.3 running on this pc. The built in sound card is detected normally and is a 7.1 card with all speakers listed. It includes a optical out as well as HDMI for the built in video. It looks like pulse audio is automagically misconfiguring the optical out, as it is listed as stereo digital out. The analog out is listed as analog stereo - analog surround 5.1. There are 4 or so different variations listed in the pulseaudio sound applet. If I select the test sound it has left and right front. I get audio through the digital connection but is only those 2 channels. opening alsamixer it appears that the surround is activated and detected. It defaults to pulseaudio for both input and output. If I select the hardware card instead, it appears they are turned on properly. I need a way to specify that digital audio is more than 2 channels, or create a specific profile for sound through the iec958 link with 8 channels.
Kendrick (153 rep)
Apr 8, 2013, 10:52 PM • Last activity: Jun 8, 2025, 03:04 AM
0 votes
0 answers
25 views
How to remove ALSA mixer entries?
I'm trying to make I2S on a Raspberry Pi, and I had to edit ALSA config files (`/etc/asound.conf` and `~/.asoundrc`) a lot. Now, because of the changes I did to the config files, I now have to entries for my I2S chip in the alsamixer. These are called "PCM" and "SoftMaster", however I guess the name...
I'm trying to make I2S on a Raspberry Pi, and I had to edit ALSA config files (/etc/asound.conf and ~/.asoundrc) a lot. Now, because of the changes I did to the config files, I now have to entries for my I2S chip in the alsamixer. These are called "PCM" and "SoftMaster", however I guess the names don't matter here. But now that I undid these config changes, the mixer entries are still there and I don't know how to remove them. The files ~/.asoundrc, /etc/asound.conf and /etc/asound.conf.old are all empty, but somehow Alsa still finds two devices called "PCM" and "SoftMaster". So how do I remove those devices or "reload" the alsamixer?
axolotlKing0722 (119 rep)
May 31, 2025, 11:24 AM
3 votes
1 answers
3462 views
ALSAEQUAL runs, but sliders do not seem to affect audio
I want to have an equalizer that lets me easily adjust sound for listening to music on my laptop with headphones. I'm trying to install ALSAEQUAL since it seems that this is the preferred tool for what I need. (If I'm wrong, please let me know). I'd like to be able to adjust equalizer levels to a pr...
I want to have an equalizer that lets me easily adjust sound for listening to music on my laptop with headphones. I'm trying to install ALSAEQUAL since it seems that this is the preferred tool for what I need. (If I'm wrong, please let me know). I'd like to be able to adjust equalizer levels to a preferred state and have my system remember this EQ state across various applications (including web browser, MPD, VLC), as well as across reboots. When I run alsamixer -D equal, the ncurses equalizer interface appears, but it seems that my audio is not respondning---the sliders move, but the playback EQ levels don't seem to change at all when I adjust the sliders. (I've tried with audio playing in both VLC and MPD). How can I configure ALSAEQUAL to work properly? My .asoundrc file is: pcm.!default { type plug; slave.pcm "plugequal"; } ctl.equal { type equal; } pcm.plugequal { type equal; slave.pcm "plug:dmix"; } I am running Linux Mint 16 Cinnamon on a Lenovo Thinkpad e420.
nivek (161 rep)
Feb 27, 2014, 06:41 AM • Last activity: May 22, 2025, 07:01 AM
0 votes
1 answers
2022 views
Recording microphone and listening from ethernet
I'm stuck with an audio problem. I have an old machine (let's call it Alice) under Xubuntu, that I can use to continuously listen sounds from an external microphone plugged in the line-in jack. I can access the machine from my PC (let's call it Bob -under Ubuntu) with ssh (and physically too ... whe...
I'm stuck with an audio problem. I have an old machine (let's call it Alice) under Xubuntu, that I can use to continuously listen sounds from an external microphone plugged in the line-in jack. I can access the machine from my PC (let's call it Bob -under Ubuntu) with ssh (and physically too ... when I will update the login keyboard layout that changed recently I don't know why, and currently prevents me from doing so). I've tried to remotely record the microphone, unsuccessfully, with arecord, pulseaudio, but I'm new with ALSA and PA. With PA the mic isn't listed with pacmd list-sources!?. Is there a (simple?) way I can continuously (but in the same time, I don't have much space on the disk, max 50 GB free) record on Alice (and eventually read the records from Bob)?
L1n3wb13 (1 rep)
Sep 4, 2020, 05:22 PM • Last activity: May 21, 2025, 05:00 PM
1 votes
1 answers
69 views
View available config options (hw params) like rate and channels for an ALSA device
When I try to record from a `hw` ALSA device that does not support the expected parameters, it shows me which formats are available: ``` arecord -D hw:0,0 [...] Available formats: - S16_LE - S24_LE ``` Then I set the correct format, but afterwards it complains about wrong channels and so on. I know,...
When I try to record from a hw ALSA device that does not support the expected parameters, it shows me which formats are available:
arecord -D hw:0,0
[...]
Available formats:
- S16_LE
- S24_LE
Then I set the correct format, but afterwards it complains about wrong channels and so on. I know, I could easliy work around this by using plughw:0,0 instead. However, I want to apply the correct settings, without trial and error. Searching the internet I found an article that mentions aplay -v, but it only works when actually playing back. Also, to me it seems to only display the current configuration, not the available configurations. How do I view the available hardware parameters of an ALSA sound card?
Mo_ (257 rep)
May 13, 2025, 03:12 PM
5 votes
3 answers
1647 views
Increasing volume causes left/right channels to be unbalanced
In Gnome 3, I mapped my volume up to `amixer set Master 1000+`, and down to `amixer set Master 1000-`. This works just fine, as long as I spin the volume roller slowly. [![enter image description here][1]][2] If I am to spin it really quickly, the left and right channel become unbalanced. [![enter i...
In Gnome 3, I mapped my volume up to amixer set Master 1000+, and down to amixer set Master 1000-. This works just fine, as long as I spin the volume roller slowly. enter image description here If I am to spin it really quickly, the left and right channel become unbalanced. enter image description here
Henry (353 rep)
Jul 22, 2015, 03:16 PM • Last activity: May 11, 2025, 10:43 PM
2 votes
1 answers
3574 views
KDE Neon doesn't detect audio devices from motherboard
I recently updated my KDE Neon to 20.04, and audio from the motherboard doesn't get detected. It does, however, detect the one from the GPU. ```none $ inxi -A Audio: Device-1: Intel 100 Series/C230 Series Family HD Audio driver: snd_hda_intel Device-2: NVIDIA GP106 High Definition Audio driver: snd_...
I recently updated my KDE Neon to 20.04, and audio from the motherboard doesn't get detected. It does, however, detect the one from the GPU.
$ inxi -A
Audio:     Device-1: Intel 100 Series/C230 Series Family HD Audio driver: snd_hda_intel 
           Device-2: NVIDIA GP106 High Definition Audio driver: snd_hda_intel 
           Device-3: Huawei UVC Camera type: USB driver: snd-usb-audio,uvcvideo 
           Sound Server: ALSA v: k5.4.0-7634-generic
Before running # alsa force-reload, $ pacmd list-cards only detects 2 audio I/O.
$ pacmd list-cards                         
2 card(s) available.
    index: 0
        name: 
        driver: 
        owner module: 7
        properties:
                alsa.card = "2"
                alsa.card_name = "HDA NVidia"
                alsa.long_card_name = "HDA NVidia at 0xdf080000 irq 17"
                alsa.driver_name = "snd_hda_intel"
                device.bus_path = "pci-0000:01:00.1"
                sysfs.path = "/devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card2"
                device.bus = "pci"
                device.vendor.id = "10de"
                device.vendor.name = "NVIDIA Corporation"
                device.product.id = "10f1"
                device.product.name = "GP106 High Definition Audio Controller"
                device.string = "2"
                device.description = "GP106 High Definition Audio Controller"
                module-udev-detect.discovered = "1"
                device.icon_name = "audio-card-pci"
        profiles:
                output:hdmi-stereo: Digital Stereo (HDMI) Output (priority 5900, available: no)
                output:hdmi-surround: Digital Surround 5.1 (HDMI) Output (priority 800, available: no)
                output:hdmi-surround71: Digital Surround 7.1 (HDMI) Output (priority 800, available: no)
                output:hdmi-stereo-extra1: Digital Stereo (HDMI 2) Output (priority 5700, available: unknown)
                output:hdmi-stereo-extra2: Digital Stereo (HDMI 3) Output (priority 5700, available: no)
                output:hdmi-surround-extra2: Digital Surround 5.1 (HDMI 3) Output (priority 600, available: no)
                output:hdmi-surround71-extra2: Digital Surround 7.1 (HDMI 3) Output (priority 600, available: no)
                output:hdmi-stereo-extra3: Digital Stereo (HDMI 4) Output (priority 5700, available: no)
                output:hdmi-surround-extra3: Digital Surround 5.1 (HDMI 4) Output (priority 600, available: no)
                output:hdmi-surround71-extra3: Digital Surround 7.1 (HDMI 4) Output (priority 600, available: no)
                off: Off (priority 0, available: unknown)
        active profile: 
        sinks:
                alsa_output.pci-0000_01_00.1.hdmi-stereo-extra1/#0: GP106 High Definition Audio Controller Digital Stereo (HDMI 2)
        sources:
                alsa_output.pci-0000_01_00.1.hdmi-stereo-extra1.monitor/#0: Monitor of GP106 High Definition Audio Controller Digital Stereo (HDMI 2)
        ports:
                hdmi-output-0: HDMI / DisplayPort (priority 5900, latency offset 0 usec, available: no)
                        properties:
                                device.icon_name = "video-display"
                hdmi-output-1: HDMI / DisplayPort 2 (priority 5800, latency offset 0 usec, available: yes)
                        properties:
                                device.icon_name = "video-display"
                                device.product.name = "GF276
       "
                hdmi-output-2: HDMI / DisplayPort 3 (priority 5700, latency offset 0 usec, available: no)
                        properties:
                                device.icon_name = "video-display"
                hdmi-output-3: HDMI / DisplayPort 4 (priority 5600, latency offset 0 usec, available: no)
                        properties:
                                device.icon_name = "video-display"
    index: 1
        name: 
        driver: 
        owner module: 8
        properties:
                alsa.card = "1"
                alsa.card_name = "UVC Camera"
                alsa.long_card_name = "Ruision UVC Camera at usb-0000:00:14.0-12, high speed"
                alsa.driver_name = "snd_usb_audio"
                device.bus_path = "pci-0000:00:14.0-usb-0:12:1.2"
                sysfs.path = "/devices/pci0000:00/0000:00:14.0/usb1/1-12/1-12:1.2/sound/card1"
                udev.id = "usb-Ruision_UVC_Camera_20200416-02"
                device.bus = "usb"
                device.vendor.id = "12d1"
                device.vendor.name = "Huawei Technologies Co., Ltd."
                device.product.id = "4321"
                device.product.name = "UVC Camera"
                device.serial = "Ruision_UVC_Camera_20200416"
                device.form_factor = "webcam"
                device.string = "1"
                device.description = "UVC Camera"
                module-udev-detect.discovered = "1"
                device.icon_name = "camera-web-usb"
        profiles:
                input:mono-fallback: Mono Input (priority 1, available: unknown)
                input:multichannel-input: Multichannel Input (priority 1, available: unknown)
                off: Off (priority 0, available: unknown)
        active profile: 
        sources:
                alsa_input.usb-Ruision_UVC_Camera_20200416-02.mono-fallback/#1: UVC Camera Mono
        ports:
                analog-input: Analog Input (priority 10000, latency offset 0 usec, available: unknown)
                        properties:

                multichannel-input: Multichannel Input (priority 0, latency offset 0 usec, available: unknown)
                        properties:
And after running # alsa force-reload:
$ pacmd list-cards      
3 card(s) available.
    index: 0
        name: 
        driver: 
        owner module: 7
        properties:
                alsa.card = "2"
                alsa.card_name = "HDA NVidia"
                alsa.long_card_name = "HDA NVidia at 0xdf080000 irq 17"
                alsa.driver_name = "snd_hda_intel"
                device.bus_path = "pci-0000:01:00.1"
                sysfs.path = "/devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card2"
                device.bus = "pci"
                device.vendor.id = "10de"
                device.vendor.name = "NVIDIA Corporation"
                device.product.id = "10f1"
                device.product.name = "GP106 High Definition Audio Controller"
                device.string = "2"
                device.description = "GP106 High Definition Audio Controller"
                module-udev-detect.discovered = "1"
                device.icon_name = "audio-card-pci"
        profiles:
                output:hdmi-stereo: Digital Stereo (HDMI) Output (priority 5900, available: no)
                output:hdmi-surround: Digital Surround 5.1 (HDMI) Output (priority 800, available: no)
                output:hdmi-surround71: Digital Surround 7.1 (HDMI) Output (priority 800, available: no)
                output:hdmi-stereo-extra1: Digital Stereo (HDMI 2) Output (priority 5700, available: unknown)
                output:hdmi-stereo-extra2: Digital Stereo (HDMI 3) Output (priority 5700, available: no)
                output:hdmi-surround-extra2: Digital Surround 5.1 (HDMI 3) Output (priority 600, available: no)
                output:hdmi-surround71-extra2: Digital Surround 7.1 (HDMI 3) Output (priority 600, available: no)
                output:hdmi-stereo-extra3: Digital Stereo (HDMI 4) Output (priority 5700, available: no)
                output:hdmi-surround-extra3: Digital Surround 5.1 (HDMI 4) Output (priority 600, available: no)
                output:hdmi-surround71-extra3: Digital Surround 7.1 (HDMI 4) Output (priority 600, available: no)
                off: Off (priority 0, available: unknown)
        active profile: 
        sinks:
                alsa_output.pci-0000_01_00.1.hdmi-stereo-extra1/#0: GP106 High Definition Audio Controller Digital Stereo (HDMI 2)
        sources:
                alsa_output.pci-0000_01_00.1.hdmi-stereo-extra1.monitor/#0: Monitor of GP106 High Definition Audio Controller Digital Stereo (HDMI 2)
        ports:
                hdmi-output-0: HDMI / DisplayPort (priority 5900, latency offset 0 usec, available: no)
                        properties:
                                device.icon_name = "video-display"
                hdmi-output-1: HDMI / DisplayPort 2 (priority 5800, latency offset 0 usec, available: yes)
                        properties:
                                device.icon_name = "video-display"
                                device.product.name = "GF276
       "
                hdmi-output-2: HDMI / DisplayPort 3 (priority 5700, latency offset 0 usec, available: no)
                        properties:
                                device.icon_name = "video-display"
                hdmi-output-3: HDMI / DisplayPort 4 (priority 5600, latency offset 0 usec, available: no)
                        properties:
                                device.icon_name = "video-display"
    index: 1
        name: 
        driver: 
        owner module: 8
        properties:
                alsa.card = "1"
                alsa.card_name = "UVC Camera"
                alsa.long_card_name = "Ruision UVC Camera at usb-0000:00:14.0-12, high speed"
                alsa.driver_name = "snd_usb_audio"
                device.bus_path = "pci-0000:00:14.0-usb-0:12:1.2"
                sysfs.path = "/devices/pci0000:00/0000:00:14.0/usb1/1-12/1-12:1.2/sound/card1"
                udev.id = "usb-Ruision_UVC_Camera_20200416-02"
                device.bus = "usb"
                device.vendor.id = "12d1"
                device.vendor.name = "Huawei Technologies Co., Ltd."
                device.product.id = "4321"
                device.product.name = "UVC Camera"
                device.serial = "Ruision_UVC_Camera_20200416"
                device.form_factor = "webcam"
                device.string = "1"
                device.description = "UVC Camera"
                module-udev-detect.discovered = "1"
                device.icon_name = "camera-web-usb"
        profiles:
                input:mono-fallback: Mono Input (priority 1, available: unknown)
                input:multichannel-input: Multichannel Input (priority 1, available: unknown)
                off: Off (priority 0, available: unknown)
        active profile: 
        sources:
                alsa_input.usb-Ruision_UVC_Camera_20200416-02.mono-fallback/#1: UVC Camera Mono
        ports:
                analog-input: Analog Input (priority 10000, latency offset 0 usec, available: unknown)
                        properties:

                multichannel-input: Multichannel Input (priority 0, latency offset 0 usec, available: unknown)
                        properties:

    index: 2
        name: 
        driver: 
        owner module: 29
        properties:
                alsa.card = "0"
                alsa.card_name = "HDA Intel PCH"
                alsa.long_card_name = "HDA Intel PCH at 0xdf220000 irq 128"
                alsa.driver_name = "snd_hda_intel"
                device.bus_path = "pci-0000:00:1f.3"
                sysfs.path = "/devices/pci0000:00/0000:00:1f.3/sound/card0"
                device.bus = "pci"
                device.vendor.id = "8086"
                device.vendor.name = "Intel Corporation"
                device.product.id = "a170"
                device.product.name = "100 Series/C230 Series Chipset Family HD Audio Controller"
                device.form_factor = "internal"
                device.string = "0"
                device.description = "Built-in Audio"
                module-udev-detect.discovered = "1"
                device.icon_name = "audio-card-pci"
        profiles:
                input:analog-stereo: Analog Stereo Input (priority 65, available: no)
                output:analog-stereo: Analog Stereo Output (priority 6500, available: no)
                output:analog-stereo+input:analog-stereo: Analog Stereo Duplex (priority 6565, available: no)
                output:analog-surround-21: Analog Surround 2.1 Output (priority 1300, available: no)
                output:analog-surround-21+input:analog-stereo: Analog Surround 2.1 Output + Analog Stereo Input (priority 1365, available: no)
                output:analog-surround-40: Analog Surround 4.0 Output (priority 1200, available: no)
                output:analog-surround-40+input:analog-stereo: Analog Surround 4.0 Output + Analog Stereo Input (priority 1265, available: no)
                output:analog-surround-41: Analog Surround 4.1 Output (priority 1300, available: no)
                output:analog-surround-41+input:analog-stereo: Analog Surround 4.1 Output + Analog Stereo Input (priority 1365, available: no)
                output:analog-surround-50: Analog Surround 5.0 Output (priority 1200, available: no)
                output:analog-surround-50+input:analog-stereo: Analog Surround 5.0 Output + Analog Stereo Input (priority 1265, available: no)
                output:analog-surround-51: Analog Surround 5.1 Output (priority 1300, available: no)
                output:analog-surround-51+input:analog-stereo: Analog Surround 5.1 Output + Analog Stereo Input (priority 1365, available: no)
                output:iec958-stereo: Digital Stereo (IEC958) Output (priority 5500, available: unknown)
                output:iec958-stereo+input:analog-stereo: Digital Stereo (IEC958) Output + Analog Stereo Input (priority 5565, available: no)
                off: Off (priority 0, available: unknown)
        active profile: 
        sinks:
                alsa_output.pci-0000_00_1f.3.iec958-stereo/#1: Built-in Audio Digital Stereo (IEC958)
        sources:
                alsa_output.pci-0000_00_1f.3.iec958-stereo.monitor/#2: Monitor of Built-in Audio Digital Stereo (IEC958)
        ports:
                analog-input-front-mic: Front Microphone (priority 8500, latency offset 0 usec, available: no)
                        properties:
                                device.icon_name = "audio-input-microphone"
                analog-input-rear-mic: Rear Microphone (priority 8200, latency offset 0 usec, available: no)
                        properties:
                                device.icon_name = "audio-input-microphone"
                analog-input-linein: Line In (priority 8100, latency offset 0 usec, available: no)
                        properties:

                analog-output-lineout: Line Out (priority 9000, latency offset 0 usec, available: no)
                        properties:

                analog-output-headphones: Headphones (priority 9900, latency offset 0 usec, available: no)
                        properties:
                                device.icon_name = "audio-headphones"
                iec958-stereo-output: Digital Output (S/PDIF) (priority 0, latency offset 0 usec, available: unknown)
                        properties:
Is there a way to fix this so that I don't have to run # alsa force-reload every boot? I can have it autorun, but I'd prefer to have this fixed. Here's my system info: * Operating System: KDE neon Testing Edition * KDE Plasma Version: 5.19.3 * KDE Frameworks Version: 5.73.0 * Qt Version: 5.14.2 * Kernel Version: 5.4.0-7634-generic * OS Type: 64-bit * Processors: 4 × Intel® Core™ i5-6500 CPU @ 3.20GHz * Memory: 15.6 GiB of RAM * Graphics Processor: GeForce GTX 1060 6GB/PCIe/SSE2 * Motherboard: MSI H170 Gaming M3
YamiYukiSenpai (141 rep)
Jul 18, 2020, 02:56 AM • Last activity: May 6, 2025, 08:04 PM
Showing page 1 of 20 total questions