Assignment 3 Information

Code submission

There are two programs for this assignment. The first is the mapping program (assign3), and the second is the map testing program (maptest). I assume most of you will do these in separate directories because that's how the support code is structured. Therefore, there are two submission pages:

If, for some reason, you've implemented these in the same directory, upload your code to the first submission page only.

Support code --- simsonar

Here is a simple sonar simulator. You can use this program to generate sonar data for a given world and motions.

You should be able to use this program without any modifications to generate simulated sonar data. You must provide a world and commands to the robot. There are several examples included.

After compiling the program, you can run it with a single argument:

$ ./simsonar Problem1.txt
By pressing 'n', the robot will execute the next command. Its position and sonar readings will be printed to the screen. You will see the robot and the sonar readings displayed on the screen. Note that the sonar cones are approximated by triangles for purposes of display. Also note that they overlap.

You may want to capture the output to a file like so:

./simsonar Problem1.txt > Sonar1.txt
Then press 'n' until nothing more happens on the screen.

To make this into a file you can use with your assign3 program, you will have to edit it to remove extraneous stuff the program prints and add the proper "header" information. See one of the sonar data files from the assignment 3 support code for examples.

Support code --- maptest

Here is support code for writing a program to evaluate the quality of your map:

This program will read in an image (saved from your assign3 program), a set of problem files (same as for assign3), and a world file.

The main thing it provides (other that this basic framework) is a procedure that calculates the area of intersection between a bounding box and a convex polygon.

Of course, you can only use this with sonar data for which you have the corresponding world file. The sonar simulator should be out soon...

Support code --- assign3