[mowbot] Questions?

david steinke (dsteink nospam at dakotacom.net)
Fri, 30 Apr 1999 14:32:37 -0700

I actually tried to post about 3 weeks ago but had lost the new address
due to a virus attack (wonderful java code that just modified files by
rearranging contents). I was hoping someone would post. So if I can
remember, here is what I wrote.

My mechanics are close to being done. The robot can rotate within its
own area. It has a ground speed of 2 inches per second and it can go
foward, reverse, and rotate in either direction. It can also count wheel
rotations/angle change from an optical encoder on the drive motors.

Now I need a control program which I would like to keep very simple. My
yard is a rectangle oriented north-south. On the west end are
semi-circular tree wells jutting in. The entire grass area is surrounded
by a 2" or higher vertical barrier. I thought of using an electronic
compass to determine direction and a simple bumper for foward motion
limit. Here is my homing sequence.

1. rotate to point north
2. head north until limit
3. rotate east
4. head east until limit
5. rotate north
6. head north until limit

I figure that should get the robot to the north east corner of the yard
unless the kids leave things in the grass. To cut, the robot would:

1. rotate west
2. head west until limit
3. rotate south
4. move south 4" or until limit(cutting width is 8", so this leaves
5. rotate east
6. head east until limit
7. rotate south
8. move south 4" or until limit
9. rotate west
10. etc

I figure I can do this with about 200 lines of code on a PIC. When the
robot hits the southern limit on the east edge, it is done. My questions

a. How sensitive are the electronic compasses to permanent magnet motors
nearby (within 4")?

b. Could I possibly do it with an infared beam pointed south along the
eastern edge? If I use a standard 40khz infared sensor with a narrow
horizontal aperture (less than 1 degree) and a simple 40khz modulated
beacon, the robot could rotate on the eastern edge until it is oriented.
Since the robot can also rotate precisely (more or less), the robot
could just reorientate the on the eastern edge. Initial homing would be
more time consuming, but still easy.

c. Is there a simpler way?