Alexis Lussier Desbiens - http://alexisld.cjb.net
Magnetic compass are not very useful on a robot, particularly near electric motors! I didn't perform any real testing about magnetic compass on my robot, but I am pretty sure that they won't give an accurate result near 16 motors that draw 2amp each at peak! You can place your magnetic compass far from the robot, as they did on Ariel from ISrobotics but I don't like this solution. I want a circuit who can give me a constant heading information... even if it's not the north (I can calibrate my circuit with a compass before starting the motors on my robot). A little bit like the job gyroscope are doing in an helicopter or in an airplane. But gyroscope cost 200$ and more!!
Insects had found an interresting solution to this problem (even if they don't have 16 motors on-board!)... They use the polarization pattern of the sky1. Depending on the angle the light from the sun hits the atmosphere, the light is polarized in a special way. Those patterns maintain an interresting characteristic all over the day : they are always perpendicular to the solar meridian (the line between the sun and the zenith [highest point in the sky, just over you]). This line is rotating around the zenith because the position of the sun is changing... at a rate of 360degrees/24h = 15degrees/h (not true... but we will see why in a few moment). Rox-544 v.2 have a clock onboard... so, if I am able to find the solar meridian, and I have the time elapsed since the last orientation's update, I am able to find my current orientation.
To build a POL-OP unit, you need ~20$: IMAX polarized glasses (I bought mine from "Reel 3-D enterprises Inc" www.reel3d.com), two photoresistors, an op-amp and some resistors. You can see on the picture the polarized glasse and my first POL-OP unit.
This is the second unit that I built... the black tubes in the first one was too short, the unit was catching light from a too big area in the sky (It's important to always look at the zenith).
The POP-OP unit consist of two photoresistors at the base of the black tubes. Each photoresistor is cover by a polarized filter (from the IMAX glasses). The filters on the two photoresistor should be place so that one photoresistor will see horizontal light and the other vertical light (90 degrees between the two filter). The two photoresistors form a voltage divider. The voltage at the jonction of the two photoresistors is plug to the input of an OP-AMP. In this configuration, the output depends only of the degree of polarization of the sky... and not of the ambient light. The gain of the OP-AMP was found by doing simulation of the circuit on MATLAB. The POL-OP unit is place on the top of a servo to scan the sky.
When I scan the sky, I found a sine wave where the max. is the position of the solar meridian and the min. is the [solar meridian + 90 degrees]. The only problem is that when I scan at each 2.5 degrees, the ouput of the A/D can give something like : 180, 187, 195, 200, 200, 200, 195, 187, etc. So I don't have only one max. position... One solution could be to use a 12 bit A/D... but I chose to just record the first position of the max. and the last one, add the two and find the middle position...
And the results are:
(green and red line with yellow dots around are the position (in degrees, it is why the green line pass from 180 to 0 degrees...) of the solar meridian and the [solare meridian + 90 degrees]. The red line is the max. value return by the POL-OP v.2, the blue line the min. value return by the POL-OP v.2 and the black line the degree of polarization of the sky (red line - blue line)
The data on this graph were recorded on a day when the sky was [very] clear. By using a rate of change of the solar meridian of 15 degrees/h, we reach a accuracy of +-5 degrees. The problem is that the rate of change of the solar meridian is not constant because of the trajectory of the sun. Insects have a "ephemeris" function who describe the rate of change of the sun (this fonction vary depending of the season and the position on the earth). We can predict this function... but we can also learn it, as insects are doing. We just need a compass, find the position of the solar meridian in fonction of the north, then find the time of the day and record the rate of change of the solar meridian at this time... after several day, of the compass should reach a precision of less than +-1 degrees... without having to tell your robot where you are on the earth and at which time of the day!
Those data were recorded during a partly cloudy day... We can see that the information about the orientation of the unit from 7h to 11h are not useful at all. But, we can also see that the degree of polarization (black line) of the sky is also very low < 50 instead of the 150 on the other graph. So, the POL-OP unit does not only tell us the orientation of the robot... but it also tell us when it becomes crazy! ;-) It is because clouds in the sky "destroy" the pattern of polarization.
Results are valid a little bit after the sunset because the unit only look for the degree of polarization.
This system, with the help of a magnetic compass, give us many informations : time of the day like a sundial), position of the north and the validity of the position. I don't have a system that will learn the ephemeris function at this time (I am waiting for the end of the winter...) or a system that works with the help of a magnetic compass... But, as soon as the outside temperature (it's -15C today) will allow my electronics to go outside... I will try this!
Alexis Lussier Desbiens - http://alexisld.cjb.net
1. LAMBRINOS, Dimitrios, Ralf MÍLLER, Thomas LABHART, Rolf PFEIFER et RŘdiger WEHNER, A mobile robot employing insect strategies for navigation, AI Lab, Department of Computer Science, University of Zurich, 19 fÚvrier 1999.