Проект

Общее

Профиль

Bug system choose sound card » История » Версия 1

Рамиль Абдулбяров, 2015-04-01 16:36

1 1 Рамиль Абдулбяров
h1. Решение проблемы когда система выбирает не ту звуковую карту по умолчанию
2
3
Смотрим выбранное утройство по умолчанию
4
5
*cat .pulse/5a779871926e26ce2bf16e0600000c57-default-sink*
6
<pre>
7
alsa_output.pci-0000_00_1b.0.analog-stereo
8
</pre>
9
10
Утилитой меняем настройки
11
*pacmd*
12
13
Смотрим список устройств
14
<pre>
15
>>> list-sinks
16
3 sink(s) available.
17
    index: 0
18
	name: <alsa_output.hw_0_0>
19
	driver: <module-alsa-sink.c>
20
	flags: HARDWARE DECIBEL_VOLUME LATENCY FLAT_VOLUME DYNAMIC_LATENCY
21
	state: SUSPENDED
22
	suspend cause: IDLE 
23
	priority: 9950
24
	volume: front-left: 85197 / 130% / 6,84 dB,   front-right: 85197 / 130% / 6,84 dB
25
	        balance 0,00
26
	base volume: 65536 / 100% / 0,00 dB
27
	volume steps: 65537
28
	muted: no
29
	current latency: 0,00 ms
30
	max request: 0 KiB
31
	max rewind: 0 KiB
32
	monitor source: 0
33
	sample spec: s16le 2ch 44100Hz
34
	channel map: front-left,front-right
35
	             Stereo
36
	used by: 0
37
	linked by: 0
38
	configured latency: 0,00 ms; range is 0,50 .. 2000,00 ms
39
	module: 5
40
	properties:
41
		alsa.resolution_bits = "16"
42
		device.api = "alsa"
43
		device.class = "sound"
44
		alsa.class = "generic"
45
		alsa.subclass = "generic-mix"
46
		alsa.name = "ALC887-VD Analog"
47
		alsa.id = "ALC887-VD Analog"
48
		alsa.subdevice = "0"
49
		alsa.subdevice_name = "subdevice #0"
50
		alsa.device = "0"
51
		alsa.card = "0"
52
		alsa.card_name = "HDA Intel PCH"
53
		alsa.long_card_name = "HDA Intel PCH at 0xfbc00000 irq 55"
54
		alsa.driver_name = "snd_hda_intel"
55
		device.bus_path = "pci-0000:00:1b.0"
56
		sysfs.path = "/devices/pci0000:00/0000:00:1b.0/sound/card0"
57
		device.bus = "pci"
58
		device.vendor.id = "8086"
59
		device.vendor.name = "Intel Corporation"
60
		device.product.id = "1c20"
61
		device.product.name = "6 Series/C200 Series Chipset Family High Definition Audio Controller"
62
		device.form_factor = "internal"
63
		device.string = "hw:0,0"
64
		device.buffering.buffer_size = "352800"
65
		device.buffering.fragment_size = "176400"
66
		device.access_mode = "mmap+timer"
67
		device.description = "Built-in Audio"
68
		device.icon_name = "audio-card-pci"
69
  * index: 1
70
	name: <alsa_output.pci-0000_01_00.1.hdmi-stereo>
71
	driver: <module-alsa-card.c>
72
	flags: HARDWARE DECIBEL_VOLUME LATENCY FLAT_VOLUME DYNAMIC_LATENCY
73
	state: SUSPENDED
74
	suspend cause: IDLE 
75
	priority: 9050
76
	volume: front-left: 53740 /  82% / -5,17 dB,   front-right: 53084 /  81% / -5,49 dB
77
	        balance -0,01
78
	base volume: 65536 / 100% / 0,00 dB
79
	volume steps: 65537
80
	muted: no
81
	current latency: 0,00 ms
82
	max request: 0 KiB
83
	max rewind: 0 KiB
84
	monitor source: 2
85
	sample spec: s16le 2ch 44100Hz
86
	channel map: front-left,front-right
87
	             Stereo
88
	used by: 0
89
	linked by: 0
90
	configured latency: 0,00 ms; range is 0,50 .. 1999,82 ms
91
	card: 0 <alsa_card.pci-0000_01_00.1>
92
	module: 8
93
	properties:
94
		alsa.resolution_bits = "16"
95
		device.api = "alsa"
96
		device.class = "sound"
97
		alsa.class = "generic"
98
		alsa.subclass = "generic-mix"
99
		alsa.name = "HDMI 0"
100
		alsa.id = "HDMI 0"
101
		alsa.subdevice = "0"
102
		alsa.subdevice_name = "subdevice #0"
103
		alsa.device = "3"
104
		alsa.card = "1"
105
		alsa.card_name = "HDA NVidia"
