![]() |
[PROBLEM] Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - Printable Version +- Moode Forum (https://moodeaudio.org/forum) +-- Forum: moOde audio player (https://moodeaudio.org/forum/forumdisplay.php?fid=3) +--- Forum: Support (https://moodeaudio.org/forum/forumdisplay.php?fid=7) +--- Thread: [PROBLEM] Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" (/showthread.php?tid=2303) |
Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - gwurb - 03-27-2020 Good afternoon, I am getting an error: MPD Error Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0": No such file or directory I am using Hifiberry DAC+ Pro HAT with Raspberry Pi 3B I know this topic has come up before, and I've read through previous posts. What I've noticed is that most people have done one of two things:
Also, re-flash surely shouldn't be the solution to errors? How often will I need to re-flash? Weekly? Monthly? So with these comments what I am hoping for is a method to address the error that I am seeing, to try to get to the root of it and hopefully end up with a more stable system. What's really odd about all of this is that everything was working fine for a few weeks. I then had the MPD error but it was 'fixed' with reboots. Now its there all the time. Maybe the Hifiberry DAC+ Pro is failing? I don't know enough to figure out what the problem may be. Thanks for the help! I've done some digging around and here is what I notice: /var/log/mpd/log ALSA lib pcm_hw.c:1822 ![]() Mar 27 12:48 : exception: Failed to open "ALSA default" (alsa) Mar 27 12:48 : exception: nested: Failed to open ALSA device "hw:0,0": No such file or directory No I2S audio DAC has the following in the Audio info: Decoded to: 0 bps Destination: Local Output rate: 0 bps DSP operations Volume ctl: Disabled (100% volume is output by MPD) Resampling: 24 bit, 192 kHz, Stereo (SoX very high quality) Polarity inv: off Crossfade: off Crossfeed: off Parametric EQ: off Graphic EQ: off Replaygain: off Normalize vol: off Chip options: None Audio Device Device: On-board audio device Chip: Broadcom SoC Interface: SOC Formats: U8, S16_LE Platform: Pi-3B 1GB v1.2 When I add Hifiberry DAC+ Pro I get the following changes in audio info: Chip options: FIR interpolation with de-emphasis, Gain=0dB, Boost=0dB Audio Device Device: HiFiBerry DAC+ Pro Chip: Burr Brown PCM5122 Interface: I2S Formats: cat: /proc/asound/card0/pcm0p/sub0/hw_params: No such file or directory pi@moode:/var/log/mpd $ dmesg | grep hifiberry [ 6.816423] snd-rpi-hifiberry-dacplus soc ![]() [ 6.824268] snd-rpi-hifiberry-dacplus soc ![]() pi@moode:/var/log/mpd $ lsmod | grep hifi snd_soc_hifiberry_dacplus 16384 0 snd_soc_core 192512 3 snd_soc_pcm512x,snd_soc_hifiberry_dacplus,snd_soc_bcm2835_i2s snd_pcm 102400 5 snd_soc_pcm512x,snd_pcm_dmaengine,snd_soc_hifiberry_dacplus,snd_soc_bcm2835_i2s,snd_soc_core clk_hifiberry_dacpro 16384 0 pi@moode:/var/log/mpd $ sudo aplay -l aplay: device_list:272: no soundcards found... RE: Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - DRONE7 - 03-27-2020 How topical...I have just fixed this on my HiFiBerry Digi+ Pro.... Firstly..try removing and reattaching the hiFiBerry HAT. If that does not work then... Ymmv but I am guessing there were several boards/batches that were not solder-flowed correctly... My digi worked intermittently when first attached to the Pi....then not at all when removed and reattached... throwing exactly the error you are facing... If you ssh in and try running.. Code: alsamixer you'll find a 'file not found' error. So... if you have a multimeter , with the Pi running and HAT attached, measure the 5v point on the Hat's 40 pin connector and then on the duplicate holes next to the 40 pin connector... mine was 5v on the first and 1.7v on the other... (on the un-powered board I measured 23R between those pins..once reflowed it was unity) I removed the HAT and re-flowed the solder connection for both 5v pins on the main 40 pin connector on the HAT.... took several attempts each with a more sustained soldering... I am thinking the multi-layered board has not been fully joined ex factory.... Remeasured and both measuring points showed 5v Rebooted...all errors gone and board played normally. Used some Fry's flux to enable the through-hole flow....again ymmv. Cheers, Bob. (yes Mr Fry does look like the 'Pointy-haired Boss from the Dilbert cartoons' Lol Alternative... if you're not confident/experienced with electronics then contact HiFiBerry and report a fault....especially if you're within the warranty. This is an unacceptable manufacturing fault and should be covered even if out of warranty. Note that there is a method to backup from within MoOde...only I can't remember how it goes.... ![]() However... the RPI version works too....scroll down to 'SD card image' and use that. https://www.raspberrypi.org/documentation/linux/filesystem/backup.md RE: Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - gwurb - 03-29-2020 Thanks for that! I have tried the remove/re-attach a few times now. No success. Running the commands: pi@moode:~ $ alsamixer cannot open mixer: No such file or directory pi@moode:~ $ sudo alsamixer cannot open mixer: No such file or directory pi@moode:~ $ amixer amixer: Mixer attach default error: No such file or directory pi@moode:~ $ sudo apt-get install alsa-utils Reading package lists... Done Building dependency tree Reading state information... Done alsa-utils is already the newest version (1.1.8-2). alsa-utils set to manually installed. 0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded. There definitely is a problem. I took voltage measurements and they are fine. There is 0.6Ohm resistance between the different ground pins and the voltage pins but that could just be my multimeter. I'll try flashing a different card with moode and seeing if a 'fresh' install makes a difference. If not then I think I think its contacting Hifiberry. RE: Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - Tim Curtis - 03-29-2020 Burn a fresh, stock moOde image onto a known good SDcard and then boot up your Pi without any HAT or other device connected. Verify that moOde works in this default configuration by examining the Moode log and confirming that there are no errors. moodeutl -l After connecting your HAT board and configuring it correctly in Audio config then rebooting, if you get errors like "Failed to open ALSA device "hw:0,0": No such file or directory" then it would suggest a bad HAT board. RE: Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - gwurb - 03-29-2020 I flashed a new card. For the new setup I only set: I2S audio device MPD config (only a couple of options) I can play sound and alsamixer command works. The problem may be moode... Would anyone want to help me troubleshoot my old install? It would be good to find the issue and iron it out. RE: Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - gwurb - 03-29-2020 (03-29-2020, 02:59 AM)Tim Curtis Wrote: Burn a fresh, stock moOde image onto a known good SDcard and then boot up your Pi without any HAT or other device connected. Verify that moOde works in this default configuration by examining the Moode log and confirming that there are no errors. Oops, I didn't see this post before flashing. I didn't do the initial boot without the HAT. Things are working right now and moodeutl -l shows no errors. I am going to change one setting at a time to my previous setup and check playback and moodeutl -l at every step. If I don't find something then I'm back to asking for assistance with troubleshooting. Will post again after putting in place my settings. RE: Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - gwurb - 03-29-2020 I think I am back to the config that I had before. I write I think because I have not done an A to B comparison, just went off memory. I can play the stereo test and can play an internet radio station. Here is an output from moodeutl -l : pi@moode:~ $ moodeutl -l 20200329 144154 worker: -- Start 20200329 144154 worker: Successfully daemonized 20200329 144154 worker: Integrity check (passed) 20200329 144154 worker: Session loaded 20200329 144154 worker: Debug logging (off) 20200329 144154 worker: Device raw: (0 ![]() 20200329 144154 worker: Device cfg: (HiFiBerry DAC+ Pro|0|0|Digital|0) 20200329 144155 worker: ALSA volume set to (0%) 20200329 144155 worker: -- System 20200329 144157 worker: Host name (moode) 20200329 144157 worker: moOde release (6.4.2 2020-02-12) 20200329 144157 worker: Raspbian OS (10.2) 20200329 144157 worker: Linux kernel (4.19.97-v7+ #1293) 20200329 144157 worker: Platform (Pi-3B 1GB v1.2) 20200329 144157 worker: Architecture (armv7l) 20200329 144157 worker: MPD version (0.21.16) 20200329 144157 worker: CPU governor (ondemand) 20200329 144157 worker: USB boot enabled 20200329 144157 worker: File system not expanded yet 20200329 144157 engine-mpd: Connection to MPD failed 20200329 144157 worker: HDMI port on 20200329 144158 worker: File check (OK) 20200329 144158 worker: -- Network 20200329 144158 worker: eth0 exists 20200329 144158 worker: IP addr (192.168.1.21) 20200329 144158 worker: Netmask (255.255.255.0) 20200329 144158 worker: Gateway (192.168.1.1) 20200329 144158 worker: Pri DNS (203.0.178.191) 20200329 144158 worker: Domain (192.168.1.1) 20200329 144158 worker: wlan0 exists 20200329 144158 worker: wifi country (AU) 20200329 144158 worker: wlan0 SSID is blank 20200329 144158 worker: eth0 addr exists, AP mode not started 20200329 144158 worker: wlan0 address not assigned 20200329 144159 worker: -- Audio 20200329 144159 worker: ALSA outputs unmuted 20200329 144159 worker: ALSA card number (0) 20200329 144159 worker: Audio output (I2S audio device) 20200329 144159 worker: Audio device (HiFiBerry DAC+ Pro) 20200329 144159 worker: Audio formats (S16_LE, S24_LE, S32_LE) 20200329 144159 worker: ALSA mixer name (Digital) 20200329 144159 worker: MPD volume control (disabled) 20200329 144159 worker: Hdwr volume controller exists 20200329 144159 worker: Max ALSA volume (100%) 20200329 144159 worker: -- Services 20200329 144159 worker: Reset renderer active state 20200329 144200 worker: MPD conf updated 20200329 144200 worker: MPD started 20200329 144201 worker: MPD accepting connections 20200329 144201 worker: Configure MPD outputs 20200329 144201 worker: MPD output 1 ALSA default (on) 20200329 144201 worker: MPD output 2 ALSA crossfeed (off) 20200329 144201 worker: MPD output 3 ALSA parametric eq (off) 20200329 144201 worker: MPD output 4 ALSA graphic eq (off) 20200329 144201 worker: MPD output 5 ALSA polarity inversion (off) 20200329 144201 worker: MPD output 6 ALSA bluetooth (off) 20200329 144201 worker: MPD output 7 HTTP stream (off) 20200329 144201 worker: MPD crossfade (off) 20200329 144201 worker: Audio source (Local) 20200329 144201 worker: Output device (Local) 20200329 144201 worker: Airplay receiver started 20200329 144201 worker: UPnP renderer started 20200329 144202 worker: DLNA server started 20200329 144202 worker: Bluetooth controller started 20200329 144202 worker: Bluetooth controller initialized 20200329 144202 worker: Bluetooth pairing agent started 20200329 144202 worker: LCD updater engine started 20200329 144203 worker: Shellinabox SSH started 20200329 144203 worker: USB auto-mounter (udisks-glue) 20200329 144203 worker: -- Music sources 20200329 144203 worker: USB sources (none attached) 20200329 144203 worker: NAS and UPnP sources (none configured) 20200329 144203 worker: -- Miscellaneous 20200329 144203 worker: Saved MPD vol level (0) 20200329 144203 worker: Preamp volume level (0) 20200329 144203 worker: MPD volume level (0) restored 20200329 144203 worker: ALSA volume level (100%) 20200329 144203 worker: Auto-play (Off) 20200329 144203 worker: LocalUI started 20200329 144203 worker: Auto-shuffle service (Off) 20200329 144203 worker: Maintenance interval (3 hrs) 20200329 144203 worker: Screen saver activation (Never) 20200329 144203 worker: Session permissions (OK) 20200329 144203 worker: Watchdog started 20200329 144203 worker: Ready 20200329 144206 worker: Job mpdcfg There is one error: 20200329 144157 engine-mpd: Connection to MPD failed I only saw that after changing SoX resampling but that seems strange. So what's the next step in figuring out what went wrong with the previous image? Or its best to wait and see if everything works ok with the new one and not bother trying to track down the previous problem? RE: Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - CallMeMike - 03-29-2020 (03-29-2020, 03:50 AM)gwurb Wrote: I think I am back to the config that I had before. I write I think because I have not done an A to B comparison, just went off memory. I can play the stereo test and can play an internet radio station. Here is an output from moodeutl -l : What is the point of a troubleshooting in a (very possible) case of a corrupt image...!? You got a new build on a different card, configure the image to your heart's content (but do small steps between repeated tests) and when you're finished with the configuration give it a good test and THEN clone/backup the new MoOde uSD card. If one is heavily re-configuring their MoOde build one ought to provision for a backup solution... All the above will not be a good effort unless you are using a quality uSD card... ![]() RE: Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - gwurb - 03-29-2020 It seems that the newly flashed image is having problems too. I've also tried a different Pi and that is also having problems. The cards are sandisk. Are there issues with sandisk and raspberry pi? Lastly I tried Hifiberry OS and I didn't get any errors but I didn't get any audio output either. I've sent a support request to Hifiberry. There may be an issue with the HAT but I am not sure what else I can measure other than supply voltage. RE: Failed to open "ALSA default" (alsa); Failed to open ALSA device "hw:0,0" - TookaFace - 03-29-2020 Yeah, those problems are probably the result of a bad SD CARD or an end of life SDCARD. It was my case, i had those mpd error msg with my old sd card. Could also be a bad power supply who corrupt sdcard. |