Monday, March 23, 2009

Chapter 9&10: Feedback & Wait for it!

Chapter 9 and 10 are all about sensors. In the first part, we learn what a condition is. A condition is something the sensor can detect such as the color on a traffic light. The Next part talked about each of the sensors: the touch sensor, sound sensor, light sensor, ultrasonic, and rotation sensors. The touch sensor is activated by the button on the front being pressed or released. In the program block for this sensor, you can choose to activate it when the sensor is bumped, released or pressed. This is useful to make the NXT look for walls and prevent damage. If the NXT has a stop block after the button is pressed, the robot will stop before the robot can damage itself. The sound sensor detects sound. In a previous investigation done last week, we found that the sensor looks for the amplitude (volume). This sensor can be programmed to respond after the sound goes above a certain level or after the sound goes below a certain level. This sensor can be used like in the drag race where we programmed it to start on a clap. The next sensor is the light sensor. The light sensor detects the amount of light. Programming it is like the sound sensor in which you can look for light greater than a certain value or less than a certain value. This is useful in applications where you must follow a line that is darker of lighter than the rest of the surface. The ultra sonic sensor sends out a signal from the sensor and it has a receiver that looks for the signal that bounces back and based on the amount of time, it can tell you how far the sensor is from a wall. making it useful in dark applications and telling your robot to stop before it gets to an obstacle. To program it, you can once again select it to wait til the value gets greater than a certain value or less than a certain value. Finally there is the forgotten rotation sensor. Most people dont realize it is there because it is built into the motor. To program this sensor, you can choose the number of degrees or rotations to wait for the motor to turn either forwards or backwards. We have used this sensor in the circuit race challenge. In this challenge, we had to calculate the number of degrees that the motors should turn so that it would go around the track without going to the inside. Wait blocks stop waiting when a command is met. All of the above applications use wait blocks

No comments:

Post a Comment