All of lore.kernel.org
 help / color / mirror / Atom feed
From: James Courtier-Dutton <James@superbug.demon.co.uk>
To: Takashi Iwai <tiwai@suse.de>
Cc: alsa-devel@lists.sourceforge.net
Subject: Re: SIS7012 SPDIF support
Date: Fri, 06 Jun 2003 02:20:05 +0100	[thread overview]
Message-ID: <3EDFEC45.6010908@superbug.demon.co.uk> (raw)
In-Reply-To: <s5hisrnnype.wl@alsa2.suse.de>

[-- Attachment #1: Type: text/plain, Size: 1362 bytes --]

Takashi Iwai wrote:
> 
> 
> thanks.   looking at the codes, it seems that no special handling for
> the chip.  it simply sets up the ac97 registers.
> 
> the patch below is a quick hack to set the spdif rate on the first
> playback pcm device.  in addition, you'll need to set up the following
> mixer controls:
> 
> - 'IEC958 AC97-SPSA' to 0 (slots 3/4).
> - 'IEC958 Playback Switch' to on.
> 
> you might need to set up 'IEC958 Playback Default', too, but it might
> not...  try once the above two switches at first.
> 
> 
> Takashi

I have done some further investigation, and have discovered the type of 
ac97 chip used.
I attach output from the ac97#0regs /proc/asound/card0 file.
Here is the url to download datasheets of the chip.
It is an ALC650 Chip.
http://www.realtek.com.tw/downloads/downloads1-3.aspx?lineid=5&famid=All&series=8&refdesign=True

 From my analysis, I think that we should be setting bit 2 of register 
0x2a to get SPDIF out.
Is it possible to set this via alsamixer, or do I now have to open the 
device with a particular name, e.g. 
iec958:AES0=0x6,AES1=0x82,AES2=0x0,AES3=0x2

The chip can set non-audio bits etc, so we should really be able to 
support opening with the iec958:...etc. name.

If you think I am on the right lines here, then what functions do we 
have to add to get it to parse iec958 lines correctly.

Cheers
James

[-- Attachment #2: ac97-regs --]
[-- Type: text/plain, Size: 768 bytes --]

0:00 = 5980
0:02 = 9f1f
0:04 = 0000
0:06 = 801f
0:08 = 0000
0:0a = 801e
0:0c = 801f
0:0e = 801f
0:10 = 9f1f
0:12 = 9f1f
0:14 = 9f1f
0:16 = 9f1f
0:18 = 9f1f
0:1a = 0000
0:1c = 0000
0:1e = 0000
0:20 = 0000
0:22 = 0000
0:24 = 0000
0:26 = 000f
0:28 = 05c7
0:2a = 05c1
0:2c = bb80
0:2e = bb80
0:30 = bb80
0:32 = bb80
0:34 = 0000
0:36 = 9f80
0:38 = 9f9f
0:3a = 2000
0:3c = 0000
0:3e = 0000
0:40 = 0000
0:42 = 0000
0:44 = 0000
0:46 = 0000
0:48 = 0000
0:4a = 0000
0:4c = 0000
0:4e = 0000
0:50 = 0000
0:52 = 0000
0:54 = 0000
0:56 = 0000
0:58 = 0000
0:5a = 0000
0:5c = 0000
0:5e = 0000
0:60 = 0000
0:62 = 0000
0:64 = 0808
0:66 = 0808
0:68 = 0000
0:6a = 0000
0:6c = 0000
0:6e = 0014
0:70 = 0211
0:72 = 00a0
0:74 = 0043
0:76 = 0001
0:78 = 0102
0:7a = 57c6
0:7c = 414c
0:7e = 4720

  reply	other threads:[~2003-06-06  1:20 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-06-02 16:01 SIS7012 SPDIF support James Courtier-Dutton
2003-06-02 18:42 ` Jaroslav Kysela
2003-06-03  9:55 ` Takashi Iwai
2003-06-03 11:24   ` James Courtier-Dutton
2003-06-03 12:16     ` Takashi Iwai
2003-06-06  1:20       ` James Courtier-Dutton [this message]
2003-06-06  9:03         ` Takashi Iwai
2003-06-06 21:18           ` James Courtier-Dutton
2003-06-04  9:11   ` build changes Giuliano Pochini
2003-06-04 11:40     ` Jaroslav Kysela
2003-06-04 15:57       ` Giuliano Pochini
2003-06-04 17:17         ` Takashi Iwai
2003-06-07  0:38           ` Giuliano Pochini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3EDFEC45.6010908@superbug.demon.co.uk \
    --to=james@superbug.demon.co.uk \
    --cc=alsa-devel@lists.sourceforge.net \
    --cc=tiwai@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.