# Alc888



## marudov (Jul 10, 2009)

Hi everybody!

  I can not get the HDMI audio to work on my PC.

Here is some information about my sound card: 

```
[root@media ~]# cat /dev/sndstat
FreeBSD Audio Driver (newpcm: 64bit 2007061600/amd64)
Installed devices:
pcm0: <HDA Realtek ALC888 PCM #0 Analog> at cad 0 nid 1 on hdac0  [MPSAFE] (1p:1v/1r:1v channels duplex default)
pcm1: <HDA Realtek ALC888 PCM #1 Analog> at cad 0 nid 1 on hdac0  [MPSAFE] (1p:1v/1r:1v channels duplex)
pcm2: <HDA Realtek ALC888 PCM #2 Digital> at cad 0 nid 1 on hdac0  [MPSAFE] (1p:1v/0r:0v channels)
pcm3: <HDA Realtek ALC888 PCM #3 Digital> at cad 0 nid 1 on hdac0  [MPSAFE] (1p:1v/0r:0v channels)
pcm4: <HDA Intel G45 HDMI PCM #0 Digital> at cad 1 nid 1 on hdac0  [MPSAFE] (1p:1v/0r:0v channels)
```
More info :

```
[root@media ~]# sysctl -a | grep snd
hw.snd.latency_profile: 1
hw.snd.latency: 5
hw.snd.report_soft_formats: 1
hw.snd.compat_linux_mmap: 0
hw.snd.feeder_buffersize: 16384
hw.snd.feeder_rate_round: 25
hw.snd.feeder_rate_max: 2016000
hw.snd.feeder_rate_min: 1
hw.snd.verbose: 1
hw.snd.maxautovchans: 16
hw.snd.default_unit: 4
hw.snd.version: 2007061600/amd64
hw.snd.default_auto: 0
```

When I play an mp3 file I get the following error in my messages : 


```
[root@media ~]# dmesg | tail -2
drm0: [ITHREAD]
hdac0: timeout in reset
```

and I cant hear any sound.

Any ideas ?


----------



## marudov (Jul 11, 2009)

The sound works perfectly through the sound card stereo jack, when I set hw.snd.default_unit to 0

But when I set the default unit to 4   / pcm4: <HDA Intel G45 HDMI PCM #0 Digital> at cad 1 nid 1 on hdac0  [MPSAFE] (1p:1v/0r:0v channels)/ the sound disappears.

Can someone provide me with some directions what to check?


----------



## mav@ (Nov 12, 2009)

Most of HDA controllers unable to support more then 4 audio streams. You have 5 audio devices. Disable any of them and timeouts will go away. Still I was unable to get HDMI playing audio on G41 chipset, so report if you succeed.


----------



## Defre (Dec 22, 2009)

Hi, I have the same chipset.
Here is my sndstat:

```
# cat /dev/sndstat 
FreeBSD Audio Driver (newpcm: 64bit 2009061500/amd64)
Installed devices:
pcm0: <HDA ATI R6xx HDMI PCM #0 HDMI> at cad 0 nid 1 on hdac0 kld snd_hda [MPSAFE] (1p:1v/0r:0v channels simplex default)
pcm1: <HDA Realtek ALC888 PCM #0 Analog> at cad 0 nid 1 on hdac1 kld snd_hda [MPSAFE] (1p:5v/1r:5v channels duplex)
pcm2: <HDA Realtek ALC888 PCM #1 Analog> at cad 0 nid 1 on hdac1 kld snd_hda [MPSAFE] (1p:1v/0r:0v channels simplex)
pcm3: <HDA Realtek ALC888 PCM #2 Analog> at cad 0 nid 1 on hdac1 kld snd_hda [MPSAFE] (1p:1v/0r:0v channels simplex)
pcm4: <HDA Realtek ALC888 PCM #3 Digital> at cad 0 nid 1 on hdac1 kld snd_hda [MPSAFE] (1p:1v/0r:0v channels simplex)
pcm5: <HDA Realtek ALC888 PCM #4 Analog> at cad 0 nid 1 on hdac1 kld snd_hda [MPSAFE] (1p:1v/0r:0v channels simplex)
```

ALC888 is mapped from pcm1 to pcm5. Stereo sound work well.
PCM devices are wired the following way:
- pcm1 is headphone out
- pcm2 is surround bass and center
- pcm3 is surround fronts
- pcm5 is surround rears.

So I can play nice sound on pcm3... However volume is quite low unless I play sound on pcm2 and pcm3 simultaneously (didn't try pcm5, but should work the same way ?!).
Therefore I wan't to setup a route from "a virtual 5.1 device" to corresponding pcms, eventually upmixing stereo input.
Well, sounds like a good idea... But I don't have any idea how to do that! (I read the sound setup handbook section though).

Thx


----------

