Example #1
0
def pycozmo_program(cli: pycozmo.client.Client):

    # Load animations - one time.
    cli.load_anims("com.anki.cozmo/files/cozmo/cozmo_resources/assets/animations/")

    # Print the names of all available animations.
    names = cli.get_anim_names()
    for name in sorted(names):
        print(name)

    time.sleep(2)

    # Play an animation.
    cli.play_anim("anim_launch_wakeup_01")
Example #2
0
def pycozmo_program(cli: pycozmo.client.Client):
    fspec = "com.anki.cozmo/files/cozmo/cozmo_resources/assets/animations/anim_codelab_tap.bin"
    clips = pycozmo.anim.load_anim_clips(fspec)
    clip = clips[0]
    cli.play_anim(clip)