Navigatrix.net - A Voyager's Companion
http://navigatrix.net/

Sound not working on Asus notebook
http://navigatrix.net/viewtopic.php?f=6&t=394
Page 1 of 1

Author:  Markus [ 18 Jun 2013, 05:38 ]
Post subject:  Sound not working on Asus notebook

Bula Captain -

We have a (relatively new, ~2011) Asus notebook with NX here in the anchorage on which the driver for the sound card does not seem to work. There is simply no sound coming from any sound file/sound emitting application, no matter what the volume / mixer settings are. When trying to run "sudo alsaconf" from the command line, the process gets stuck at "building card database...".

Any suggestions to fix this are welcome. Is there some driver that has been known to have caused trouble in the past and if so - is there a way to black-list it?

Many thanks,
Markus

Author:  Moe [ 18 Jun 2013, 09:52 ]
Post subject:  Re: Sound not working on Asus notebook

I'm not sure Markus. I do remember a bug in Ubuntu with some netbooks having a sound problem. The machine would create two mic inputs and fail until one (as I recall it didn't matter which one) was muted. Give that a looksee first.

Then let's find what sort of soundcard it is and go from there....

See if
Code:
cat /proc/asound/cards
gives us anything useful; like what soundcard it thinks is there.

aplay is a barebones media media player/recorder that works when other fail. That is to say if aplay doesn't make or record a sound nothing else will. It also has some info gathering to help diagnose the problem;
Code:
aplay -l
will also list the device it thinks is there and that all other applications are attempting to connect to by default.

And then
Code:
lspci -vv | grep -i -A10 audio
for a very vocal reply of what is actually there...and when that is all said and done we'll look up the vendor and product number to see what module really should be there to make it all work....all of the playback mutes are off, right?
Code:
amixer set Master unmute
amixer set Front unmute
amixer set Headphone unmute
amixer set PCM unmute
...just in case.

I also just read about Alsa Auto-mute which is news to me. I don't know what it is; how it works; or if it's even real. But,
Code:
amixer -c 0 sset "Auto-Mute Mode" Disabled
...if it's not real then we've spent 20 seconds on an education that makes us wiser, but gets us no where....much like a 4 year degree in Philosophy, but cheaper and quicker.
A quick test...
Code:
aplay /usr/local/share/opencpn/sounds/collision555.wav
Let me know.

Author:  Markus [ 19 Jun 2013, 03:26 ]
Post subject:  Re: Sound not working on Asus notebook

Many thanks for the quick response Moe. I double checked everything was unmuted and there was only one mic input. Here's what those commands produced in output:

Code:
victoria@victoria-laptop:~$ cat /proc/asound/cards

 0 [Generic        ]: HDA-Intel - HD-Audio Generic
                      HD-Audio Generic at 0xfeb44000 irq 45
 1 [SB             ]: HDA-Intel - HDA ATI SB
                      HDA ATI SB at 0xfeb40000 irq 16

------------------------------------------------------------------------------------------------------------

victoria@victoria-laptop:~$ aplay -l

