/******************** * RunJimsRobot.java * * This file has the main() method to exercise the * routines in the JimsRobot class. * * @author Jim Mahoney * @version 1.0, September 30, 2002 * @see JimsRobot * **/ public class RunJimsRobot { public static void main(String[] args) throws Exception { JimsRobot j = new JimsRobot(); j.makeNoise(); // Get people's attention. j.waggleDance(); j.goForward(20.0); // Move forward about 20 cm, j.goBackward(20.0); // and back. j.turnRight(360.0); // Spin around to the right. j.goForward(40.0); // Move backward and forward j.goBackward(40.0); // about twice as far. j.turnLeft(360.0); // Spin around to the left. j.makeNoise(); // Get their attention again. j.waggleDance(); } }