cml/sof-cmlda7219max: add dmic split, use front and rear mic

pull/1/head
WeirdTreeThing 2023-05-24 17:27:19 -04:00
parent f758565591
commit e6e72150e3
No known key found for this signature in database
GPG Key ID: 1F56A4B52998B851
1 changed files with 71 additions and 3 deletions

View File

@ -31,6 +31,44 @@ SectionVerb {
] ]
} }
# Split 4ch dmic into 2 virtual 2ch mics
Include.pcm_split.File "/conf.d/dmic-common/split.conf"
Macro [
{
SplitPCM {
Name "cml_stereo_in"
Direction Capture
Format S32_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" { SectionDevice."Speaker" {
Comment "Speaker" Comment "Speaker"
@ -66,14 +104,44 @@ SectionDevice."Headphones" {
} }
SectionDevice."Mic" { SectionDevice."Mic" {
Comment "Internal Microphone" Comment "Front Mic"
Value { Value {
CapturePriority 100 CapturePriority 100
CapturePCM "hw:sofcmlda7219max,2" CapturePCM "hw:sofcmlda7219max,2"
CaptureChannels 4 CaptureChannels 4
CaptureChannelMap "2 3 -1 -1 -1 -1 -1 -1 -1 -1 -1" }
IntrinsicSensitivity "-2600" Macro.pcm_split.SplitPCMDevice {
Name "cml_stereo_in"
Direction Capture
Device 2
HWChannels 4
Channels 2
Channel0 0
Channel1 1
ChannelPos0 FL
ChannelPos1 FR
}
}
SectionDevice."Mic 1" {
Comment "Rear Mic"
Value {
CapturePriority 100
CapturePCM "hw:sofcmlda7219max,2"
CaptureChannels 4
}
Macro.pcm_split.SplitPCMDevice {
Name "cml_stereo_in"
Direction Capture
Device 2
HWChannels 4
Channels 2
Channel0 2
Channel1 3
ChannelPos0 FL
ChannelPos1 FR
} }
} }