4. Robot positioning

 

Normally you would say that two-beacon readings do not allow exact positionnings. But with some restrictions, yes, they do! We place the IR/ultrasonic beacons at the corners of our room as shown on the picture. The beacon A is the origin of the cartesian system which will give us the robot position as C(x,y). Thus the robot will only move in the first quadrant. Note that the following calculations make only sense with slow motion robots.

 

From trigonometry we know the following identities:

 

So, the RCX_R-program must NOT compute the sinus, nor the cosinus through too complex calculations ! It must only be able to compute  the square-root. Thus, the limitations of the RCX programming under the original firmware may be easily overcome.

 

The scenario looks like:

  1. Fix the unvariable distance c

  2. Repeat:

    1. fix the variable distance a

    2. fix the variable distance b

    3. compute S, ... x, y

    4. send the coordinates to the beacons

As we want to use turnable beacons, the RCX_A and RCX_B should be able to compute the angles a and b from the coordinates, which the robot communicates to them continuously.


RetourMain Page