1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
--- a/mkchromecast/pulseaudio.py
+++ b/mkchromecast/pulseaudio.py
@@ -13,14 +13,8 @@
'pactl',
'load-module',
'module-null-sink',
- 'sink_name=' + sink_name
- ]
-
- rename_sink = [
- 'pacmd',
- 'update-sink-proplist',
- sink_name,
- 'device.description=' + sink_name
+ 'sink_name=' + sink_name,
+ "sink_properties=device.description=" + sink_name,
]
cs = subprocess.Popen(
@@ -32,12 +26,6 @@
time.sleep(1)
- rs = subprocess.Popen(
- rename_sink,
- stdout=subprocess.PIPE,
- stderr=subprocess.PIPE
- )
- rsoutput, rserror = rs.communicate()
return
@@ -59,8 +47,9 @@
def check_sink():
check_sink = [
- 'pacmd',
- 'list-sinks'
+ 'pactl',
+ 'list',
+ 'sinks'
]
chk = subprocess.Popen(
check_sink,
|