light sensor "sees white" then we know it is left of the line's edge (and the
line). If it "sees black" then we know it is to the right of the line's edge
(and on the line). This is called a "left hand
line follower" since it is following the line's left edge
We need to know what values the light sensor returns when it "sees white" and
when it "sees black". A typical uncalibrated sensor might give a "white" reading
of 50 and a "black" reading of 40 (uncalibrated, on a 0 to 100 scale). It is
convenient to draw the values on a simple number line to help visualize how we
convert light sensor values into changes in the
robot's movement.
Below are our made up light values for white and black.
We'll just divide the range into two equal pieces and say that if the light
level is less than 45 we want the robot to turn left. If it is greater than 45
we want to turn right. I won't go into how exactly the turns should be done.
I'll just say that gentle turns work well for a fairly straight line
line with lots of curves usually needs to be making sharper turns. For gentle
turns you might use Power levels of 50% on the fast wheel and 20% on the slow
wheel. For sharper turns on a curvy line you might need to use 30% power for the
fast wheel and coast or brake the slow wheel. Whatever power levels you use the
numbers will be the same for the two turns, you just switch which motor gets the
big number and which get the smaller number (or a stop command).
This type of a line follower will follow a line but it isn't very pretty. It
looks OK on a straight line with with the motors programmed for gentle turns.
But if the line has any curves then you have tell the robot to use sharper turns
to follow line. That makes the robot swing back and forth across the line. The
robot only "knows" how to do two things; turn left and turn right. This approach
can be made to work but it is not very fast or accurate and looks terrible.
In the above approach the robot never drives straight, even if it is
perfectly aligned with line's edge and the line is
straight. That doesn't seem very efficient does it?
Lets try to fix that. Instead of dividing our light value number line into
two regions lets divide it into three.
the top of this article explains how it would be easier to follow the edge of the line rather than the center of the line. As it detects the white it will turn back to the black and as it detects the black it will turn back to the white.
LabVIEW 2009 LEGO MINDSTORMS NXT Module Help Logs Data from the specified sensor connected to the specified port. The data logging parameters are sample time and total time.For the Red Vis, the data is stored in the RedData.dat file on the NXT brick and can be viewed using the Data Viewer application.
we could use this logic, when the sound sensor detects the sound indicating the start of the race that would be the starting condition for the program
ps. i know that we do not use the same programming as in the picture
this would be a rather complicated idea for our robot but we should figure out a way to have more weight like this one so it stays on the ground. we would need to lower the nxt brick so it does not tip
While Roomba is cleaning, it avoids steps (or any other kind of drop-off) using four infrared sensors on the front underside of the unit. These cliff sensors constantly send out infrared signals, and Roomba expects them to immediately bounce back. If it's approaching a cliff, the signals all of a sudden get lost. This is how Roomba knows to head the other way
Roomba can clean for about two hours on a single charge. If you have the
self-charger, Roomba will return and connect to the charger all
by itself when the battery power is low (the self-charger is sold as an add-on
to the Roomba base model but comes included on most of the higher Discovery
models). It accomplishes this using the infrared receiver on its front bumper.
When the battery power gets low, the vacuum starts looking for the infrared
signal emitted by the charger. Once it finds it, Roomba follows the signal and
docks itself to the charger. Some robotic vacuums with this self-charging
feature will head back out to resume cleaning once they're fully recharged