SunFounder PiDog Kit, Release 1.0
(continued from previous page)
"status": STATUS_STAND,
"head_pitch": STAND_HEAD_PITCH,
},
"turn right": {
"commands": ["turn right"],
"function": lambda: my_dog.do_action('turn_right', wait=False, speed=98),
"status": STATUS_STAND,
"head_pitch": STAND_HEAD_PITCH,
},
"trot": {
"commands": ["trot"],
"function": lambda: my_dog.do_action('trot', wait=False, speed=98),
"status": STATUS_STAND,
"head_pitch": STAND_HEAD_PITCH,
},
"stop": {
"commands": ["stop"],
},
"lie down": {
"commands": ["lie down"],
"function": lambda: my_dog.do_action('lie', wait=False, speed=70),
"head_pitch": STAND_HEAD_PITCH,
"status": STATUS_LIE,
},
"stand up": {
"commands": ["stand up"],
"function": lambda: my_dog.do_action('stand', wait=False, speed=70),
"head_pitch": STAND_HEAD_PITCH,
"status": STATUS_STAND,
},
"sit": {
"commands": ["sit", "sit down", "set", "set down"],
"function": lambda: my_dog.do_action('sit', wait=False, speed=70),
"head_pitch": SIT_HEAD_PITCH,
"status": STATUS_SIT,
},
"bark": {
"commands": ["bark", "park", "fuck"],
"function": lambda: bark(my_dog, head_yrp, pitch_comp=head_pitch_init),
},
"bark harder": {
"commands": ["bark harder", "park harder", "fuck harder", "bark harbor",
˓→"park harbor", "fuck harbor"],
"function": lambda: bark_action(my_dog, head_yrp, 'single_bark_1'),
},
"pant": {
"commands": ["pant", "paint"],
"function": lambda: pant(my_dog, head_yrp, pitch_comp=head_pitch_init),
},
"wag tail": {
"commands": ["wag tail", "wake tail", "wake town", "wait town", "wait tail",
˓→"wake time", "wait time", "wait tail"],
"function": lambda: my_dog.do_action('wag_tail', wait=True, speed=100),
"after": "wag tail",
},
"shake head": {
"commands": ["shake head"],
(continues on next page)
66 Chapter 2. Play with Python