[alsa-devel] stac9200 speaker/hp not detected

Takashi Iwai tiwai at suse.de
Mon Jul 9 14:30:49 CEST 2007


At Sun, 08 Jul 2007 12:54:54 -0400,
Brian Hinz wrote:
> 
> OK, after a few days of familiarizing myself with the hda and stac9200 
> specs, I think I see what's going on.  I tossed out the pin config settings 
> from the windows driver and simply derived a set based on the stac9200 
> datasheet and my best guesses as to how the hardware is actually configured. 
>   At this point, dmesg shows:
> 
> line_outs=0 (0x0/0x0/0x0/0x0/0x0)
> speaker_outs=1 (0xe/0x0/0x0/0x0/0x0)
> hp_outs=1 (0xd/0x0/0x0/0x0/0x0)
> inputs: mic=0x10, fmic=0x0, line=0x0, fline=0x0, cd=0x0, aux=0x0
> 
> which corresponds at least to the number of external ports. Still no sound, 
> BUT, /proc/asound/card0/codec#0 shows something interesting (heh, actually 
> it's shown it all along, ignorance is bliss I guess...):
> 
> ...
> Node 0x08 [Pin Complex] wcaps 0x430681: Stereo Digital
>   Pincap 0x0810024: IN EAPD Detect
>   Pin Default 0x40c001fd: [N/A] SPDIF In at Ext N/A
>     Conn = Unknown, Color = Unknown
>   Pin-ctls: 0x00:
>   Power: 0x0
> ...
> 
> the DigInPin is showing EAPD control.  I wasn't sure about the meaning of 
> the "Power: 0x0" line in /proc/asound/card0/codec#0 so I put some debug 
> statements into patch_sigmatel.c to dump the DigInPin power state and EAPD 
> registers:
> 
> [ 5701.644000] hda_codec: DigInPin PwrState: 00000033

Hm, how can it be?  The proc file shows it's 0 (= all power-on), and
you see a different value?

> [ 5701.644000] hda_codec: EAPD Config: 00000000
> 
> According to the stac9200 datasheet, a PwrState of 0x3 means that the node 
> is powered down.  A value of 0 on the EAPD pin means power down the external 
> amp, and a 1 means power up the amp if PwrState is < 0x2. If PwrState >= 
> 0x2, Pin47 is tri-stated.  And Pin47 is ... GPIO3 (AKA: SPDIF_IN,  EAPD)!  
> The stac9200 datasheet also states that "an external pull-down is required 
> if EAPD must be low when Pin Widget is powered down."

I'm a bit skeptical about this relation.  SPDIF-IN was used for the
EAPD control on many boards with ac97 codecs, but EAPD is usually
controlled via AC_VERB_SET_EAPD_BTLENABLE verb to the specific pin
widget on HD-audio codecs.  GPIO may be required for some weird
setting, but it's nowhere defined in the datasheet.

BTW, how did you find out that the HP pin is 0x0d and the speaker is
0x0e?


Takashi


More information about the Alsa-devel mailing list