1 |
commit: d2e0eb643dc5cadcb0b130c82f61d3ba1e31dfbc |
2 |
Author: Marco Scardovi <marco <AT> scardovi <DOT> com> |
3 |
AuthorDate: Thu Jul 1 08:52:12 2021 +0000 |
4 |
Commit: Marco Scardovi <marco <AT> scardovi <DOT> com> |
5 |
CommitDate: Thu Jul 1 08:52:34 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=d2e0eb64 |
7 |
|
8 |
media-libs/alsa-ucm-pinephone: added missing .conf files |
9 |
|
10 |
Package-Manager: Portage-3.0.20, Repoman-3.0.3 |
11 |
Signed-off-by: Marco Scardovi <marco <AT> scardovi.com> |
12 |
|
13 |
media-libs/alsa-ucm-pinephone/files/HiFi.conf | 146 ++++++++++++++++++++ |
14 |
media-libs/alsa-ucm-pinephone/files/PinePhone.conf | 11 ++ |
15 |
media-libs/alsa-ucm-pinephone/files/VoiceCall.conf | 151 +++++++++++++++++++++ |
16 |
3 files changed, 308 insertions(+) |
17 |
|
18 |
diff --git a/media-libs/alsa-ucm-pinephone/files/HiFi.conf b/media-libs/alsa-ucm-pinephone/files/HiFi.conf |
19 |
new file mode 100644 |
20 |
index 000000000..5996e4a26 |
21 |
--- /dev/null |
22 |
+++ b/media-libs/alsa-ucm-pinephone/files/HiFi.conf |
23 |
@@ -0,0 +1,146 @@ |
24 |
+SectionVerb { |
25 |
+ EnableSequence [ |
26 |
+ cset "name='Headphone Playback Switch' off" |
27 |
+ cset "name='Headphone Source Playback Route' DAC" |
28 |
+ cset "name='Line In Playback Switch' off" |
29 |
+ cset "name='Line Out Playback Switch' off" |
30 |
+ cset "name='Line Out Source Playback Route' Mono Differential" |
31 |
+ cset "name='Mic1 Playback Switch' off" |
32 |
+ cset "name='Mic2 Playback Switch' off" |
33 |
+ cset "name='AIF1 DA0 Playback Volume' 160" |
34 |
+ cset "name='AIF3 ADC Source Capture Route' None" |
35 |
+ cset "name='AIF2 DAC Source Playback Route' None" |
36 |
+ cset "name='DAC Playback Switch' on" |
37 |
+ cset "name='DAC Playback Volume' 160" |
38 |
+ cset "name='ADC Digital DAC Playback Switch' off" |
39 |
+ cset "name='AIF1 Slot 0 Digital DAC Playback Switch' on" |
40 |
+ cset "name='AIF2 Digital DAC Playback Switch' off" |
41 |
+ cset "name='DAC Reversed Playback Switch' off" |
42 |
+ cset "name='Earpiece Playback Switch' off" |
43 |
+ cset "name='Earpiece Source Playback Route' DACL" |
44 |
+ |
45 |
+ cset "name='Line In Capture Switch' off" |
46 |
+ cset "name='Mic1 Capture Switch' off" |
47 |
+ cset "name='Mic1 Boost Volume' 7" |
48 |
+ cset "name='Mic2 Capture Switch' off" |
49 |
+ cset "name='Mic2 Boost Volume' 7" |
50 |
+ cset "name='Mixer Capture Switch' off" |
51 |
+ cset "name='Mixer Reversed Capture Switch' off" |
52 |
+ cset "name='ADC Capture Volume' 160" |
53 |
+ cset "name='ADC Gain Capture Volume' 7" |
54 |
+ cset "name='AIF1 AD0 Capture Volume' 160" |
55 |
+ cset "name='AIF1 Data Digital ADC Capture Switch' on" |
56 |
+ cset "name='AIF2 ADC Mixer ADC Capture Switch' off" |
57 |
+ cset "name='AIF2 ADC Mixer AIF1 DA0 Capture Switch' off" |
58 |
+ cset "name='AIF2 ADC Mixer AIF2 DAC Rev Capture Switch' off" |
59 |
+ cset "name='AIF2 ADC Mixer AIF1 DA0 Capture Switch' off" |
60 |
+ cset "name='AIF2 ADC Mixer AIF1 DA0 Capture Switch' off" |
61 |
+ ] |
62 |
+ |
63 |
+ DisableSequence [ |
64 |
+ ] |
65 |
+ |
66 |
+ Value { |
67 |
+ } |
68 |
+} |
69 |
+ |
70 |
+SectionDevice."Speaker" { |
71 |
+ Comment "Internal speaker" |
72 |
+ EnableSequence [ |
73 |
+ cset "name='AIF1 DA0 Stereo Playback Route' Mix Mono" |
74 |
+ cset "name='Line Out Playback Switch' on" |
75 |
+ cset "name='Line Out Playback Volume' 100%" |
76 |
+ ] |
77 |
+ |
78 |
+ DisableSequence [ |
79 |
+ cset "name='Line Out Playback Switch' off" |
80 |
+ ] |
81 |
+ |
82 |
+ Value { |
83 |
+ PlaybackVolume "Line Out Playback Volume" |
84 |
+ PlaybackSwitch "Line Out Playback Switch" |
85 |
+ PlaybackChannels 2 |
86 |
+ PlaybackPriority 300 |
87 |
+ PlaybackPCM "hw:${CardId},0" |
88 |
+ } |
89 |
+} |
90 |
+SectionDevice."Earpiece" { |
91 |
+ Comment "Internal Earpiece" |
92 |
+ EnableSequence [ |
93 |
+ cset "name='AIF1 DA0 Stereo Playback Route' Mix Mono" |
94 |
+ cset "name='Earpiece Playback Switch' on" |
95 |
+ cset "name='Earpiece Playback Volume' 100%" |
96 |
+ ] |
97 |
+ |
98 |
+ DisableSequence [ |
99 |
+ cset "name='Earpiece Playback Switch' off" |
100 |
+ ] |
101 |
+ |
102 |
+ Value { |
103 |
+ PlaybackVolume "Earpiece Playback Volume" |
104 |
+ PlaybackSwitch "Earpiece Playback Switch" |
105 |
+ PlaybackChannels 2 |
106 |
+ PlaybackPriority 200 |
107 |
+ PlaybackPCM "hw:${CardId},0" |
108 |
+ } |
109 |
+} |
110 |
+SectionDevice."Mic" { |
111 |
+ Comment "Internal Microphone" |
112 |
+ ConflictingDevice [ |
113 |
+ "Headset" |
114 |
+ ] |
115 |
+ EnableSequence [ |
116 |
+ cset "name='Mic1 Capture Switch' on" |
117 |
+ ] |
118 |
+ DisableSequence [ |
119 |
+ cset "name='Mic1 Capture Switch' off" |
120 |
+ ] |
121 |
+ Value { |
122 |
+ CapturePriority 100 |
123 |
+ CapturePCM "hw:${CardId},0" |
124 |
+ CaptureChannels 2 |
125 |
+ CaptureVolume "ADC Capture Volume" |
126 |
+ CaptureSwitch "Mic1 Capture Switch" |
127 |
+ } |
128 |
+} |
129 |
+SectionDevice."Headset" { |
130 |
+ Comment "Headset Microphone" |
131 |
+ ConflictingDevice [ |
132 |
+ "Mic" |
133 |
+ ] |
134 |
+ EnableSequence [ |
135 |
+ cset "name='Mic2 Capture Switch' on" |
136 |
+ ] |
137 |
+ DisableSequence [ |
138 |
+ cset "name='Mic2 Capture Switch' off" |
139 |
+ ] |
140 |
+ Value { |
141 |
+ CapturePriority 500 |
142 |
+ CapturePCM "hw:${CardId},0" |
143 |
+ CaptureChannels 2 |
144 |
+ CaptureVolume "ADC Capture Volume" |
145 |
+ CaptureSwitch "Mic2 Capture Switch" |
146 |
+ JackControl "Headset Microphone Jack" |
147 |
+ } |
148 |
+} |
149 |
+SectionDevice."Headphones" { |
150 |
+ Comment "Headphones" |
151 |
+ EnableSequence [ |
152 |
+ cset "name='AIF1 DA0 Stereo Playback Route' Stereo" |
153 |
+ cset "name='Headphone Playback Switch' on" |
154 |
+ cset "name='Headphone Playback Volume' 70%" |
155 |
+ ] |
156 |
+ |
157 |
+ DisableSequence [ |
158 |
+ cset "name='Headphone Playback Switch' off" |
159 |
+ ] |
160 |
+ |
161 |
+ Value { |
162 |
+ PlaybackVolume "Headphone Playback Volume" |
163 |
+ PlaybackSwitch "Headphone Playback Switch" |
164 |
+ PlaybackChannels 2 |
165 |
+ PlaybackPriority 500 |
166 |
+ PlaybackPCM "hw:${CardId},0" |
167 |
+ JackControl "Headphone Jack" |
168 |
+ } |
169 |
+} |
170 |
|
171 |
diff --git a/media-libs/alsa-ucm-pinephone/files/PinePhone.conf b/media-libs/alsa-ucm-pinephone/files/PinePhone.conf |
172 |
new file mode 100644 |
173 |
index 000000000..9a8ea12b2 |
174 |
--- /dev/null |
175 |
+++ b/media-libs/alsa-ucm-pinephone/files/PinePhone.conf |
176 |
@@ -0,0 +1,11 @@ |
177 |
+Syntax 2 |
178 |
+ |
179 |
+SectionUseCase."HiFi" { |
180 |
+ File "HiFi.conf" |
181 |
+ Comment "Play HiFi quality music" |
182 |
+} |
183 |
+ |
184 |
+SectionUseCase."Voice Call" { |
185 |
+ File "VoiceCall.conf" |
186 |
+ Comment "Make a phone call" |
187 |
+} |
188 |
|
189 |
diff --git a/media-libs/alsa-ucm-pinephone/files/VoiceCall.conf b/media-libs/alsa-ucm-pinephone/files/VoiceCall.conf |
190 |
new file mode 100644 |
191 |
index 000000000..163055986 |
192 |
--- /dev/null |
193 |
+++ b/media-libs/alsa-ucm-pinephone/files/VoiceCall.conf |
194 |
@@ -0,0 +1,151 @@ |
195 |
+SectionVerb { |
196 |
+ EnableSequence [ |
197 |
+ cset "name='Headphone Playback Switch' off" |
198 |
+ cset "name='Headphone Source Playback Route' DAC" |
199 |
+ cset "name='Line In Playback Switch' off" |
200 |
+ cset "name='Line Out Playback Switch' off" |
201 |
+ cset "name='Line Out Source Playback Route' Mono Differential" |
202 |
+ cset "name='Mic1 Playback Switch' off" |
203 |
+ cset "name='Mic2 Playback Switch' off" |
204 |
+ cset "name='AIF1 DA0 Playback Volume' 160" |
205 |
+ cset "name='AIF2 DAC Playback Volume' 160" |
206 |
+ cset "name='AIF3 ADC Source Capture Route' None" |
207 |
+ cset "name='AIF2 DAC Source Playback Route' None" |
208 |
+ cset "name='DAC Playback Switch' on" |
209 |
+ cset "name='DAC Playback Volume' 160" |
210 |
+ cset "name='ADC Digital DAC Playback Switch' off" |
211 |
+ cset "name='AIF1 Slot 0 Digital DAC Playback Switch' on" |
212 |
+ cset "name='AIF2 Digital DAC Playback Switch' on" |
213 |
+ cset "name='DAC Reversed Playback Switch' off" |
214 |
+ cset "name='Earpiece Playback Switch' off" |
215 |
+ cset "name='Earpiece Source Playback Route' DACL" |
216 |
+ |
217 |
+ cset "name='Line In Capture Switch' off" |
218 |
+ cset "name='Mic1 Capture Switch' off" |
219 |
+ cset "name='Mic1 Boost Volume' 0" |
220 |
+ cset "name='Mic1 Playback Volume' 7" |
221 |
+ cset "name='Mic2 Capture Switch' off" |
222 |
+ cset "name='Mic2 Boost Volume' 0" |
223 |
+ cset "name='Mic2 Playback Volume' 7" |
224 |
+ cset "name='Mixer Capture Switch' off" |
225 |
+ cset "name='Mixer Reversed Capture Switch' off" |
226 |
+ cset "name='ADC Capture Volume' 160" |
227 |
+ cset "name='ADC Gain Capture Volume' 7" |
228 |
+ cset "name='AIF1 AD0 Capture Volume' 160" |
229 |
+ cset "name='AIF1 Data Digital ADC Capture Switch' on" |
230 |
+ cset "name='AIF2 ADC Capture Volume' 160" |
231 |
+ cset "name='AIF2 ADC Mixer ADC Capture Switch' on" |
232 |
+ cset "name='AIF2 ADC Mixer AIF1 DA0 Capture Switch' off" |
233 |
+ cset "name='AIF2 ADC Mixer AIF2 DAC Rev Capture Switch' off" |
234 |
+ cset "name='AIF2 ADC Mixer AIF1 DA0 Capture Switch' off" |
235 |
+ cset "name='AIF2 ADC Mixer AIF1 DA0 Capture Switch' off" |
236 |
+ ] |
237 |
+ |
238 |
+ DisableSequence [ |
239 |
+ ] |
240 |
+ |
241 |
+ Value { |
242 |
+ PlaybackRate 8000 |
243 |
+ } |
244 |
+} |
245 |
+ |
246 |
+SectionDevice."Speaker" { |
247 |
+ Comment "Internal speaker" |
248 |
+ EnableSequence [ |
249 |
+ cset "name='AIF1 DA0 Stereo Playback Route' Mix Mono" |
250 |
+ cset "name='Line Out Playback Switch' on" |
251 |
+ cset "name='Line Out Playback Volume' 100%" |
252 |
+ ] |
253 |
+ |
254 |
+ DisableSequence [ |
255 |
+ cset "name='Line Out Playback Switch' off" |
256 |
+ ] |
257 |
+ |
258 |
+ Value { |
259 |
+ PlaybackVolume "Line Out Playback Volume" |
260 |
+ PlaybackSwitch "Line Out Playback Switch" |
261 |
+ PlaybackChannels 2 |
262 |
+ PlaybackPriority 300 |
263 |
+ PlaybackPCM "hw:${CardId},0" |
264 |
+ } |
265 |
+} |
266 |
+SectionDevice."Earpiece" { |
267 |
+ Comment "Internal Earpiece" |
268 |
+ EnableSequence [ |
269 |
+ cset "name='AIF1 DA0 Stereo Playback Route' Mix Mono" |
270 |
+ cset "name='Earpiece Playback Switch' on" |
271 |
+ cset "name='Earpiece Playback Volume' 100%" |
272 |
+ ] |
273 |
+ |
274 |
+ DisableSequence [ |
275 |
+ cset "name='Earpiece Playback Switch' off" |
276 |
+ ] |
277 |
+ |
278 |
+ Value { |
279 |
+ PlaybackVolume "Earpiece Playback Volume" |
280 |
+ PlaybackSwitch "Earpiece Playback Switch" |
281 |
+ PlaybackChannels 2 |
282 |
+ PlaybackPriority 500 |
283 |
+ PlaybackPCM "hw:${CardId},0" |
284 |
+ } |
285 |
+} |
286 |
+SectionDevice."Mic" { |
287 |
+ Comment "Internal Microphone" |
288 |
+ ConflictingDevice [ |
289 |
+ "Headset" |
290 |
+ ] |
291 |
+ EnableSequence [ |
292 |
+ cset "name='Mic1 Capture Switch' on" |
293 |
+ ] |
294 |
+ DisableSequence [ |
295 |
+ cset "name='Mic1 Capture Switch' off" |
296 |
+ ] |
297 |
+ Value { |
298 |
+ CapturePriority 200 |
299 |
+ CapturePCM "hw:${CardId},0" |
300 |
+ CaptureVolume "ADC Capture Volume" |
301 |
+ CaptureSwitch "Mic1 Capture Switch" |
302 |
+ CaptureChannels 2 |
303 |
+ } |
304 |
+} |
305 |
+SectionDevice."Headset" { |
306 |
+ Comment "Headset Microphone" |
307 |
+ ConflictingDevice [ |
308 |
+ "Mic" |
309 |
+ ] |
310 |
+ EnableSequence [ |
311 |
+ cset "name='Mic2 Capture Switch' on" |
312 |
+ ] |
313 |
+ DisableSequence [ |
314 |
+ cset "name='Mic2 Capture Switch' off" |
315 |
+ ] |
316 |
+ Value { |
317 |
+ CapturePriority 500 |
318 |
+ CapturePCM "hw:${CardId},0" |
319 |
+ CaptureChannels 2 |
320 |
+ CaptureVolume "ADC Capture Volume" |
321 |
+ CaptureSwitch "Mic2 Capture Switch" |
322 |
+ JackControl "Headset Microphone Jack" |
323 |
+ } |
324 |
+} |
325 |
+SectionDevice."Headphones" { |
326 |
+ Comment "Headphones" |
327 |
+ EnableSequence [ |
328 |
+ cset "name='AIF1 DA0 Stereo Playback Route' Stereo" |
329 |
+ cset "name='Headphone Playback Switch' on" |
330 |
+ cset "name='Headphone Playback Volume' 100%" |
331 |
+ ] |
332 |
+ |
333 |
+ DisableSequence [ |
334 |
+ cset "name='Headphone Playback Switch' off" |
335 |
+ ] |
336 |
+ |
337 |
+ Value { |
338 |
+ PlaybackVolume "Headphone Playback Volume" |
339 |
+ PlaybackSwitch "Headphone Playback Switch" |
340 |
+ PlaybackChannels 2 |
341 |
+ PlaybackPriority 500 |
342 |
+ PlaybackPCM "hw:${CardId},0" |
343 |
+ JackControl "Headphone Jack" |
344 |
+ } |
345 |
+} |