From 2a29a1431de7ec622918d31091e7d1885d73af01 Mon Sep 17 00:00:00 2001 From: Philippe Teuwen Date: Wed, 10 Jun 2020 01:18:26 +0200 Subject: [PATCH] theremin.py: quit when pm3 button is pressed --- client/pyscripts/theremin.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/pyscripts/theremin.py b/client/pyscripts/theremin.py index 2bd1681ac..a286d6193 100755 --- a/client/pyscripts/theremin.py +++ b/client/pyscripts/theremin.py @@ -53,6 +53,8 @@ while True: if(select([pm3_proc.stdout], [], [], 0)[0]): b = pm3_proc.stdout.read(256).decode("ascii") + if "Done" in b: + break; for c in b: if c in "0123456789 mV": mv_recbuf += c