Skip to content

Commit 0aca4ab

Browse files
committed
[#1] Fixes tone geneation math.
1 parent ec88f42 commit 0aca4ab

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

PythonBlueBox.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
continue
7575

7676
stream.write(array.array('f',
77-
((volume * math.sin(i / (tone[0] / 100.)) + volume * math.sin(i / (tone[1] / 100.)))
77+
((volume * math.sin(2.0 * math.pi * i * tone[0] / sr) + volume * math.sin(2.0 * math.pi * i * tone[1] / sr))
7878
for i in range(int(sr*length)))).tostring())
7979

8080

0 commit comments

Comments
 (0)