**** List of PLAYBACK Hardware Devices ****
card 0: Generic [HD-Audio Generic], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: SB [HDA ATI SB], device 0: ALC269VB Analog [ALC269VB Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

------------------------------------------------------------------------------------------------------------

victoria@victoria-laptop:~$ lspci -vv | grep -i -A10 audio

00:01.1 Audio device: ATI Technologies Inc Device 1314
   Subsystem: ASUSTeK Computer Inc. Device 103b
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
   Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
   Latency: 0, Cache Line Size: 64 bytes
   Interrupt: pin B routed to IRQ 45
   Region 0: Memory at feb44000 (32-bit, non-prefetchable) [size=16K]
   Capabilities: <access denied>
   Kernel driver in use: HDA Intel
   Kernel modules: snd-hda-intel

--
00:14.2 Audio device: ATI Technologies Inc SBx00 Azalia (Intel HDA) (rev 40)
   Subsystem: ASUSTeK Computer Inc. Device 103b
   Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx-
   Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=slow >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
   Latency: 32, Cache Line Size: 64 bytes
   Interrupt: pin A routed to IRQ 16
   Region 0: Memory at feb40000 (64-bit, non-prefetchable) [size=16K]
   Capabilities: <access denied>
   Kernel driver in use: HDA Intel
   Kernel modules: snd-hda-intel


In addition, when I open the Gnome ALSA Mixer, I see two tabs:

(1) ATI R6XX HDMI: empty / no controls or audio channels shown, but with the IEC958 box checked

(2) Realtek ALC269VB; shows all the input/output channels and controls

However, the ALSA Mixer on my own computer similarly shows an empty tab for ATI (in this case ATI 690/780 HDMI) and full controls on the Realtek tab (in this case ALC 271X) and sound works fine.

Does any of this ring a bell?

Thanks again,
Markus

Author:  Moe [ 19 Jun 2013, 06:59 ]
Post subject:  Re: Sound not working on Asus notebook

The first (card0) is the audio device connected to the HDMI port of the on-board graphics device; the second (card1) is the main audio device.

I'll bet if you hook that machine up with a HDMI cable to the 55 inch flat screen in the salon something would come out.

Until then, or until I can get back, open up alsamixer and then hit <F6> to change to the second device (card1).

If it's not listed enter device name and enter the device name. Alsa uses a crazy notation hw(0,1)...or something like that...you might know, but I need to look it up. The syntax makes my head spin.

...or was this the place that was hanging?

Ah, regardless, I need to do some research and get back to after a little sleep.

Author:  Moe [ 19 Jun 2013, 07:12 ]
Post subject:  Re: Sound not working on Asus notebook

Try this:

Create a file /etc/asound.conf containing:

Code:
pcm.!default {
   type hw
   card 1
}
ctl.!default {
   type hw
   card 1
}
Save and reboot.

Author:  Markus [ 21 Jun 2013, 03:45 ]
Post subject:  Re: Sound not working on Asus notebook

Just back from the Victorias who say "hello" and a big "thank you"... it seems we're *almost* there...

With the F6 in alsamixer and the asound.conf above the volume control now appears in the little LXDE system panel and we can play mp3 files in audacious. However, trying to play a *.wav file in audacious results in an error "ALSA Error: snd_pcm_hw_params_set_channels failed: invalid argument". Also, when trying to start Lingot (SW guitar tuner that uses built-in mic for input) it fails with a message "no such device: /dev/dsp". Lingot works fine on my installation of NX. No clue if these two errors are in any way related.

Searching for "missing /dev/dsp" brings up some hits that suggest an additional kernel module (snd-pcm-oss) may need to be loaded but I will only be able to try this tomorrow. I'm still puzzled though, because it works fine on my computer (without loading additional modules).

Aside from that we're busy with moving the grand piano out of the salon so we can fit that 55in flat-screen in here...

Author:  Moe [ 21 Jun 2013, 09:35 ]
Post subject:  Re: Sound not working on Asus notebook

...I never liked *.wav files. I don't know why...<deleted 20 minutes of fruitless introspection>...just because.

So, the command aplay /usr/local/share/opencpn/sounds/collision555.wav produced diddly?

How'bout
Code:
aplay -D hw:1,0  /usr/local/share/opencpn/sounds/collision555.wav
This machine wants..it aches, to pump digital sound and video to a big flat screen. We need to convince it to squeak it out through the in-built speakers with -D(use Device) hw:1,0 (to access the first device on the second soundcard/device [editorial note: I'm quoting this from the computer science guys who, evidently took a different counting course than I did]). This should be the (ho-hum) regular screen/speakers.

Do you hear an alarming sound from a disagreeable format?

What about:
Code:
speaker-test -D hw:1,0 -c 2 -t wav
(...similar to the first one, and bypasses asound.conf) a two channel wave test on the however they count card/device?
...nothing? Swap out the -D hw:1,0(card 1: SB [HDA ATI SB], device 0) and go back to the 'main' card with -D hw:0,3 (card 0: Generic [HD-Audio Generic], device 3).

Also test if it's just the wav format that causing trouble by swapping out -t wav with -t sine.

...I've always liked the name 'Victoria'...so I'll keep on trying as long as you're willing. I'll install Lingot to see what is going on there even though I have no musical ability what so ever; and get back to you on that error.

Author:  Moe [ 21 Jun 2013, 10:32 ]
Post subject:  Re: Sound not working on Asus notebook

I'll also add the folks at ALSA mention this in the asound.conf file
Quote:
dmix

These days we have a native plugin for ALSA called the dmix (direct mixing) plugin. It allows software mixing in an easy to use syntax and without the hassle of installing/understanding a new application first.

A very interesting and potentially extremely useful aspect of this plugin is using it combined with the default plugin name. In theory this means all applications that have native ALSA support will share the sound device. In practice not many applications are able to take advantage of this functionality yet. However if you have time to test and report your findings to the application developers it is worth a try:

They include this code... Depending on if you feel like a guinea pig...here ya' go. I've not given it any thought to card/device numbering...i.e., making 1 a slave of 0...or the other way around. Or haven't thought about the implications of the previous construction of asound.conf.
Code:
pcm.!default {
   type plug
   slave.pcm "dmixer"
}

pcm.dmixer  {
    type dmix
    ipc_key 1024
    slave {
      pcm "hw:1,0"
      period_time 0
      period_size 1024
      buffer_size 4096
      rate 44100
   }
   bindings {
      0 0
      1 1
   }
}

ctl.dmixer {
   type hw
   card 0
}
I'll think about it in the morning.

Author:  Moe [ 22 Jun 2013, 08:24 ]
Post subject:  Re: Sound not working on Asus notebook

The third line of the ~/.lingot/lingot.conf points to the audio device
Code:
# Config file automatically created by lingot

AUDIO_DEV = /dev/dsp
...now, just gotta figure where that is on Victoria's machine.

I'll keep digging. (it's winter; cold, dark and wet. What else am I going to do?)

Author:  Moe [ 22 Jun 2013, 08:31 ]
Post subject:  Re: Sound not working on Asus notebook

Oh, what model laptop is this?...a ASUS N53Jq?...a 1215T?...UX31A? an EeePc?....K42JC?...I'll keep guessing.

Author:  Markus [ 24 Jun 2013, 14:55 ]
Post subject:  Re: Sound not working on Asus notebook

Wow - many thanks! I'll see the Victorias again this afternoon and will get laptop model and results of the test above. After tomorrow we'll probably loose internet connectivity for about two weeks but I hope to have the info back before that.

Author:  Markus [ 24 Jun 2013, 15:05 ]
Post subject:  Re: Sound not working on Asus notebook

Found the laptop model in my notes: ASUS 1225B

Author:  Moe [ 24 Jun 2013, 21:25 ]
Post subject:  Re: Sound not working on Asus notebook

Could it be so simple?

This from Gentoo on their wiki page regarding the Ausu 1225B

This is the part that makes me think this is on the right track
Quote:
There is a problem that actually ALSA often sees two sound cards: HD-Audio Generic (that is a kind of a virtual device, i.e. it doesn't actually play music) and the required HDA ATI SB. The simplest way to check it is to launch
user $ aplay -l**** List of PLAYBACK Hardware Devices ****

card 0: Generic [HD-Audio Generic], device 3: HDMI 0 [HDMI 0]

Subdevices: 1/1
Subdevice #0: subdevice #0

card 1: SB [HDA ATI SB], device 0: ALC269VB Analog [ALC269VB Analog]

Suvdevices: 1/1

Subdevice #0: subdevice #0

If HD-Audio Generic is the first number, it might be the default card. If it is the case, than you're likely to have no sound unless the default card is switched from 0 to 1.

File/etc/asound.conf
Code:
defaults.ctl.card 1
defaults.pcm.card 1
defaults.timer.card 1
It is possible that if we un-did the damage we did before...that is, just had those 3 lines in /etc/asound.conf everything, including .wav, will be switched to the proper card/device. The plumbing for /dev/dsp should be in place so lingot should...should pick up. I'll search for confirmation of that hypothesis, but wanted to get this posted before you went off.

...and obviously those lines in /etc/asound.conf should be commented out when she connects to the flatscreen in the salon.

Author:  Moe [ 24 Jun 2013, 23:46 ]
Post subject:  Re: Sound not working on Asus notebook

There is some disagreement if you should use /dev/dsp or /dev/audio in the lingot config.

I suggest using the one that works.

Author:  Markus [ 25 Jun 2013, 01:41 ]
Post subject:  Re: Sound not working on Asus notebook

Brilliant - that does it! Scary sounds in disagreeable formats all around... the Victorias will supply you with an allotment of VBs once they make it to Australia.

lingot is also working now, after having the the config file point to /dev/dsp1 which was lurking somewhere in the shadows. Now that lingot is running, we're temporarily moving the piano back into the salon so we can re-tune it. Flatscreen update to follow...

Author:  Moe [ 25 Jun 2013, 01:50 ]
Post subject:  Re: Sound not working on Asus notebook

Cool. Well done finding (and trying) /dev/dsp1.

Enjoy your weeks away from the intertubes.

Page 1 of 1 All times are UTC - 5 hours
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/