diff --git a/glk/sof-glkda7219ma/HiFi.conf b/glk/sof-glkda7219ma/HiFi.conf index dd76e3c..2234879 100644 --- a/glk/sof-glkda7219ma/HiFi.conf +++ b/glk/sof-glkda7219ma/HiFi.conf @@ -28,6 +28,44 @@ SectionVerb { ] } +# Split 4ch dmic into 2 virtual 2ch mics +Include.pcm_split.File "/conf.d/dmic-common/split.conf" + +Macro [ + { + SplitPCM { + Name "glk_stereo_in" + Direction Capture + Format S16_LE + Channels 2 + HWChannels 4 + HWChannelPos0 FL + HWChannelPos1 FR + HWChannelPos2 FL + HWChannelPos3 FR + } + } +] + +Include.ctl_remap.File "/conf.d/dmic-common/remap.conf" + +Macro [ + { + CtlRemapStereoVolSw { + Dst "Mic 1 Capture" + Index0 0 + Index1 1 + } + } + { + CtlRemapStereoVolSw { + Dst "Mic 2 Capture" + Index0 2 + Index1 3 + } + } +] + SectionDevice."Speaker" { Comment "Speaker" @@ -70,6 +108,17 @@ SectionDevice."Mic" { CapturePCM "hw:${CardId},99" CaptureChannels 4 } + Macro.pcm_split.SplitPCMDevice { + Name "glk_stereo_in" + Direction Capture + Device 99 + HWChannels 4 + Channels 2 + Channel0 0 + Channel1 1 + ChannelPos0 FL + ChannelPos1 FR + } SectionDevice."Headset" { diff --git a/glk/sof-glkrt5682ma/HiFi.conf b/glk/sof-glkrt5682ma/HiFi.conf index f46362d..84dc341 100644 --- a/glk/sof-glkrt5682ma/HiFi.conf +++ b/glk/sof-glkrt5682ma/HiFi.conf @@ -24,6 +24,44 @@ SectionVerb { ] } +# Split 4ch dmic into 2 virtual 2ch mics +Include.pcm_split.File "/conf.d/dmic-common/split.conf" + +Macro [ + { + SplitPCM { + Name "glk_stereo_in" + Direction Capture + Format S16_LE + Channels 2 + HWChannels 4 + HWChannelPos0 FL + HWChannelPos1 FR + HWChannelPos2 FL + HWChannelPos3 FR + } + } +] + +Include.ctl_remap.File "/conf.d/dmic-common/remap.conf" + +Macro [ + { + CtlRemapStereoVolSw { + Dst "Mic 1 Capture" + Index0 0 + Index1 1 + } + } + { + CtlRemapStereoVolSw { + Dst "Mic 2 Capture" + Index0 2 + Index1 3 + } + } +] + SectionDevice."Speaker" { Comment "Speaker" @@ -70,6 +108,17 @@ SectionDevice."Mic" { CapturePCM "hw:${CardId},99" CaptureChannels 4 } + Macro.pcm_split.SplitPCMDevice { + Name "glk_stereo_in" + Direction Capture + Device 99 + HWChannels 4 + Channels 2 + Channel0 0 + Channel1 1 + ChannelPos0 FL + ChannelPos1 FR + } SectionDevice."Headset" {