thanks, Bill

[From Brian D’Agostino (2005.05.18.2158.EST)]

Bill, for about a month (on and off, unfortunately, because of other responsibilities) I’ve been working with your analysis of my robotics problem, and I find it very helpful. What you wrote can guide my work for months more, but I need to adjourn for perhaps a year because I’m now in transition to a better teaching position (High School for Mathematics, Science, and Engineering at City College) and I need to devote my full attention to that learning curve.

So far, the only modification I’ve made to your approach is to change direction by using separate motors for the wheels on the left and right sides of the robot and making one side go faster than the other, rather than using a steerable wheel. Thanks very much for your help.

Brian D’Agostino

···

----- Original Message -----

From:
Bill Powers

To: CSGNET@listserv.uiuc.edu

Sent: Monday, April 25, 2005 10:59 AM

Subject: Re: need robotics text

[From Bill Powers (2005.04.25.MDT)]
Brian D’Agostino (2005.04.24.2225) –

I need to be able to build robots using Lego parts and a Handy Board processor, with code written in Interactive C.  The robots need to be able to home in on and pick up grey plastic rings and put them in one bin, and to home in on and pick up green plastic bottles and put them into a different bin.  I have analog light and IR reflectance sensors, an optical range finder, and digital touch and slotted encoder sensors, as well as servos and motors.  Would appreciate any ideas and references any of you may have . .

This problem has several parts, and it would be good to tackle them one at a time. You need a way to alter the (1) speed of motion and the (2) direction of motion. You need a way to (3) pick up and let go of an object. You need a way to (4) sense the direction of an object relative to the arm that picks it up.

I assume that the Lego kits provide solutions to (1) and (2), and possibly (3). So if I were doing this project, I would set several groups to work on providing interfaces between the program and the actions. This is like designing the lower-order systems that will be used by the higher order systems. For example, the higher order system will need to be able to adjust a number that determines speed (rate of change of position), and another number that adjusts turn rate (rate of change of direction). Speed is controlled by changing the voltage that drives a motor; rate of change of direction is controlled by changing the angle of a steerable wheel. If you get that workling, the next level of system in the program will be able to control its perceptions just by changing the relevant numbers. If you have sensors for speed and direction you can make the lower-order systems into control systems; otherwise just concentrate on making them reliable and smooth open-loop actuators.

The hardest problem is (4), sensing the objects. Actually this has several parts. First you have to figure out how to discriminate the objects (including the bins) from the background. What are the characteristics of the objects that you have sensors to sense? You mention color and shape. But there is also position (direction and distance) relative to the pickup device. If you can devise a way to create a perceptual signal that indicates the left-right position of the object relative to the left-right position of the pickup device and the position of the pickup device relative to the position of a bin, you will have most of the problem solved. All that will remain will be to alter speed and direction until the sensed distance between the pickup device and an object is zero, actuate the picker-upper, alter speed and direction until the sensed distance between the pickup device and a bin is zero, and turn off the picker-upper.

So how can you discriminate the object from its background? Sensing shape is probably out of the question. You’d need a video camera to create a visual map of the scene, and then a very sophisticated program which I don’t believe anyone knows how to write to pick out a ring shape or a bottle shape (in any orientation and at any distance) from the background. I assume that what you have are photocells which just detect light intensity.

First you have to make the sensing directional, so the photocell sees light only from one direction. You can do that by using a lens, or less efficiently by letting it look through a tube blackened on the inside. Then you need a way to tell left from right, which means using two photocells receiving light from slightly different horizontal directions. If the signals from the photocells are representable by numbers (not just on-off), you can find the exact direction to a bright light by using the left-right movements of the robot to make the two signals equal (make the difference between signal magnitudes zero).

If you detect the object by its color, you will have the photocells looking through filters that allow only that color through. Then you wheel the robot around in a circle two or three times, measuring the intensities of light from the two photocells and picking out the maximum intensities. That allows you to set a reference level, after which you wheel around until the sensed intensities match it. The robot is then pointing toward the object , or at least to the place where that color is the most intense. Moving forward will then bring the object into contact with the picker-upper if you have placed everything correctly (move forward until the contact sensor indicates non-zero).

If you’re very clever you can get a crude kind of binocular vision out of this – suppose you could swivel one of the sighting tubes a little bit, say up to 20 degrees, relative to the other, and measure the angle when the program thinks they are seeing the same thing.

I don’t know enough of the details of your equipment and setup to be more helpful. But the obvious main problem is how to pick out an object from its background and sense its direction relative to the heading of the robot. That gives you a perceptual signal to control, and controlling it will then be relatively easy.

Best,

Bill P.

[From Bill Powers (2005.05.18.2108 MDT)]

Brian D’Agostino
(2005.05.18.2158.EST)

Bill, for about a month (on and off,
unfortunately, because of other responsibilities) I’ve been working
with your analysis of my robotics problem, and I find it very
helpful.

You have no idea how pleased I am at that. I hesitated to write back,
knowing essentially nothing of your situation and your students’
knowledge. Considering how general it was, and how nonspecific to your
needs, I am impressed that you could find useful ideas in it.

Always ready to lend a hand.

Best,

Bill P.