import sys
import time

from gameduino import Gameduino, readarray
from GDprep import spectrum

gd = Gameduino(sys.argv[1], 115200)

gd.silence()

import math
for v in range(0, 255, 63) + range(255, 0, -15):
    print v
    gd.voice(0, 1, 9000, v/2)
    time.sleep(.001)

gd.silence()
