... | ... | @@ -18,18 +18,37 @@ The plan is to follow the plan described in [1]. |
|
|
|
|
|
## Odometry
|
|
|
|
|
|
For this exercise the standard base vehicle from Lesson 6 is used together with the PilotSquare.java program provided in this lesson.
|
|
|
The parameters of the LEGO car in this program is defined as the following.
|
|
|
|
|
|
| Parameter | Value |
|
|
|
| ------------------------- |:---------------:|
|
|
|
| Left wheel diameter | 5.5 cm |
|
|
|
| Right wheel diameter | 5.5 cm |
|
|
|
| Track width | 16 cm |
|
|
|
|
|
|
The program makes the car drive 20 cm straight forward, turn 90 degrees to the left and repeat this 4 times in order to get back to the initial position.
|
|
|
A special piece of paper with multiple grids on it is used to measure the accuracy of the system. This is shown in the following image.
|
|
|
|
|
|
![Measuring physical accuracy of the DifferentialPilot class](https://gitlab.au.dk/rene2014/lego/raw/master/Lesson10/Images/Odometry.JPG)
|
|
|
|
|
|
Optimally, the LEGO car should end up in the exact same position as prior to the execution of the program. However this is not the case due to both **systematic** and **non-systematic** errors.
|
|
|
The result of the 3 test runs are summarized in the following table.
|
|
|
|
|
|
| Attempt | Measured x | Measured y | Calculated x | Calculated y |
|
|
|
| -------- |:-------------:| -----------:| ------------:| ------------:|
|
|
|
| 1 | -2.00 mm | -2.00 mm | 1.00 mm | -1.60 mm |
|
|
|
| 2 | -2.00 mm | 2.00 mm | 0.40 mm | -0.60 mm |
|
|
|
| 3 | -4.00 mm | 3.50 mm | 2.50 mm | -1.90 mm |
|
|
|
|
|
|
"Measured" x and y is the physical error measured by a ruler and "Calculated" x and y is computed error displayed in the LCD on the NXT.
|
|
|
|
|
|
The **Non-systematic** involves variations in the surface and the internal uncertainty of ~2% [2]. These errors are difficult to cope with. However the **systematic** errors involves incorrect definition of the LEGO car parameters and these can be corrected by calibration which is described in the following.
|
|
|
|
|
|
## Calibration of wheel diameter and the track width
|
|
|
|
|
|
![Calibration of LEGO car paramters](https://gitlab.au.dk/rene2014/lego/raw/master/Lesson10/Images/Calibration.JPG)
|
|
|
|
|
|
#### Initial square run with calibrated values
|
|
|
|
|
|
| Parameter | Value |
|
... | ... | @@ -86,11 +105,23 @@ The plan is to follow the plan described in [1]. |
|
|
| Track width | 16.27 cm |
|
|
|
|
|
|
|
|
|
## Position tracking by means of particle filters
|
|
|
|
|
|
Why this behavior?
|
|
|
|
|
|
Quantization error in tacho counter in each step of the trip.
|
|
|
Orientation of back wheel.
|
|
|
|
|
|
500 mm kørt distance. Afstand fra mål ~0.5 mm = dist_err = 0.001
|
|
|
Rotation error ~0.5 degrees. 0.5/360 = 0,00138
|
|
|
|
|
|
## Position tracking by means of particle filters
|
|
|
|
|
|
Hastighed ændret fra 5 til 15
|
|
|
|
|
|
Distance noise factor = 0.005
|
|
|
|
|
|
Angle noise factor = 2.5
|
|
|
|
|
|
|
|
|
## Conclusion
|
|
|
|
... | ... | @@ -98,6 +129,7 @@ Rotation error ~0.5 degrees. 0.5/360 = 0,00138 |
|
|
## References
|
|
|
|
|
|
[1] http://legolab.cs.au.dk/DigitalControl.dir/NXT/Lesson10.dir/Lesson.html
|
|
|
[2] http://lejos.sourceforge.net/nxt/nxj/tutorial/WheeledVehicles/WheeledVehicles.htm
|
|
|
|
|
|
|
|
|
### Code
|
... | ... | |