An exploration of localization, tracking, and movement algorithms for an autonomous vehicle.
This project represents the optional "hardware" project portion of CS8803, Artificial Intelligence for Robotics, taught by Dr. Sebastian Thrun, part of Georgia Tech's outstanding Online Masters of Science in Computer Science program.
Using the course material, can I program an autonomous vehicle (robot) that will:
- Navigate a physical maze, the design of which is known to the robot in advance, from a known initial position to a known goal position?
- Navigate a physical maze, the design of which is known to the robot in advance, from an unknown initial position to a known goal position?
- Navigate a physical maze, the design of which is known to the robot in advance, from an unknown initial position to an unknown goal position (the goal being identified by sensing a desired set of conditions)?
- Navigate a physical maze, the design of which is unknown to the robot in advance, from an unknown initial position to an unknown goal position (the goal being identified by sensing a desired set of conditions) while mapping the maze as it searches?
Furthermore, can I meet the above objectives in a maze that consists of:
- A single, straight corridor?
- Right angle turns?
- Right angle intersections?
- Turns and intersections at angles of other than 90 degrees?
For this project, I selected the GoPiGo robot kit from Dexter Industries. The GoPiGo is a simple, 2-wheeled vehicle with a forward-facing, servo-mounted ultrasonic range sensor, controlled by a Raspberry Pi.
I selected it for the following qualities:
- Programmable in Python.
- Complete kit - no need to identify and purchase compatible components.
- (Relatively) inexpensive at $199.
- Easy to assemble.
NOTE: I moved the range sensor from its position at the front of the robot (shown in the stock photo above) to directly over the axis of the drive wheels. This helped ensure consistent distance measurements before and after a turning or rotating motion.
- Begin a terminal session on the GoPiGo from another machine on the network. SSH works fine, but you may also use VNC to view the GoPiGo's desktop and begin a terminal session from there.
- Clone the contents of this repository to a directory on the GoPiGo.
- Start the robot with
python ./run.py
.
Note that the code requires the gopigo
Python library which comes preinstalled on the GoPiGo. The unit tests use the gopigo_stub
module so that you don't need the gopigo
library on your development machine.
- v1.0: The robot will navigate a straight corridor, with steering adjustments calculated using the PD controller algorithm.
The use of the contents of this repository is governed by the MIT License.