106
		alsa.long_card_name = "HDA NVidia at 0xfb080000 irq 17"
107
		alsa.driver_name = "snd_hda_intel"
108
		device.bus_path = "pci-0000:01:00.1"
109
		sysfs.path = "/devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1"
110
		device.bus = "pci"
111
		device.vendor.id = "10de"
112
		device.vendor.name = "NVIDIA Corporation"
113
		device.product.id = "0be3"
114
		device.product.name = "High Definition Audio Controller"
115
		device.string = "hdmi:1"
116
		device.buffering.buffer_size = "352768"
117
		device.buffering.fragment_size = "176384"
118
		device.access_mode = "mmap+timer"
119
		device.profile.name = "hdmi-stereo"
120
		device.profile.description = "Digital Stereo (HDMI)"
121
		device.description = "High Definition Audio Controller Digital Stereo (HDMI)"
122
		alsa.mixer_name = "Nvidia GPU 0b HDMI/DP"
123
		alsa.components = "HDA:10de000b,10de0101,00100200"
124
		module-udev-detect.discovered = "1"
125
		device.icon_name = "audio-card-pci"
126
	ports:
127
		hdmi-output-0: HDMI / DisplayPort (priority 5900, latency offset 0 usec, available: no)
128
			properties:
129
				device.icon_name = "video-display"
130
	active port: <hdmi-output-0>
131
    index: 2
132
	name: <alsa_output.pci-0000_00_1b.0.analog-stereo>
133
	driver: <module-alsa-card.c>
134
	flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY FLAT_VOLUME DYNAMIC_LATENCY
135
	state: SUSPENDED
136
	suspend cause: IDLE 
137
	priority: 9959
138
	volume: front-left: 54094 /  83% / -5,00 dB,   front-right: 54094 /  83% / -5,00 dB
139
	        balance 0,00
140
	base volume: 65536 / 100% / 0,00 dB
141
	volume steps: 65537
142
	muted: no
143
	current latency: 0,00 ms
144
	max request: 0 KiB
145
	max rewind: 0 KiB
146
	monitor source: 3
147
	sample spec: s16le 2ch 44100Hz
148
	channel map: front-left,front-right
149
	             Stereo
150
	used by: 0
151
	linked by: 0
152
	configured latency: 0,00 ms; range is 0,50 .. 2000,00 ms
153
	card: 1 <alsa_card.pci-0000_00_1b.0>
154
	module: 22
155
	properties:
156
		alsa.resolution_bits = "16"
157
		device.api = "alsa"
158
		device.class = "sound"
159
		alsa.class = "generic"
160
		alsa.subclass = "generic-mix"
161
		alsa.name = "ALC887-VD Analog"
162
		alsa.id = "ALC887-VD Analog"
163
		alsa.subdevice = "0"
164
		alsa.subdevice_name = "subdevice #0"
165
		alsa.device = "0"
166
		alsa.card = "0"
167
		alsa.card_name = "HDA Intel PCH"
168
		alsa.long_card_name = "HDA Intel PCH at 0xfbc00000 irq 55"
169
		alsa.driver_name = "snd_hda_intel"
170
		device.bus_path = "pci-0000:00:1b.0"
171
		sysfs.path = "/devices/pci0000:00/0000:00:1b.0/sound/card0"
172
		device.bus = "pci"
173
		device.vendor.id = "8086"
174
		device.vendor.name = "Intel Corporation"
175
		device.product.id = "1c20"
176
		device.product.name = "6 Series/C200 Series Chipset Family High Definition Audio Controller"
177
		device.form_factor = "internal"
178
		device.string = "front:0"
179
		device.buffering.buffer_size = "352800"
180
		device.buffering.fragment_size = "176400"
181
		device.access_mode = "mmap+timer"
182
		device.profile.name = "analog-stereo"
183
		device.profile.description = "Analog Stereo"
184
		device.description = "Built-in Audio Analog Stereo"
185
		alsa.mixer_name = "Realtek ALC887-VD"
186
		alsa.components = "HDA:10ec0887,18490887,00100302"
187
		module-udev-detect.discovered = "1"
188
		device.icon_name = "audio-card-pci"
189
	ports:
190
		analog-output-lineout: Line Out (priority 9900, latency offset 0 usec, available: yes)
191
			properties:
192
				
193
		analog-output-headphones: Headphones (priority 9000, latency offset 0 usec, available: unknown)
194
			properties:
195
				device.icon_name = "audio-headphones"
196
	active port: <analog-output-lineout>
197
</pre>
198
199
Изменили устройство по умолчанию
200
<pre>
201
>>> set-default-sink 2
202
</pre>
203
204
Проверяем
205
*cat .pulse/5a779871926e26ce2bf16e0600000c57-default-source*
206
<pre>
207
alsa_input.pci-0000_00_1b.0.analog-stereo
208
</pre>