# Use case Configuration for bytcr-rt5640
+Define.HaveAif1 ""
+Define.HaveAif2 ""
+
+If.DefineAif1 {
+ Condition {
+ Type String
+ Haystack "${CardComponents}"
+ Needle "aif:1"
+ }
+ True.Define.HaveAif1 "yes"
+}
+
+If.DefineAif2 {
+ Condition {
+ Type String
+ Haystack "${CardComponents}"
+ Needle "aif:2"
+ }
+ True.Define.HaveAif2 "yes"
+}
+
SectionVerb {
Include.e.File "/codecs/rt5640/EnableSeq.conf"
Value {
CapturePriority 100
CapturePCM "hw:${CardId}"
+ If.DmicAif1 {
+ Condition { Type String Empty "${var:HaveAif1}" }
+ False {
+ CaptureMixerElem "ADC"
+ CaptureVolume "ADC Capture Volume"
+ CaptureSwitch "ADC Capture Switch"
+ }
+ }
+ If.DmicAif2 {
+ Condition { Type String Empty "${var:HaveAif2}" }
+ False {
+ CaptureMixerElem "Mono ADC"
+ CaptureVolume "Mono ADC Capture Volume"
+ CaptureSwitch "Mono ADC Capture Switch"
+ }
+ }
}
}
JackControl "Headphone Jack"
PlaybackMixerElem "HP"
PlaybackVolume "HP Playback Volume"
+ If.HpAif1 {
+ Condition { Type String Empty "${var:HaveAif1}" }
+ False {
+ PlaybackMasterElem "DAC1"
+ }
+ }
+ If.HpAif2 {
+ Condition { Type String Empty "${var:HaveAif2}" }
+ False {
+ PlaybackMasterElem "DAC2"
+ }
+ }
}
}
JackControl "Headset Mic Jack"
CaptureMixerElem "IN2 Boost"
CaptureVolume "IN2 Boost"
+ If.HSmicAif1 {
+ Condition { Type String Empty "${var:HaveAif1}" }
+ False {
+ CaptureMasterElem "ADC"
+ }
+ }
+ If.HSmicAif2 {
+ Condition { Type String Empty "${var:HaveAif2}" }
+ False {
+ CaptureMasterElem "Mono ADC"
+ }
+ }
}
}
CapturePCM "hw:${CardId}"
CaptureMixerElem "IN1 Boost"
CaptureVolume "IN1 Boost"
+ If.In1Aif1 {
+ Condition { Type String Empty "${var:HaveAif1}" }
+ False {
+ CaptureMasterElem "ADC"
+ }
+ }
+ If.In1Aif2 {
+ Condition { Type String Empty "${var:HaveAif2}" }
+ False {
+ CaptureMasterElem "Mono ADC"
+ }
+ }
}
}
CapturePCM "hw:${CardId}"
CaptureMixerElem "IN3 Boost"
CaptureVolume "IN3 Boost"
+ If.In3Aif1 {
+ Condition { Type String Empty "${var:HaveAif1}" }
+ False {
+ CaptureMasterElem "ADC"
+ }
+ }
+ If.In3Aif2 {
+ Condition { Type String Empty "${var:HaveAif2}" }
+ False {
+ CaptureMasterElem "Mono ADC"
+ }
+ }
}
}
PlaybackPCM "hw:${CardId}"
PlaybackMixerElem "Speaker"
PlaybackVolume "Speaker Playback Volume"
+ If.MonoSpkAif1 {
+ Condition { Type String Empty "${var:HaveAif1}" }
+ False {
+ PlaybackMasterElem "DAC1"
+ }
+ }
+ If.MonoSpkAif2 {
+ Condition { Type String Empty "${var:HaveAif2}" }
+ False {
+ PlaybackMasterElem "DAC2"
+ }
+ }
}
}
PlaybackPCM "hw:${CardId}"
PlaybackMixerElem "Speaker"
PlaybackVolume "Speaker Playback Volume"
+ If.SpkAif1 {
+ Condition { Type String Empty "${var:HaveAif1}" }
+ False {
+ PlaybackMasterElem "DAC1"
+ }
+ }
+ If.SpkAif2 {
+ Condition { Type String Empty "${var:HaveAif2}" }
+ False {
+ PlaybackMasterElem "DAC2"
+ }
+ }
}
}