Classes - Beard

You are here: start » robot_soccer » notes



Notes and Other Useful Material

Robot Soccer Notes


  • Latest version. Check back regularly for updates.

TA Materials

ODroid U3 and Ubuntu 14.04


Udacity - Kalman Filters This contains a useful explanation of what the Kalman Filter is actually doing. You don't need to register or pay for the course - just use the materials and lecture videos.

A gentle intro to ROS This book is a bit long but provides a good set of tutorial uses of ROS and shows a few power uses of ROS (such as launch files). This book is linked to below as well in the section on ROS.

ROS Cheat Sheet A simple cheat sheet for many common ROS operations. The information is based on ROS Hydro but should be almost entirely valid on ROS Indigo.

OpenCV Tutorials Thse are good tutorials about OpenCV, which let you get a good general idea of some of the functionality you may want to use. I also recommend installing OpenCV and learning how to compile the programs in general.

Motor pinouts

Odroid GPIO pins

Old Roboclaw Datasheet

Newer (too new?) Robotclaw Datasheet

This is a document on the functionality of the roboclaw. I would suggest focusing attention on the first few pages (introduction, pinout, inputs, status LEDs, setup, and everything through ~p. 12), baud rates, and the packet serial mode (pp. 25- 38, with emphasis on the advanced packet serial because of the finer-grained control from PIDs), quadrature decoding (pp. 39-42), and advanced motor control (pp. 43 - 52). See what modes you can pick out that look as if they may be helpful. The Arduino code may or may not be helpful, I kind of wrote my own last year so I don't know what this code demonstrates.

Presentation on robot architecture, 14 Jan 2015

Presentation on ROS, 2 Feb 2015

Code and tips from 2014

I'm not sure if you have access to these yet. Let me know if you can't get to them.

Critical Path Group Materials

Motion Control Group Resources

Vision Group Resources Some of this may be deprecated as it references the Minnowboard; however, there is some potentially useful information here.


Mechanical System

(old) motors_batteries.pdf

(old) robot_construction.pdf

(old) models_for_mobile_robots.pdf This file is important in the sense that it contains the model for a DC motor, and also explains how pulse width modulation works. There is also an explanation of how to model the time between expected battery charges.

(old) motor_model_and_control.pdf There are useful things in this file including the relationship between angular speed of a wheel and its linear velocity, how to use system identification to find motor constants. Most of the rest of the material is contained in other files.


  • Updated 2/24/2014.
  • To be used for first simulator competition.

  • Updated 3/6/2014.
  • To be used for second simulator competition.
  • Ball interactions are modeled with spring forces. This sometimes leads to some odd behaviors on some bounces. There are other bugs and odd behaviors that need to be fixed.
  • Kalman filter to estimate self position of one robot from range and bearing measurements of marker.
  • Kalman filter to estimate ball position. Works ok until the robot estimating the position touches ball, and then the estimate diverges. Something obviously wrong with estimator.

(old) robot_model_two_wheel.pdf

(old) homework_three_wheel_model.pdf

(old) mobile_robot_kinematics.pdf

(old) two_wheel_model.pdf

(old) Simulink files of a three wheeled robot including motor dynamics. (Old)

(old) Simulink files of two teams of three wheeled robots with velocity inputs. (Old)

(old) Old Simulink simulation of one-on-one robot soccer game. Out of date and needs modifications to run.

(old) Old Simulink simulation of robot maneuvering to push the ball in the goal.

(old) Old robot soccer simulator written in C. We used to compile this on Linux, but I haven't done it for many years and not sure how anymore.

(old) I have two directories with C projects. This project may actually be our old simulator and not the file above.

Stepping back - This is useful to go back to replay goals so you can improve algorithms

Debugging Matlab Code - Frustratingly enough, Simulink doesn't usually tell you the line number of your errors. So here is some useful code that prints out the entire error message in the console. Surround the code causing the error with a try catch as follows:

function u = robot_ctrl(uu, P)
		u = robot_ctrl_that_has_an_error(uu, P);
	catch e
		msgString = getReport(e);
		fprintf(2,'%s\n', msgString);

Mex functions - If, while porting your code to C or C++ you wish to test it, this is a great tool! Requires Matlab GCC add-on package; follow instructions to install.

Motion Control


  • Derives kinematic relationship between commanded world speeds and commanded wheel speeds.
  • Presented in class on 1/15/2014.


  • Discusses planning paths to push ball into the goal.
  • Assumes the ability to predict the future location of the ball.
  • Updated for three wheel robots.


  • Overview of the Rapidly exploring Random Tree (RRT) algorithm for path planning.
  • From Beard, McLain, Small Unmanned Aircraft, Princeton University Press, 2012.
  • Discussed on 2/10/2014.

  • Matlab code that implements the RRT algorithm.
  • From Beard, McLain, Small Unmanned Aircraft, Princeton University Press, 2012.


  • Old but useful.
  • Path planning using potential field methods.


  • almost identical material to motion_planning.pdf except it contains a section on ball prediction.
  • Need to combine the two files.

(old) velocity_control_three_wheel.pdf

(old) control.pdf

(old) closed_loop_two_wheel.pdf

(old) motion_control_two_wheel.pdf

(old) ball_prediction.pdf

(old) ball_prediction2.pdf

(old) velocity_control_two_wheel.pdf

(old) goal_tending.pdf

(old) goal_scoring_intercept.pdf

(old) path_planning.pdf

(old) Simulink simulation of model reference adaptive control of a DC motor.

Vision and State estimation


  • Updated 3/26/2014
  • Estimate of own position, ball position, and position of other robots based on static geometry.
  • Could be used in place of Kalman filter, or perhaps as input to a Kalman filter.
  • Requires view of two marker.


  • Updated 3/6/2014.
  • Derivation of the Kalman filter and application to finding the position and orientation of self, given range and bearing measurements to the markers.
  • Kalman filter for position and velocity of ball.
  • Kalmann filter for position and velocity of other robots.


  • Slides describing computer vision tools for robot soccer.

  • OpenCV examples.
  • Includes Makefile and C++ file showing OpenCV examples, including capturing image, resizing, blurring, edge detection, and color thresholding.
  • Runs on Mac without modification.

(old) vision_book_chap3.pdf

(old) ecen490_2-_video_and_color_space.ppt

(old) feature_detection.pdf

(old) vision_color_segmentation.pdf

(old) three_wheel_ekf.pdf


  • This is a simulink simulation of a Kalman filter estimating the state of a two wheeled robot.
  • The implementation method is dated, using global variables.
  • The simulation assumes an overhead camera with zero mean Gaussian noise.

ROS Architecture and Artificial Intelligence Strategies


  • Potential architectures for intelligent play
  • Deliberative vs. reactive planning
  • Path planning ideas using Voronoi and visibility graphs.

Beginners Guide to ROS

  • A Gentle Introduction to ROS is designed to ease the learning curve for new ROS users.
  • Aims to supplement the existing tutorials and documentation for basic concepts like nodes, topics, messages, resource names, launch files, parameters, services, and more.
  • Example programs in C++.
  • Does not assume any previous experience with ROS, and includes warnings about some pitfalls that, in the author's experience, are often troublesome for beginners.
  • The goal is that, after reading this book, beginners should have a strong foundation to understand and explore the ROS ecosystem on their own.

(old) robot_soccer_decide_and_act.pdf

(old) software_architecture.pdf