August 2010
Intermediate to advanced
288 pages
13h 21m
English
Each NXT motor has a Rotation Sensor built into it that measures how far the motor has turned. You can use this sensor to control how far the robot moves as an alternative to the Move block’s Duration setting. This gives you an easy way to make the program perform certain actions while the robot is moving. For example, you’ll change the BumperBot program to make the TriBot beep while backing up.
While your program is running, the Rotation Sensor tracks how far the motor has moved. You can read this value at any time, the same way you read values from the other sensors. You can also reset the Rotation Sensor value to 0, allowing you to measure how far the motor has moved between any two points in the program. (In most cases, ...