Data Modified: April 19, 2016
Note: texts in black are actual codes, tests in green are comments.
void myCode()
{
double gc=-150,s1=28,s2=305,s3=556;
int flat=32;
rotateServo(30);
celerate(4,0,26,2);
goToAbsolutePosition(-129); //gc
reverse(4);
motorSpeed(4,14);
goToAbsolutePosition(-183);
brake(4);
goFor(2);
rotateServo(0);
celerate(4,0,33,2);
goToAbsolutePosition(-105);
reverse(4);
motorSpeed(4,22);
goToAbsolutePosition(s1); //stop 1
brake(4);
delay(2000);
reverse(4);
celerate(4,0,30,1.5);
goToAbsolutePosition(s2); //stop 2
brakes(29);
goFor(2);
delay(1000);
celerate(4,0,57,4);
goToAbsolutePosition(s3); //stop 3 top of ramp
brakes(24);
goFor(3);
reverse(4);
celerate(4,0,16,.4);
goToAbsolutePosition(530);
reverse(4);
motorSpeed(4,78);
goFor(1);
celerate(4,78,58,.25);
delay(1000);
brake(4);
reverse(4);
celerate(4,0,18,3);
motorSpeed(4,18);
goFor(1);
reverse(4);
goToAbsolutePosition(339); //not actually stop 3, heading back down
celerate(4,0,20,.5);
motorSpeed(4,20);
goFor(1.5);
brake(4);
goFor(2);
reverse(4);
celerate(4,0,24,2);
goToAbsolutePosition(-130);
reverse(4);
motorSpeed(4,15);
goToAbsolutePosition(-180); //back to grand canyon
brake(4);
goFor(2);
rotateServo(30);
delay(1500);
celerate(4,0,23,2);
goToAbsolutePosition(-95);
reverse(4);
motorSpeed(4,21); //good
goToAbsolutePosition(5); //stop 1
goFor(1.5);
reverse(4);
}