Brian Bentow - Yu-min Kim - Joshua Lewis

Introduction Set Up Progress Responsibilities
AIBO Pen Lab 0 and 1 Lab 2 Lab 4 Follow Ball Score Goal

For our first second semester project we programmed the AIBO to follow its pink ball around the AIBO Pen. View Code. View Video (WMV). View Video (AVI).

Process and Challenges

Set Up

We built on our work for Lab 4 for classifying the AIBO's visual input as ball or not-ball. Initially we simply looked at the x axis centroid of the ball classified pixels and used that value to pan the head. The head moves at a velocity relative to the sqare of the error (distance from center) of the centroid. Tuning our parameters so that the dog didn't overshoot the ball and therefore get into an endless cycle of corrections was one of the main challenges at this stage.

Additional Behavior

Next we added functions to CMU's that returned the y axis centroid and the number of ball pixels detected. We used this information for tilting the head up and down and moving the dog forwards, respectively. Finally, we detected the current horizontal position of the AIBO's head and turned the body if it went outside the middle 30% of its range.

Input Smoothing

The pixel count data is very noisy, so we average pixel counts over the last 30 frames of vision data in order to smooth the input and make the AIBO's behavior more graceful. Otherwise, the AIBO would get into border states where it would alternate between being satisfied and wanting to move forward, resulting in small jerks in its legs.


We implemented three states for fulfilling this task: searching, following and satisfied. When the dog doesn't see the ball, it is searching. In this state it stands in place and rotates. If the dog sees the ball, but is not satisfied with how close it is to the ball, it is following. In this state it moves its head and body to get closer to the ball. If the dog sees the ball and the ball is close enough, the dog is satisfied. In this state is just stands still and looks at the ball.


To Do