]> git.alsa-project.org Git - alsa-ucm-conf.git/commitdiff
Add UCM for Librem 5 Devkit
authorGuido Günther <agx@sigxcpu.org>
Mon, 21 Jun 2021 09:58:45 +0000 (11:58 +0200)
committerJaroslav Kysela <perex@perex.cz>
Mon, 23 Aug 2021 13:47:19 +0000 (15:47 +0200)
The DTS configuration is in Linux mainline since 5.13-rc1:

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/freescale/imx8mq-librem5-devkit.dts?h=v5.13-rc1#n167

Signed-off-by: Guido Günther <agx@sigxcpu.org>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
ucm2/NXP/iMX8/Librem_5_Devkit/HiFi.conf [new file with mode: 0644]
ucm2/NXP/iMX8/Librem_5_Devkit/Librem 5 Devkit.conf [new file with mode: 0644]
ucm2/conf.d/simple-card/Librem 5 Devkit.conf [new symlink]

diff --git a/ucm2/NXP/iMX8/Librem_5_Devkit/HiFi.conf b/ucm2/NXP/iMX8/Librem_5_Devkit/HiFi.conf
new file mode 100644 (file)
index 0000000..f34aa92
--- /dev/null
@@ -0,0 +1,74 @@
+SectionVerb {
+       EnableSequence [
+               cset "name='Digital Input Mux' I2S"
+               cset "name='PCM Playback Volume' 144"
+
+               cset "name='AVC Switch' off"
+               cset "name='Headphone Playback ZC Switch' off"
+
+               cset "name='Capture Attenuate Switch (-6dB)' off"
+               cset "name='Capture Mux' MIX_IN"
+               cset "name='Capture ZC Switch' off"
+               cset "name='Capture Switch' On"
+               cset "name='Capture Volume' 15,15"
+       ]
+       DisableSequence [
+               cset "name='PCM Playback Volume' 0"
+       ]
+       Value {
+       }
+}
+
+SectionDevice."Handset".0 {
+       Comment "Handset"
+
+       ConflictingDevice [
+               "Headset"
+       ]
+
+       EnableSequence [
+               cset "name='Mic Mux MUX' Input 2"
+               cset "name='Lineout Playback Switch' on"
+               cset "name='Lineout Playback Volume' 18"
+               cset "name='Mic Volume' 2"
+       ]
+       DisableSequence [
+               cset "name='Lineout Playback Switch' off"
+               cset "name='Mic Volume' 0"
+       ]
+       Value {
+               PlaybackPriority "1000"
+               PlaybackPCM "hw:${CardId},0"
+               PlaybackVolume "name='Lineout Playback Volume'"
+               PlaybackSwitch "name='Lineout Playback Switch'"
+               CapturePriority "1000"
+               CapturePCM "hw:${CardId},0"
+       }
+}
+
+SectionDevice."Headset".0 {
+       Comment "Headset"
+
+       ConflictingDevice [
+               "Handset"
+       ]
+
+       EnableSequence [
+               cset "name='Mic Mux MUX' Input 1"
+               cset "name='Headphone Mux' DAC"
+               cset "name='Headphone Playback Volume' 63"
+               cset "name='Headphone Playback Switch' on"
+       ]
+       DisableSequence [
+               cset "name='Headphone Playback Switch' off"
+       ]
+       Value {
+               PlaybackPriority "700"
+               PlaybackPCM "hw:${CardId},0"
+               PlaybackVolume "name='Headphone Playback Volume'"
+               PlaybackSwitch "name='Headphone Playback Switch'"
+               CapturePriority "700"
+               CapturePCM "hw:${CardId},0"
+               JackControl "Headphones Jack"
+       }
+}
diff --git a/ucm2/NXP/iMX8/Librem_5_Devkit/Librem 5 Devkit.conf b/ucm2/NXP/iMX8/Librem_5_Devkit/Librem 5 Devkit.conf
new file mode 100644 (file)
index 0000000..933e3d4
--- /dev/null
@@ -0,0 +1,10 @@
+Syntax 2
+
+SectionUseCase."HiFi" {
+       File "HiFi.conf"
+}
+
+ValueDefaults {
+       PlaybackPCM "hw:${CardId},0"
+       CapturePCM "hw:${CardId},0"
+}
diff --git a/ucm2/conf.d/simple-card/Librem 5 Devkit.conf b/ucm2/conf.d/simple-card/Librem 5 Devkit.conf
new file mode 120000 (symlink)
index 0000000..3bdfe20
--- /dev/null
@@ -0,0 +1 @@
+../../NXP/iMX8/Librem_5_Devkit/Librem 5 Devkit.conf
\ No newline at end of file