summaryrefslogtreecommitdiff
path: root/examples/play_file.py
diff options
context:
space:
mode:
authorMatthias Geier <Matthias.Geier@gmail.com>2017-02-16 20:44:39 +0100
committerMatthias Geier <Matthias.Geier@gmail.com>2017-02-16 20:45:47 +0100
commit32fdcda970f2f2a2e9f979d5759a4c2cd8d53c54 (patch)
treef838be474266904e2f25546c655ef1e471760eb0 /examples/play_file.py
parent747030a8a6db88f7541f773fabae00cdb2c145b9 (diff)
play_file example: use wait() instead of blocking=True
Diffstat (limited to 'examples/play_file.py')
-rwxr-xr-xexamples/play_file.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/play_file.py b/examples/play_file.py
index cf78815..c474a63 100755
--- a/examples/play_file.py
+++ b/examples/play_file.py
@@ -29,8 +29,8 @@ try:
import sounddevice as sd
import soundfile as sf
data, fs = sf.read(args.filename, dtype='float32')
- sd.play(data, fs, device=args.device, blocking=True)
- status = sd.get_status()
+ sd.play(data, fs, device=args.device)
+ status = sd.wait()
if status:
parser.exit('Error during playback: ' + str(status))
except KeyboardInterrupt: