Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 5140

Beginners • ALSA errors - proper way to config ALSA on headless Pi?

$
0
0
I am playing a sound file with PyAudio, through a USB audio adapter, on a Pi Zero 2 W, running 64-bit Pi OS Lite (Bookworm).

I am able to set the audio device (from default HDMI to USB). Tutorials say this is all that is necessary. It works - but I get the below errors every time the sound file starts (although the sound does play).

These seem to be ALSA config errors and nothing to do with PyAudio. Forum posts argue about how you’re supposed to deal with this.

How do we configure ALSA properly, so it always works on startup or reboot, on a headless Pi? I.e. not just suppress warnings.

Code:

ALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rearALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfeALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.sideALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.hdmi.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2'ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directoryALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directoryALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM hdmiALSA lib confmisc.c:1369:(snd_func_refer) Unable to find definition 'cards.0.pcm.hdmi.0:CARD=0,AES0=4,AES1=130,AES2=0,AES3=2'ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directoryALSA lib conf.c:5703:(snd_config_expand) Evaluate error: No such file or directoryALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM hdmiALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modemALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modemALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phonelineALSA lib pcm.c:2666:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline

Code:

Cannot connect to server socket err = No such file or directoryCannot connect to server request channeljack server is not running or cannot be startedJackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlockJackShmReadWritePtr::~JackShmReadWritePtr - Init not done for -1, skipping unlock

Statistics: Posted by ericjforman — Wed Jan 08, 2025 4:02 pm — Replies 0 — Views 28



Viewing all articles
Browse latest Browse all 5140

Trending Articles