Skip to content

Commit ed027a6

Browse files
committedJul 13, 2020
More output for playwav
1 parent 5302dc5 commit ed027a6

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed
 

‎playwav.py

+5-3
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,13 @@ def play(device, f):
2727
else:
2828
raise ValueError('Unsupported format')
2929

30-
print('%d channels, %d sampling rate\n' % (f.getnchannels(),
31-
f.getframerate()))
32-
3330
periodsize = f.getframerate() // 8
3431

32+
print('%d channels, %d sampling rate, format %d, periodsize %d\n' % (f.getnchannels(),
33+
f.getframerate(),
34+
format,
35+
periodsize))
36+
3537
device = alsaaudio.PCM(channels=f.getnchannels(), rate=f.getframerate(), format=format, periodsize=periodsize, device=device)
3638

3739
data = f.readframes(periodsize)

0 commit comments

Comments
 (0)