import lejos.nxt.*;
@author
public class InertiaTest
{
public static void main(String[] args)
{
LCD.drawString("Inertia Test", 0, 0);
Button.waitForPress();
rotate720();
Motor.A.resetTachoCount();
Motor.A.setSpeed(800);
rotate720();
}
public static void rotate720()
{
Motor.A.forward();
int count = 0;
while( count < 720 )count = Motor.A.getTachoCount();
Motor.A.stop();
LCD.drawInt(count , 0, 1);
while(Motor.A.getActualSpeed()>0);
LCD.drawInt(Motor.A.getTachoCount(), 7,1 );
Button.waitForPress();
LCD.clear();
}
}