SectionVerb {
	If.Controls {
		Condition {
			Type ControlExists
			Control "name='media0_in Gain 0 Switch'"
		}
		Before.EnableSequence "0"
		True {
			Include.pe.File "/platforms/bytcr/PlatformEnableSeq.conf"
			Include.pd.File "/platforms/bytcr/PlatformDisableSeq.conf"
		}
	}

    EnableSequence [
		cset "name='codec_out0 Gain 0 Volume' 72%"
		cset "name='IF2 ADC Mux' DAC_REF"
		cset "name='IF3 ADC Mux' IF_ADC1"
		# 音量50%
		# cset "name='DAC1 Playback Volume' 50%"
		# 设置右扬声器使用右声道
		cset "name='Amp Input1' Right"

		# Enable Boost
		cset "name='STO1 ADC Capture Switch' on"
		cset "name='IN3 Boost Volume' 45"
		cset "name='IN4 Boost Volume' 45"

		# Set ADC Source
		cset "name='Stereo1 ADC Source' 'ADC1'"
		cset "name='Stereo1 ADC1 Source' 'ADC'"

		# Set recording mixer output to ADC
		cset "name='Stereo1 ADC MIXL ADC1 Switch' on"
		cset "name='Stereo1 ADC MIXR ADC1 Switch' on"
		cset "name='DAC1 MIXL Stereo ADC Switch' off"
		cset "name='DAC1 MIXR Stereo ADC Switch' off"
		cset "name='media_loop2_out mix 0 codec_in0 Switch' on"
		cset "name='pcm1_out mix 0 media_loop2_in Switch' on"

		# Set ADC Volume
		cset "name='IN Capture Volume' 23"
		cset "name='STO1 ADC Capture Volume' 70"
    ]

	DisableSequence []
	Value {}
}

SectionDevice."Speaker" {
	Comment "Stereo Speakers"

	ConflictingDevice []

	Value {
		PlaybackPCM "hw:${CardId}"
		# The speaker ampl. path on the 5659 has no speaker vol control
		# Use the digital DAC1 master control as MixerElem
		PlaybackMixerElem "DAC1"
	}

	EnableSequence [
		cset "name='DAC1 Playback Switch' on"
	]
	DisableSequence [
		cset "name='DAC1 Playback Switch' off"
	]
}

SectionDevice."IntMic" {
	Comment "Microphone"

	ConflictingDevice []

	EnableSequence [
		# Enable Int Mic
		cset "name='Int Mic Switch' on"
		cset "name='RECMIX1L BST3 Switch' on"
		cset "name='RECMIX1R BST4 Switch' on"
	]

	DisableSequence [
		cset "name='Int Mic Switch' off"
		cset "name='RECMIX1L BST3 Switch' off"
		cset "name='RECMIX1R BST4 Switch' off"
	]

	Value {
		CapturePCM "hw:${CardId}"
		# CaptureMixerElem "Int Mic"
		CaptureVolume "IN Capture Volume"
		CaptureSwitch "Int Mic Switch"
	}
}