... | ... | @@ -33,9 +33,12 @@ The goal of this exercise was to measure the distance of some different objects. |
|
|
|
|
|
The cardboard and trashcan differs around 1 to 2 cm. This is ok a ok result since we properly did not get the robot to start at exactly 0 cm. Same problem with the object not being set exactly on the measured mark. The cardboard has a spike with 4 cm in difference, maybe we did not hold it orthogonal to the table. The NXT measured the trashcan closer than it was. The reason was that the trashcan was wider at the top (see picture below).
|
|
|
|
|
|
|
|
|
|
|
|
![Measure of trashcan](http://i.imgur.com/IRuta54.jpg)
|
|
|
> Setup of a measurement of trashcan
|
|
|
|
|
|
|
|
|
Ink problems
|
|
|
We experienced problems with an ink ""patron"" at a distance of 120 cm. It hits the bumps on the front of the catridge as seen on Figure and the sound goes of into another direction. Which result in the "ping" not returning.
|
|
|
|
... | ... | @@ -51,17 +54,25 @@ This shows us that the NXT continually fetches data each 30 ms, even while the p |
|
|
### Exercise 3
|
|
|
It is possible to measure a distance of 254 cm when placing the NXT on the floor 254 cm away from a large wooden box with a smooth uniform surface. It also requires a surface which is orthogonal with the sensor.
|
|
|
|
|
|
|
|
|
![254 measurements](http://i.imgur.com/iSWxEHV.jpg)
|
|
|
|
|
|
> Here we managed to measure a distance of 254 cm.
|
|
|
|
|
|
|
|
|
On an upwards angled wall the NXT could not measure beyond 101 cm and using a large plant container the limit was 175 cm.
|
|
|
|
|
|
|
|
|
![Angled wall measurement](http://i.imgur.com/pRkejJE.jpg)
|
|
|
|
|
|
> At this angled wall we could only measure up to 101 cm.
|
|
|
|
|
|
|
|
|
![Plant measurement](http://i.imgur.com/Wgo3flF.jpg)
|
|
|
|
|
|
> At this plant we could measure up to 175 cm.
|
|
|
|
|
|
|
|
|
Using the speed of sound (340,29 m/s) and the max distance of 255 cm we can calculate the time limit of the sensor:
|
|
|
|
|
|
$2,55 m * 2 / 340,29 m/s = 0,015 ms$
|
... | ... | @@ -83,9 +94,11 @@ Here’s a [video demonstration](https://vimeo.com/120279261)[3]. |
|
|
### Exercise 6
|
|
|
In this exercise the goal was to make a wall follower robot based on a program by Philippe Hurbain[4]. To to this we first had to mount an ultrasonic sensor on top of our robot and point to the side in a 45 degree angle. This makes it possible for the robot to determine whether it is getting closer to or further away from the wall.
|
|
|
|
|
|
|
|
|
![Modified robot](http://i.imgur.com/StOmWYC.jpg)
|
|
|
> A picture showing the ultrasonic sensor mounted on our robot.
|
|
|
|
|
|
|
|
|
We made a program based on the NQC program while adding some features of our own. Hurbain is using a number of if statements to decide the robots behaviour at different distances. We are using the same structure but with our own distance thresholds which were found by experimentation. This structure gives our robot six different states with variable motor settings.
|
|
|
|
|
|
Hurbain was using all 4 motor modes (forward, backward, stop float) but we ended up using only forward and backward. The reason for not using the stop mode was it would make the robot turn too aggressively if one wheel brakes and the other turns. The float mode was ineffective as the resistance on the wheel were too great for it to actually float which then gave us too sharp turns. Instead of those modes we modified the power for each motor in every state which then gave us the ability to make smoother turns when correcting the distance to the wall. Five of our states are very similar since they just reduce the power of the motor pointing in the direction we want to turn. The state reached when the distance is ‘wayTooClose’ is different because it does a right turn in place to get out of a corner.
|
... | ... | |