from math import * pi = 3.1415 d = open("/dev/dsp","a") for i in range(10000): d.write(str( 0*sin(2*pi*i/700)) ) d.close()