Пример #1
0
void RampKickstand() {
	servo[kickstand] = 255;
	StartTask(init);
	turnUltra(0, 0);
	turnUltra(1, 0);
	releaseTube();

	SixtyCM();

	turnUltra(0, 0);
	pause(0.3);
	tillSense(200, 90, true, 90, rearUS);
	pause(0.1);
	turnWithGyro(-50, 120);
	pause(0.1);
	releaseTube();
	pause(0.2);
	turnWithGyro(-50, 60);
	grabTube();
	move(-50);
	pause(1);
	move(0);
	pause(0.5);
	Kickstand();
	//moveDistance(100, 5);
	//servo[lift1] = WINCHSTOP;
	//servo[lift2] = WINCHSTOP;
}
Пример #2
0
void placeTube(int possision)
{
		if(possision == 1)
		{
			gyroTurn(70,50,dRight);
			travelDistance(1);
			captureTube();
		}

		else if(possision == 2)
		{
			gyroTurn(70, 50, dRight);
			travelDistance(2);
			captureTube();
		}

		else if(possision == 3)
		{
			gyroTurn(70, 45, dRight);
			travelDistance(1);
			captureTube();
		}

		else
		{

		}
releaseTube();
}