From patchwork Sat Apr 28 19:51:58 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans de Goede X-Patchwork-Id: 10370315 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 4BB1360116 for ; Sat, 28 Apr 2018 19:52:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3F15C28BE7 for ; Sat, 28 Apr 2018 19:52:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 33FB42908F; Sat, 28 Apr 2018 19:52:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7D28D28BE7 for ; Sat, 28 Apr 2018 19:52:20 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 9AA942671EA; Sat, 28 Apr 2018 21:52:13 +0200 (CEST) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 36CB4267265; Sat, 28 Apr 2018 21:52:08 +0200 (CEST) Received: from mx1.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by alsa0.perex.cz (Postfix) with ESMTP id 6FD44266C1C for ; Sat, 28 Apr 2018 21:52:06 +0200 (CEST) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C0319406C751; Sat, 28 Apr 2018 19:52:05 +0000 (UTC) Received: from shalem.localdomain.com (ovpn-116-45.ams2.redhat.com [10.36.116.45]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1A50C1116CFB; Sat, 28 Apr 2018 19:52:04 +0000 (UTC) From: Hans de Goede To: alsa-devel@alsa-project.org Date: Sat, 28 Apr 2018 21:51:58 +0200 Message-Id: <20180428195200.11722-4-hdegoede@redhat.com> In-Reply-To: <20180428195200.11722-1-hdegoede@redhat.com> References: <20180428195200.11722-1-hdegoede@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.5]); Sat, 28 Apr 2018 19:52:05 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.5]); Sat, 28 Apr 2018 19:52:05 +0000 (UTC) for IP:'10.11.54.3' DOMAIN:'int-mx03.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'hdegoede@redhat.com' RCPT:'' Cc: Takashi Iwai , Hans de Goede , Pierre-Louis Bossart Subject: [alsa-devel] [PATCH 3/5] conf/ucm: chtrt5645: Fix recording from internal analog microphone X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP The internal analog mic switch is called 'Int Analog Mic Switch' (not 'Int Mic Switch') and is connected to BST2 not BST1. Also change the analog mic volume levels so that we get better audio / less noise. Signed-off-by: Hans de Goede --- src/conf/ucm/chtrt5645/HiFi.conf | 38 ++++++++++++++++++++------------ 1 file changed, 24 insertions(+), 14 deletions(-) diff --git a/src/conf/ucm/chtrt5645/HiFi.conf b/src/conf/ucm/chtrt5645/HiFi.conf index b97a9c00..e81866cf 100644 --- a/src/conf/ucm/chtrt5645/HiFi.conf +++ b/src/conf/ucm/chtrt5645/HiFi.conf @@ -160,15 +160,24 @@ SectionVerb { # Input Configuration cset "name='Stereo1 DMIC Mux' 0" + cset "name='Stereo1 ADC1 Mux' 1" cset "name='Stereo1 ADC2 Mux' 1" cset "name='ADC Capture Switch' on" - cset "name='ADC Capture Volume' 31" - cset "name='ADC Boost Capture Volume' 3" - cset "name='Mono ADC Capture Volume' 63" - cset "name='Mono ADC Boost Capture Volume' 2" - cset "name='IN Capture Volume' 63" + # 55/63 + cset "name='ADC Capture Volume' 55" + # set ADC Boost to 0/3, higher vals cause a lot of white noise + cset "name='ADC Boost Capture Volume' 0" + # 55/63 + cset "name='Mono ADC Capture Volume' 55" + # 0/3 + cset "name='Mono ADC Boost Capture Volume' 0" + # 27/31 + cset "name='IN Capture Volume' 27" cset "name='I2S2 Func Switch' on" - + # 3/12 the headphone mic tends to be quite loud + cset "name='IN1 Boost' 3" + # 8/8 the internal analog mic tends to be quite soft + cset "name='IN2 Boost' 8" ] DisableSequence [ @@ -243,7 +252,8 @@ SectionDevice."Headphones" { cset "name='Headphone Switch' on" cset "name='Headphone Channel Switch' on" - cset "name='Headphone Playback Volume' 31" + # 25/39 higher values cause crackling on some boards + cset "name='Headphone Playback Volume' 25" ] DisableSequence [ @@ -255,7 +265,7 @@ SectionDevice."Headphones" { } SectionDevice."Mic".0 { - Comment "Internal Analog Microphones" + Comment "Internal Analog Microphone" Value { CaptureChannels "2" @@ -265,7 +275,7 @@ SectionDevice."Mic".0 { EnableSequence [ cdev "hw:chtrt5645" - cset "name='Int Mic Switch' on" + cset "name='Int Analog Mic Switch' on" cset "name='Sto1 ADC MIXL ADC1 Switch' on" cset "name='Sto1 ADC MIXR ADC1 Switch' on" @@ -277,8 +287,8 @@ SectionDevice."Mic".0 { cset "name='Mono ADC MIXL ADC2 Switch' off" cset "name='Mono ADC MIXR ADC2 Switch' off" - cset "name='RECMIXL BST1 Switch' on" - cset "name='RECMIXR BST1 Switch' on" + cset "name='RECMIXL BST2 Switch' on" + cset "name='RECMIXR BST2 Switch' on" ] @@ -290,10 +300,10 @@ SectionDevice."Mic".0 { cset "name='Mono ADC MIXL ADC1 Switch' off" cset "name='Mono ADC MIXR ADC1 Switch' off" - cset "name='RECMIXL BST1 Switch' off" - cset "name='RECMIXR BST1 Switch' off" + cset "name='RECMIXL BST2 Switch' off" + cset "name='RECMIXR BST2 Switch' off" - cset "name='Int Mic Switch' off" + cset "name='Int Analog Mic Switch' off" ] }