All of lore.kernel.org
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: Jochen Voss <voss@seehuhn.de>
Cc: alsa-devel@lists.sourceforge.net
Subject: Re: [RFC] Add dB scale information to AK4xxx codec
Date: Fri, 08 Sep 2006 12:32:33 +0200	[thread overview]
Message-ID: <s5hr6ymd4xq.wl%tiwai@suse.de> (raw)
In-Reply-To: <20060907221844.GA7188@tarte.seehuhn.de>

At Thu, 7 Sep 2006 23:18:45 +0100,
Jochen Voss wrote:
> 
> Hi Takashi,
> 
> On Thu, Sep 07, 2006 at 04:52:58PM +0200, Takashi Iwai wrote:
> > I confirmed that the same behavior appears on AK4524.
> > So, it makes much more sense to combine ADC and IPGA controls to a
> > single control.
> Great, this should simplify things considerably.
> 
> > The patch below is the final version I have on my local tree.
> > Please check whether it works for you.
> It works nice.  I now get
> 
>     Simple mixer control 'PCM',0
>       Capabilities: pvolume cvolume cswitch cswitch-joined
>       Playback channels: Front Left - Front Right
>       Capture channels: Front Left - Front Right
>       Limits: Playback 0 - 127 Capture 0 - 151
>       Front Left: Playback 127 [100%] Capture 0 [0%] [on]
>       Front Right: Playback 127 [100%] Capture 151 [100%] [on]
> 
> One remaining problem: Unfortunatly left and right volume are
> exchanged when recording.  When I record with the setting above (using
> arecord) and then replay the recording with aplay all the sound comes
> from the left (!)  speaker.
> 
> I reactivated my register write spying patch and got
> 
>     reg4 <- 00
>     reg5 <- 98
> 
> for the setting above.  So the actual register writes seem to be ok.
> It seems that register 5 corresponds to the left channel (and 4 to the
> right channel) on the revolution 5.1 card.

Hm, this is a bit weird.  Could you double-check this?


> Otherwise everything seems fine.

OK, I committed the patch to ALSA HG tree now.


> Minor nit: the code (from ak4xxx-adda.c)
> 
> 		/* register 4 & 5 */
> 		if (ak->type == SND_AK5365)
> 			knew.private_value =
> 				AK_COMPOSE(idx/2, (idx%2) + 4, 0, 151) |
> 				AK_VOL_CVT | AK_IPGA;
> 		else
> 			knew.private_value =
> 				AK_COMPOSE(idx/2, (idx%2) + 4, 0, 163) |
> 				AK_VOL_CVT | AK_IPGA;
> 
> looks unnecessarily complicated.  The AK5365 has just two channels, so
> shouldn't it be just as follows?
> 
> 		/* register 4 & 5 */
> 		if (ak->type == SND_AK5365)
> 			knew.private_value =
> 				AK_COMPOSE(0, idx + 4, 0, 151) |
> 				AK_VOL_CVT | AK_IPGA;
> 		else
> 			knew.private_value =
> 				AK_COMPOSE(idx/2, (idx%2) + 4, 0, 163) |
> 				AK_VOL_CVT | AK_IPGA;

The code above is for the cases with multiple codecs, i.e. when two or
more AK5365 codecs are connected to a single controller.

> 
> > FYI, the second patch is for envy24control to make it work correctly
> > after changing ADC ranges.
> I only tried envy24control a long time ago.  Then it didn't recognise my
> card and I ignored it afterwards.  Is it useful?  Should I give this a try?

Not really for VT1720/1724.  Many functions of Envy24 were stripped,
and thus many features envy24control provides are not supported by
VT1720/1724 chips.


thanks,

Takashi

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642

  reply	other threads:[~2006-09-08 10:32 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-28 11:38 [RFC] Add dB scale information to AK4xxx codec Takashi Iwai
2006-08-28 14:52 ` Takashi Iwai
2006-09-03 15:53 ` Jochen Voss
2006-09-04  9:58   ` Takashi Iwai
2006-09-04 11:13     ` Jochen Voß
2006-09-04 11:35       ` Takashi Iwai
2006-09-04 12:12         ` Jochen Voß
2006-09-04 17:41       ` Jochen Voss
2006-09-04 18:28         ` Takashi Iwai
2006-09-04 19:27           ` Jochen Voss
2006-09-05  9:36             ` Takashi Iwai
2006-09-05 19:24               ` Jochen Voss
2006-09-07 10:09                 ` Takashi Iwai
2006-09-07 10:29                   ` Jochen Voss
2006-09-07 10:33                     ` Takashi Iwai
2006-09-07 11:00                       ` Jochen Voss
2006-09-07 12:49                         ` Takashi Iwai
2006-09-07 14:52                           ` Takashi Iwai
2006-09-07 22:18                             ` Jochen Voss
2006-09-08 10:32                               ` Takashi Iwai [this message]
2006-09-10 22:38                                 ` Jochen Voss

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=s5hr6ymd4xq.wl%tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=alsa-devel@lists.sourceforge.net \
    --cc=voss@seehuhn.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.