... | @@ -22,11 +22,11 @@ Follow the instructions at[1] |
... | @@ -22,11 +22,11 @@ Follow the instructions at[1] |
|
|------------|-------|-------|-------|------|
|
|
|------------|-------|-------|-------|------|
|
|
| Light vale | 58-59 | 36-37 | 46-47 | 56 |
|
|
| Light vale | 58-59 | 36-37 | 46-47 | 56 |
|
|
|
|
|
|
The threshold value signifies a reference light value for which the program can determine whether it is above a white or black area on the ground. A light value below the threshold leads to the conclusion that the machine is above a black area, while for a value above the threshold, a white area. As such, we would like to use the mean value of black and white as the threshold.
|
|
The threshold value signifies a reference light percentage (the desired state) for which the program can determine whether it is above a white or black area on the ground. A light value below the threshold leads to the conclusion that the machine is above a black area, while for a value above the threshold, a white area. As such, we would like to use the mean value of black and white as the threshold.
|
|
|
|
|
|
(58+36)/2 = 47
|
|
threshold = (58+36)/2 = 47
|
|
|
|
|
|
(59+37)/2 = 48
|
|
Depending on the lighting in the room, the timeday and so on, the threshold will change.
|
|
|
|
|
|
### Exercise 2
|
|
### Exercise 2
|
|
Note: the light values depend on the light level in the room in general, which makes them unreliable as general values.
|
|
Note: the light values depend on the light level in the room in general, which makes them unreliable as general values.
|
... | @@ -37,7 +37,7 @@ Note: the light values depend on the light level in the room in general, which m |
... | @@ -37,7 +37,7 @@ Note: the light values depend on the light level in the room in general, which m |
|
|
|
|
|
### Exercise 3
|
|
### Exercise 3
|
|
|
|
|
|
The sample interval indicates how often the robot should react to its environment. A large sample interval leads to a slow reaction to color shifts between black and white on the ground. All in all, a small sample interval makes the robot follow the line more precisely, while a large interval makes the movement rough.
|
|
The sample interval indicates how often the robot should react to its environment. A large sample interval leads to a slow reaction to color shifts between black and white and therefore rough movement, while a small sample interval makes the robot follow the line more precisely.
|
|
|
|
|
|
### Exercise 4
|
|
### Exercise 4
|
|
The following four graphs show the data collected from using 10ms, 50ms, 100ms and 500ms sample intervals respectively. A short sample interval is expected to update the direction of the robot often, while a slow sample interval might allow the robot to drive further away from the black line before its direction is corrected. The graph, which we have created using the DataLogger, illustrate this point well. We see for a 10ms sample rate that we first of all have a lot of data samples, but also that the curve resembles a sinus curve, which oscillates with a fairly high frequency. The same points can be made for 50ms and 100ms, although they oscillate with a lower frequency as expected. The final graph, which modulates 500ms is a special case in that the robot is not able to follow the black line for such a high sample interval. As a result it runs in circles causing the graph to be somewhat chaotic, but still with a low frequency as expected.
|
|
The following four graphs show the data collected from using 10ms, 50ms, 100ms and 500ms sample intervals respectively. A short sample interval is expected to update the direction of the robot often, while a slow sample interval might allow the robot to drive further away from the black line before its direction is corrected. The graph, which we have created using the DataLogger, illustrate this point well. We see for a 10ms sample rate that we first of all have a lot of data samples, but also that the curve resembles a sinus curve, which oscillates with a fairly high frequency. The same points can be made for 50ms and 100ms, although they oscillate with a lower frequency as expected. The final graph, which modulates 500ms is a special case in that the robot is not able to follow the black line for such a high sample interval. As a result it runs in circles causing the graph to be somewhat chaotic, but still with a low frequency as expected.
|
... | | ... | |