for seg in range(8 * dur):
    sin_seg = sin(seg * factor) + sin(seg * factor1)
fout.write(pack('b', vol * 64 * sin_seg))
fout.close()
t = time.strftime('%S', time.localtime())
ti = time.strftime('%M', time.localtime())
tis = float(t)
tis = tis * 100
tim = float(ti)
tim = tim * 100
if __name__ == '__main__':
    pass
Using python to play two sine tones at once