Audio failed to init? (Arch Linux on Raspberry Pi )

Hi,

I’m hoping to find help with a RetroArch issue I’m having on a Raspberry Pi B+ running the latest Arch Linux. When I first set everything up RetroArch works great, but after a half dozen launches of RetroArch I loose sound only in RetroArch. I have erased and rebuild my SD card 3 times and this always happens after a random handful of game launches. It always works at first for a while.

This is what I get from the console:

ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM RetroArch [ERROR] :: alsa_thread_init :: ALSA: Failed to initialize… RetroArch [ERROR] :: init_audio :: Failed to initialize audio driver. Will continue without audio.

I have tried playing audio with alsaplayer from the command line immediately before and after attempting to load a rom in RetroArch and it always works fine so I am guessing the issue is with RetroArch or one of it’s config files.

Can anyone suggest what it is that is causing this or how I could fix it? Any help would be most appreciated.

Thanks in advance,

Eric

Usually, this sort of behavior comes from some other program having exclusive control over it (typically XBMC), but it appears that’s not happening here. I guess you could try using a different audio driver. JACK or rsound or something.

Thanks for the suggestion. I have fixed my problem another way.

For any one else who has sound failures on a raspberry pi (any *nix or any model Pi) you can add the following two lines to your retroarch.cfg to fix it (works for both analog audio out and audio over hdmi with no changes)

audio_device = hw:0,1 audio_volume = 12.0

The first line designates the audio hardware to use. The second sets the dB gain to max for the audio (retroarch seems to be a lot quieter than other audio played on a Pi without this).

Eric

Oh nice. Thanks for posting your solution :slight_smile: