device-samsung-manta: add audio support
Signed-off-by: Alexandre Marquet <tb@a-marquet.fr> Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7222>
This commit is contained in:
parent
3960d31623
commit
5eec34ee2e
3 changed files with 266 additions and 2 deletions
|
|
@ -3,13 +3,14 @@
|
|||
# Co-Maintainer: Alexandre Marquet <tb@a-marquet.fr>
|
||||
pkgname=device-samsung-manta
|
||||
pkgdesc="Google Nexus 10"
|
||||
pkgver=9
|
||||
pkgrel=1
|
||||
pkgver=10
|
||||
pkgrel=0
|
||||
url="https://postmarketos.org"
|
||||
license="MIT"
|
||||
arch="armv7"
|
||||
options="!check !archcheck"
|
||||
depends="
|
||||
alsa-ucm-conf
|
||||
linux-postmarketos-exynos5
|
||||
mkbootimg
|
||||
postmarketos-base
|
||||
|
|
@ -20,6 +21,8 @@ source="
|
|||
deviceinfo
|
||||
modules-initfs
|
||||
hwclock
|
||||
ucm/HiFi.conf
|
||||
ucm/Manta_WM1811.conf
|
||||
"
|
||||
replaces="openrc" # for hwclock configuration
|
||||
|
||||
|
|
@ -40,6 +43,13 @@ package() {
|
|||
|
||||
install -Dm644 "$srcdir"/hwclock \
|
||||
-t "$pkgdir"/etc/conf.d/
|
||||
|
||||
_manta_audio_dir="$pkgdir/usr/share/alsa/ucm2/conf.d/Manta_WM1811"
|
||||
install -Dm644 "$srcdir"/Manta_WM1811.conf \
|
||||
-t "$pkgdir"/usr/share/alsa/ucm2/conf.d/Manta_WM1811/
|
||||
install -Dm644 "$srcdir"/HiFi.conf \
|
||||
-t "$pkgdir"/usr/share/alsa/ucm2/conf.d/Manta_WM1811/
|
||||
|
||||
}
|
||||
|
||||
nonfree_firmware() {
|
||||
|
|
@ -56,4 +66,6 @@ sha512sums="
|
|||
9a566c5be457834f0cfa5750ced12ed1c26019dd24c311f4c8b3bf8b6417658c2868a6b2b6d2eb73b75a67e3bb707d8ae8016f80342d2b467d1e44eff7303269 deviceinfo
|
||||
e00c58936fa4340f8531538136ad028d002342a4399b68d26190b931831108007486257f9d8a48c3ed454696b45d176b1497d624c33ace21e61eba33ac7ce136 modules-initfs
|
||||
8a9756c66bf1eacd6a9717abf772a198123391deac7e32a520666dd6f72c4c5b09d1a4791437c8902f62cf4b49106ace195d57082972b1cb4c843c8e1b065875 hwclock
|
||||
0a3d0365369335fcb4793d6dce93b744111478e191f4725e06da431cd080874ba897ea5abf92da9fc9005a5520da253e199620229231b16fb58a41a1091e6a44 HiFi.conf
|
||||
0e9c4690db5316fc9c820a1c993235f2b39e1b2852288d1a1b51af670a7ddfd1a3f8f3bf6678ba5ade04389b74ca230667f61115d78b91077ec5bf9b9622f32b Manta_WM1811.conf
|
||||
"
|
||||
|
|
|
|||
200
device/community/device-samsung-manta/ucm/HiFi.conf
Normal file
200
device/community/device-samsung-manta/ucm/HiFi.conf
Normal file
|
|
@ -0,0 +1,200 @@
|
|||
SectionVerb {
|
||||
EnableSequence [
|
||||
cset "name='DAC1R Mixer AIF1.1 Switch' 0"
|
||||
cset "name='DAC1L Mixer AIF1.1 Switch' 0"
|
||||
cset "name='DAC1 Switch' 0"
|
||||
cset "name='DAC2 Switch' 0"
|
||||
cset "name='AIF1DRC1 Mode' Default"
|
||||
cset "name='AIF1DAC1 DRC Switch' 0"
|
||||
cset "name='Speaker Switch' 0"
|
||||
cset "name='SPKR DAC1 Switch' 0"
|
||||
cset "name='SPKL DAC1 Switch' 0"
|
||||
cset "name='Speaker Mixer Volume' 0"
|
||||
cset "name='Headphone Switch' 0"
|
||||
cset "name='Right Headphone Mux' DAC"
|
||||
cset "name='Left Headphone Mux' DAC"
|
||||
cset "name='Left Output Mixer DAC Switch' 0"
|
||||
cset "name='Right Output Mixer DAC Switch' 0"
|
||||
cset "name='MIXINL IN1L Switch' 0"
|
||||
cset "name='IN1L Switch' 0"
|
||||
cset "name='IN1L PGA IN1LP Switch' 0"
|
||||
cset "name='IN1L PGA IN1LN Switch' 1"
|
||||
cset "name='MIXINL IN2L Switch' 0"
|
||||
cset "name='IN2L Switch' 0"
|
||||
cset "name='IN2L PGA IN2LP Switch' 0"
|
||||
cset "name='IN2L PGA IN2LN Switch' 1"
|
||||
cset "name='MIXINR IN1R Switch' 0"
|
||||
cset "name='IN1R Switch' 0"
|
||||
cset "name='IN1R PGA IN1RP Switch' 0"
|
||||
cset "name='IN1R PGA IN1RN Switch' 1"
|
||||
cset "name='MIXINR IN2R Switch' 0"
|
||||
cset "name='IN2R Switch' 0"
|
||||
cset "name='IN2R PGA IN2RP Switch' 0"
|
||||
cset "name='IN2R PGA IN2RN Switch' 1"
|
||||
cset "name='AIF2DACL Mux' AIF3"
|
||||
cset "name='AIF2DACR Mux' AIF3"
|
||||
cset "name='AIF2DAC Mux' AIF3DACDAT"
|
||||
cset "name='AIF3ADC Mux' AIF2ADCDAT"
|
||||
cset "name='AIF1ADC1L Mixer AIF2 Switch' 0"
|
||||
cset "name='AIF1ADC1R Mixer AIF2 Switch' 0"
|
||||
cset "name='AIF1ADC2L Mixer AIF2 Switch' 0"
|
||||
cset "name='AIF1ADC2R Mixer AIF2 Switch' 0"
|
||||
cset "name='AIF1ADC1L Mixer ADC/DMIC Switch' 0"
|
||||
cset "name='AIF1ADC1R Mixer ADC/DMIC Switch' 0"
|
||||
cset "name='MUX' A-D"
|
||||
]
|
||||
|
||||
DisableSequence [
|
||||
]
|
||||
|
||||
Value {
|
||||
PlaybackChannels "2"
|
||||
CaptureChannels "2"
|
||||
}
|
||||
}
|
||||
|
||||
SectionDevice."Speaker" {
|
||||
Comment "Internal speakers"
|
||||
|
||||
ConflictingDevice [
|
||||
"Headphones"
|
||||
]
|
||||
|
||||
EnableSequence [
|
||||
cset "name='DAC1R Mixer AIF1.1 Switch' 1"
|
||||
cset "name='DAC1L Mixer AIF1.1 Switch' 1"
|
||||
cset "name='DAC1 Switch' 1"
|
||||
cset "name='AIF1DAC1 EQ Switch' 1"
|
||||
cset "name='AIF1DAC1 EQ1 Volume' 3"
|
||||
cset "name='AIF1DAC1 EQ2 Volume' 8"
|
||||
cset "name='AIF1DAC1 EQ3 Volume' 16"
|
||||
cset "name='AIF1DAC1 EQ4 Volume' 10"
|
||||
cset "name='AIF1DAC1 EQ5 Volume' 11"
|
||||
cset "name='Speaker Switch' 1"
|
||||
cset "name='SPKR DAC1 Switch' 1"
|
||||
cset "name='SPKL DAC1 Switch' 1"
|
||||
cset "name='Speaker Mixer Volume' 3"
|
||||
cset "name='Speaker Boost Volume' 5"
|
||||
cset "name='AIF1DRC1 Mode' Speakers Media"
|
||||
cset "name='AIF1DAC1 DRC Switch' 1"
|
||||
cset "name='Speaker Volume' 61,62"
|
||||
]
|
||||
|
||||
DisableSequence [
|
||||
cset "name='DAC1R Mixer AIF1.1 Switch' 0"
|
||||
cset "name='DAC1L Mixer AIF1.1 Switch' 0"
|
||||
cset "name='DAC1 Switch' 0"
|
||||
cset "name='Speaker Switch' 0"
|
||||
cset "name='SPKR DAC1 Switch' 0"
|
||||
cset "name='SPKL DAC1 Switch' 0"
|
||||
cset "name='Speaker Mixer Volume' 0"
|
||||
cset "name='AIF1DRC1 Mode' Default"
|
||||
cset "name='AIF1DAC1 DRC Switch' 0"
|
||||
]
|
||||
|
||||
Value {
|
||||
PlaybackPCM "hw:${CardId},0"
|
||||
}
|
||||
}
|
||||
|
||||
SectionDevice."Headphones" {
|
||||
Comment "Headphones"
|
||||
|
||||
ConflictingDevice [
|
||||
"Speaker"
|
||||
]
|
||||
|
||||
EnableSequence [
|
||||
cset "name='DAC1R Mixer AIF1.1 Switch' 1"
|
||||
cset "name='DAC1L Mixer AIF1.1 Switch' 1"
|
||||
cset "name='DAC1 Switch' 1"
|
||||
cset "name='AIF1DAC1 EQ Switch' 0"
|
||||
cset "name='Headphone Switch' 1"
|
||||
cset "name='Headphone Volume' 24"
|
||||
]
|
||||
|
||||
DisableSequence [
|
||||
cset "name='DAC1R Mixer AIF1.1 Switch' 0"
|
||||
cset "name='DAC1L Mixer AIF1.1 Switch' 0"
|
||||
cset "name='DAC1 Switch' 0"
|
||||
cset "name='Headphone Switch' 0"
|
||||
]
|
||||
|
||||
Value {
|
||||
PlaybackPCM "hw:${CardId},0"
|
||||
JackControl "Headset Jack"
|
||||
}
|
||||
}
|
||||
|
||||
SectionDevice."Mic" {
|
||||
Comment "Internal microphone"
|
||||
|
||||
ConflictingDevice [
|
||||
"Headset"
|
||||
]
|
||||
|
||||
EnableSequence [
|
||||
cset "name='AIF1ADC1L Mixer ADC/DMIC Switch' 1"
|
||||
cset "name='AIF1ADC1R Mixer ADC/DMIC Switch' 1"
|
||||
cset "name='MIXINR IN2R Switch' 1"
|
||||
cset "name='MIXINR IN2R Volume' 1"
|
||||
cset "name='IN2R Switch' 1"
|
||||
cset "name='AIF1ADCL Source' Right"
|
||||
cset "name='AIF1ADC1L Mixer ADC/DMIC Switch' 1"
|
||||
cset "name='AIF1ADC1R Mixer ADC/DMIC Switch' 1"
|
||||
cset "name='MIXINL IN2L Switch' 1"
|
||||
cset "name='MIXINL IN2L Volume' 1"
|
||||
cset "name='IN2L Switch' 1"
|
||||
cset "name='AIF1ADCR Source' Left"
|
||||
cset "name='IN2R Volume' 16"
|
||||
cset "name='IN2L Volume' 16"
|
||||
cset "name='AIF1ADC1 HPF Switch' 1"
|
||||
cset "name='AIF1ADC1 HPF Mode' HiFi"
|
||||
]
|
||||
|
||||
DisableSequence [
|
||||
cset "name='AIF1ADC1L Mixer ADC/DMIC Switch' 0"
|
||||
cset "name='AIF1ADC1R Mixer ADC/DMIC Switch' 0"
|
||||
cset "name='MIXINR IN2R Switch' 0"
|
||||
cset "name='IN2R Switch' 0"
|
||||
cset "name='AIF1ADC1L Mixer ADC/DMIC Switch' 0"
|
||||
cset "name='AIF1ADC1R Mixer ADC/DMIC Switch' 0"
|
||||
cset "name='MIXINL IN2L Switch' 0"
|
||||
cset "name='IN2L Switch' 0"
|
||||
]
|
||||
|
||||
Value {
|
||||
CapturePCM "hw:${CardId},0"
|
||||
}
|
||||
}
|
||||
|
||||
SectionDevice."Headset" {
|
||||
Comment "Headset"
|
||||
|
||||
ConflictingDevice [
|
||||
"Mic"
|
||||
]
|
||||
|
||||
EnableSequence [
|
||||
cset "name='AIF1ADC1L Mixer ADC/DMIC Switch' 1"
|
||||
cset "name='AIF1ADC1R Mixer ADC/DMIC Switch' 1"
|
||||
cset "name='MIXINR IN1R Switch' 1"
|
||||
cset "name='MIXINR IN1R Volume' 1"
|
||||
cset "name='IN1R Switch' 1"
|
||||
cset "name='AIF1ADCL Source' Right"
|
||||
cset "name='IN1R Volume' 16"
|
||||
cset "name='AIF1ADC1 HPF Mode' HiFi"
|
||||
]
|
||||
|
||||
DisableSequence [
|
||||
cset "name='AIF1ADC1L Mixer ADC/DMIC Switch' 0"
|
||||
cset "name='AIF1ADC1R Mixer ADC/DMIC Switch' 0"
|
||||
cset "name='MIXINR IN1R Switch' 0"
|
||||
cset "name='IN1R Switch' 0"
|
||||
]
|
||||
|
||||
Value {
|
||||
CapturePCM "hw:${CardId},0"
|
||||
JackControl "Headset Jack"
|
||||
}
|
||||
}
|
||||
52
device/community/device-samsung-manta/ucm/Manta_WM1811.conf
Normal file
52
device/community/device-samsung-manta/ucm/Manta_WM1811.conf
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
Syntax 6
|
||||
|
||||
SectionUseCase."HiFi" {
|
||||
File "HiFi.conf"
|
||||
Comment "Default"
|
||||
}
|
||||
|
||||
BootSequence [
|
||||
cdev "hw:WM1811"
|
||||
|
||||
cset "name='DAC1R Mixer AIF1.1 Switch' 0"
|
||||
cset "name='DAC1L Mixer AIF1.1 Switch' 0"
|
||||
cset "name='DAC1 Switch' 0"
|
||||
cset "name='DAC2 Switch' 0"
|
||||
cset "name='AIF1DRC1 Mode' Default"
|
||||
cset "name='AIF1DAC1 DRC Switch' 0"
|
||||
cset "name='Speaker Switch' 0"
|
||||
cset "name='SPKR DAC1 Switch' 0"
|
||||
cset "name='SPKL DAC1 Switch' 0"
|
||||
cset "name='Speaker Mixer Volume' 0"
|
||||
cset "name='Headphone Switch' 0"
|
||||
cset "name='Right Headphone Mux' DAC"
|
||||
cset "name='Left Headphone Mux' DAC"
|
||||
cset "name='Left Output Mixer DAC Switch' 0"
|
||||
cset "name='Right Output Mixer DAC Switch' 0"
|
||||
cset "name='MIXINL IN1L Switch' 0"
|
||||
cset "name='IN1L Switch' 0"
|
||||
cset "name='IN1L PGA IN1LP Switch' 0"
|
||||
cset "name='IN1L PGA IN1LN Switch' 1"
|
||||
cset "name='MIXINL IN2L Switch' 0"
|
||||
cset "name='IN2L Switch' 0"
|
||||
cset "name='IN2L PGA IN2LP Switch' 0"
|
||||
cset "name='IN2L PGA IN2LN Switch' 1"
|
||||
cset "name='MIXINR IN1R Switch' 0"
|
||||
cset "name='IN1R Switch' 0"
|
||||
cset "name='IN1R PGA IN1RP Switch' 0"
|
||||
cset "name='IN1R PGA IN1RN Switch' 1"
|
||||
cset "name='MIXINR IN2R Switch' 0"
|
||||
cset "name='IN2R Switch' 0"
|
||||
cset "name='IN2R PGA IN2RP Switch' 0"
|
||||
cset "name='IN2R PGA IN2RN Switch' 1"
|
||||
cset "name='AIF2DACL Mux' AIF3"
|
||||
cset "name='AIF2DACR Mux' AIF3"
|
||||
cset "name='AIF2DAC Mux' AIF3DACDAT"
|
||||
cset "name='AIF3ADC Mux' AIF2ADCDAT"
|
||||
cset "name='AIF1ADC1L Mixer AIF2 Switch' 0"
|
||||
cset "name='AIF1ADC1R Mixer AIF2 Switch' 0"
|
||||
cset "name='AIF1ADC2L Mixer AIF2 Switch' 0"
|
||||
cset "name='AIF1ADC2R Mixer AIF2 Switch' 0"
|
||||
cset "name='AIF1ADC1L Mixer ADC/DMIC Switch' 0"
|
||||
cset "name='AIF1ADC1R Mixer ADC/DMIC Switch' 0"
|
||||
]
|
||||
Loading…
Add table
Add a link
Reference in a new issue