Coasting v. Power Braking Lab
CODE : CB.i – program used to test and collect data for coasting
celerate(4,0,40,3);
motorSpeed(4,40);
goFor(3);
brake(4);
*********
CODE : CB.ii – Program used to test and collect data for power braking
celerate(4,0,40,3);
motorSpeed(4,40);
goFor(3);
brake(4);
reverse(4);
motorSpeed(4,40);
goFor(2);
********
CODE: CV.iii
celerate(4,0,40,3);
motorSpeed(4,40);
goFor(3);
brake(4);
reverse(4);
motorSpeed(4,40);
goFor(2);
brake(4);
goFor(3);
reverse(4);
celerate(4,0,40,3);
motorSpeed(4,40);
goFor(3);
brake(4);
reverse(4);
motorSpeed(4,40);
goFor(2);
**********
CODE: CV.iv
celerate(4,0,40,3);
motorSpeed(4,40);
goFor(3);
brake(4);
reverse(4);
motorSpeed(4,40);
goFor(2);
brake(4);
goFor(3);
celerate(4,0,40,3);
motorSpeed(4,40);
goFor(3);
brake(4);
reverse(4);
motorSpeed(4,40);
goFor(2);
Motor Configuration Lab
CODE: MC.i – two motors facing the same direction
//accelerate both motors from start to 40% in 2 seconds
celerate(4,0,40,2);
//run at constant speed for 3 seconds
motorSpeed(4,40);
goFor(3);
// Brake both motors.
brake(4);
CODE: MC.ii – two motors facing opposite directions
//reverse motor 1
reverse(1);
//accelerate both motors from start to 40% in 2 seconds
celerate(4,0,40,2);
//run at constant speed for 3 seconds
motorSpeed(4,40);
goFor(3);
// Brake both motors.
brake(4);