# Use case Configuration for RT5631 based ASUS Transformers

SectionDevice."Speaker" {
	Comment "Speaker"

	ConflictingDevice [
		"Headphones"
	]

	EnableSequence [
		cset "name='Speaker Playback Switch' on"
		cset "name='Int Spk Switch' on"
	]

	DisableSequence [
		cset "name='Int Spk Switch' off"
		cset "name='Speaker Playback Switch' off"
	]

	Value {
		PlaybackPCM "hw:${CardId}"
		PlaybackChannels 2
		PlaybackPriority 200

		PlaybackMixerElem "Speaker"
	}
}

SectionDevice."Headphones" {
	Comment "Headphones"

	ConflictingDevice [
		"Speaker"
	]

	EnableSequence [
		cset "name='HP Playback Switch' on"
	]

	DisableSequence [
		cset "name='HP Playback Switch' off"
	]

	Value {
		PlaybackPCM "hw:${CardId}"
		PlaybackChannels 2
		PlaybackPriority 100

		PlaybackMixerElem "HP"

		JackControl "Headphone Jack"
	}
}

SectionDevice."Mic1" {
	Comment "Internal Microphone"

	ConflictingDevice [
		"Mic2"
	]

	EnableSequence [
		cset "name='DMIC Capture Switch' on"
		cset "name='DMIC Switch' on"
		cset "name='Int Mic Switch' on"
	]

	DisableSequence [
		cset "name='DMIC Capture Switch' off"
		cset "name='DMIC Switch' off"
		cset "name='Int Mic Switch' off"
	]

	Value {
		CapturePCM "hw:${CardId}"
		CapturePriority 200
	}
}

SectionDevice."Mic2" {
	Comment "External Microphone"

	ConflictingDevice [
		"Mic1"
	]

	EnableSequence [
		cset "name='Mic Jack Switch' on"
	]

	DisableSequence [
		cset "name='Mic Jack Switch' off"
	]

	Value {
		CapturePCM "hw:${CardId}"
		CapturePriority 100

		JackControl "Mic Jack"
	}
}
