From c82c400fb653292bbf0570e278d60e1ba14cc341 Mon Sep 17 00:00:00 2001 From: Shuming Fan Date: Wed, 16 Nov 2022 17:36:51 +0800 Subject: [PATCH] ucm2: sof-soundwire: add basic settings for RT1318 SDCA device Add support for rt1318 amplifier Fixes: https://github.com/alsa-project/alsa-ucm-conf/pull/242 Signed-off-by: Shuming Fan Signed-off-by: Jaroslav Kysela --- ucm2/sof-soundwire/rt1318-1.conf | 20 ++++++++++++++++++++ ucm2/sof-soundwire/rt1318-2.conf | 25 +++++++++++++++++++++++++ 2 files changed, 45 insertions(+) create mode 100644 ucm2/sof-soundwire/rt1318-1.conf create mode 100644 ucm2/sof-soundwire/rt1318-2.conf diff --git a/ucm2/sof-soundwire/rt1318-1.conf b/ucm2/sof-soundwire/rt1318-1.conf new file mode 100644 index 00000000..13d77e1c --- /dev/null +++ b/ucm2/sof-soundwire/rt1318-1.conf @@ -0,0 +1,20 @@ +# Use case Configuration for sof-soundwire card + +SectionDevice."Speaker" { + Comment "Speaker" + + EnableSequence [ + cset "name='rt1318-1 DAC Switch' 1" + cset "name='Speaker Switch' on" + ] + + DisableSequence [ + cset "name='rt1318-1 DAC Switch' 0" + cset "name='Speaker Switch' off" + ] + + Value { + PlaybackPriority 100 + PlaybackPCM "hw:${CardId},2" + } +} diff --git a/ucm2/sof-soundwire/rt1318-2.conf b/ucm2/sof-soundwire/rt1318-2.conf new file mode 100644 index 00000000..56024704 --- /dev/null +++ b/ucm2/sof-soundwire/rt1318-2.conf @@ -0,0 +1,25 @@ +# Use case Configuration for sof-soundwire card + +SectionDevice."Speaker" { + Comment "Speaker" + + EnableSequence [ + cset "name='rt1318-1 RX Channel Select' L,L" + cset "name='rt1318-2 RX Channel Select' R,R" + + cset "name='rt1318-1 DAC Switch' 1" + cset "name='rt1318-2 DAC Switch' 1" + cset "name='Speaker Switch' on" + ] + + DisableSequence [ + cset "name='rt1318-1 DAC Switch' 0" + cset "name='rt1318-2 DAC Switch' 0" + cset "name='Speaker Switch' off" + ] + + Value { + PlaybackPriority 100 + PlaybackPCM "hw:${CardId},2" + } +}