<<Prev 1 2 3 4 5 6 7 8 9 10 Next>>
Finding a cone
Our destination cone looks somewhat like a real traffic cone except that it is much smaller
for the sake of our purposes but its color is still very distinct. We can now use the
RGBFilter to look for something reddish as orange has red it in. The images here are taken from
the wireless camera from the point of view of the Lego Tribot.
To eliminate other red objects above the ground plane we again use our blob filtering to remove
small red objects and anything above the Y coordinate of 120. This results in a nice easy to track
red object. We again use the same tracking and movement code as we did before to now move towards
the orange cone.
Once enough of the cone is in view we assume that we are close enough and can drop the ball. It is
worth noting that the ball is obstructing the view of the cone. In reality the processed image
looks as below. Regardless, there is still enough of the cone in view to steer towards it even
with the blue ball in the grippers.
Now we know how to find the initial blue ball, when to grab the ball and are able to track
the destination code all using vision. We need to communicate this information back to the Lego
Mindstorm NXT to tell it what to do.
<<Prev 1 2 3 4 5 6 7 8 9 10 Next>>
|