aboutsummaryrefslogtreecommitdiff
path: root/client.py
diff options
context:
space:
mode:
authorGrissess <grissess@nexusg.org>2016-06-14 02:56:53 -0400
committerGrissess <grissess@nexusg.org>2016-06-14 02:56:53 -0400
commit2cb9c95ea18906258a4fc2df1fe229d191ae5e31 (patch)
treeb042131c201687b7de1523586fa226ff64e00c69 /client.py
parentbb38c09530d7e66182c0db5205c15b143f3d5a9b (diff)
Bugfixes
Diffstat (limited to 'client.py')
-rw-r--r--client.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/client.py b/client.py
index 1680017..766b639 100644
--- a/client.py
+++ b/client.py
@@ -355,7 +355,7 @@ while True:
elif pkt.cmd == CMD.PLAY:
dur = pkt.data[0]+pkt.data[1]/1000000.0
FREQ = pkt.data[2]
- AMP = MAX * (pkt.as_float(3))
+ AMP = MAX * max(min(pkt.as_float(3), 1.0), 0.0)
signal.setitimer(signal.ITIMER_REAL, dur)
elif pkt.cmd == CMD.CAPS:
data = [0] * 8