예제 #1
0
def dance(r, num_repeats=1):
    """First light up, then play a distinctive sound, continue with 
    a robot dance

    Keyword arguments:
    r -- robot object and serial connection
    num_repeats -- number of loops to run

    Returns: nothing, changes lights, makes sound and moves.

    """
    for i in range(num_repeats):
        look_around(r)
        c_chord(r)
        spin(r)
        shake(r)
        twist(r)
예제 #2
0
 def test_look_around(self):
     r = create.Create(SERIAL_PORT)
     light.look_around(r)
     r.shutdown()