Testing Code For Coasting:
//accelerate all motors from 0 % power to 40% power in 2 seconds.
celerate(4,0,40,2);
//run at current speed for 2 seconds.
goFor(2);
//brake all motors.
brake(4);
Test Code For Power Braking:
//accelerate all motors from 0 % power to 40% power in 2 seconds.
celerate(4,0,40,2);
//run at current speed for 2 seconds.
goFor(2);
//brake all motors.
brake(4);
//reverses the polarity of all motors
reverse(4);
//accelerate all motors from 0 % power to 20% power in 2 seconds.
celerate(4,0,20,2);
//run at current speed for 2.2 seconds.
goFor(2.2);