root / trunk / code / projects / mapping / odometry / odometry.h @ 947
History | View | Annotate | Download (617 Bytes)
| 1 | |
|---|---|
| 2 | #ifndef __ODOMETRY_C__
|
| 3 | #define __ODOMETRY_C__
|
| 4 | |
| 5 | //Odometry resolution, *64 microseconds.
|
| 6 | //= approx. 100 ms
|
| 7 | #define ODOMETRY_CLK 255u |
| 8 | |
| 9 | //Wheel = 2.613 in.
|
| 10 | //Circumference = 208.508133 mm
|
| 11 | //Distance per encoder click (circumference / 1024) = 203.621224 um.
|
| 12 | //Robot width = 5.3745 in. = 136.5123 mm
|
| 13 | |
| 14 | #define ROBOT_WIDTH_UM 137000 //um |
| 15 | #define CLICK_DISTANCE_UM 204 //um |
| 16 | |
| 17 | #define DISTANCE_SCALE 2.10526316 |
| 18 | #define ANGLE_SCALE 1.12823207 |
| 19 | |
| 20 | //Standard measures will be mm and us
|
| 21 | |
| 22 | long odometry_dx(void); |
| 23 | long odometry_dy(void); |
| 24 | double odometry_angle(void); |
| 25 | void odometry_init(void); |
| 26 | void odometry_reset(void); |
| 27 | |
| 28 | #endif
|