X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=projects%2Fmicrob2010%2Ftests%2Fbeacon_tsop%2Ftrigo.h;h=15b90dc2a186ac3ca19d8d763a5610332bc1591f;hb=8b483b080955caa558615ec69cac0fb4eb7e04ef;hp=1c3178f5ea5e41d4db1541736cee492e72eae460;hpb=a56bf7c398eb727f67ed0843c6ebef948cc0dd61;p=aversive.git diff --git a/projects/microb2010/tests/beacon_tsop/trigo.h b/projects/microb2010/tests/beacon_tsop/trigo.h index 1c3178f..15b90dc 100644 --- a/projects/microb2010/tests/beacon_tsop/trigo.h +++ b/projects/microb2010/tests/beacon_tsop/trigo.h @@ -18,5 +18,16 @@ * Olivier MATZ */ +extern point_t beacon0; +extern point_t beacon1; +extern point_t beacon2; + /* get the position of the robot from the angle of the 3 beacons */ int8_t angles_to_posxy(point_t *pos, double a01, double a12, double a20); + +/* get the position and angle of the robot from the angle of the 2 + * beacons, and the distance of 2 beacons */ +int8_t ad_to_posxya(point_t *pos, double *a, int algo, + const point_t *b0, const point_t *b1, /* beacon position */ + double a0, double a1, /* seen angle of beacons */ + double d0, double d1 /* distance to beacons */ );