From: Takashi Iwai Subject: Re: Output to Input routing Date: Thu, 02 Aug 2007 14:30:57 +0200 Message-ID: References: Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 81670103877 for ; Thu, 2 Aug 2007 14:30:58 +0200 (CEST) In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@alsa-project.org Errors-To: alsa-devel-bounces@alsa-project.org To: Vadim Lebedev Cc: alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org At Tue, 31 Jul 2007 14:33:04 +0000 (UTC), Vadim Lebedev wrote: > > Hello, > > I remember reading AC97 specs that there si possibility to configure it > in such a way, that when doing stereo capture, left input channel will get > actual MIC input and right input channel will get the copy of speaker output. > This setting is ideal for echo cancellation algorithm. > To my grand dismay i'm unable to find a doc of ALSA mixer API so i'm > unsucessuful writing code to put mixer in such mode. > Can some kind soul please contibuite a code snippet.... Choose "Mix" as the capture source will give you the loopback input for the specific channel. You can change it via amixer, for example, % amixer cset iface=MIXER,name='Capture Source' 0,5 numid=66,iface=MIXER,name='Capture Source' ; type=ENUMERATED,access=rw------,values=2,items=8 ; Item #0 'Mic' ; Item #1 'CD' ; Item #2 'Video' ; Item #3 'Aux' ; Item #4 'Line' ; Item #5 'Mix' ; Item #6 'Mix Mono' ; Item #7 'Phone' : values=0,5 Takashi