You have a while(true) in your teleopPeriodic() method. You should do that in an IterativeRobot implementation. Try changing:
Code:
@Override
public void teleopPeriodic() {
while(true) {
robotDrive1.arcadeDrive(leftJoystick.getY()*driveBaseSpeed, rightJoystick.getX());
robotDrive2.arcadeDrive(leftJoystick.getY()*driveBaseSpeed, rightJoystick.getX());
gearMotor.set(rightJoystick.getY()*gearMotorSpeed);
if(rightJoystick.getRawButton(4)) {
fuelGate.set(1.0*fuelGateSpeed);
} else if(rightJoystick.getRawButton(5)) {
fuelGate.set(-1*fuelGateSpeed);
} else {
fuelGate.set(0);
}
if(rightJoystick.getRawButton(6)) {
scissorLift.set(1.0*scissorLiftSpeed);
} else if(rightJoystick.getRawButton(7)) {
scissorLift.set(-1*scissorLiftSpeed);
} else {
scissorLift.set(0);
}
}
}
To:
Code:
@Override
public void teleopPeriodic() {
// teleopPeriodic() should do something and exit right away (it should not loop forever)
// while(true) {
robotDrive1.arcadeDrive(leftJoystick.getY()*driveBaseSpeed, rightJoystick.getX());
robotDrive2.arcadeDrive(leftJoystick.getY()*driveBaseSpeed, rightJoystick.getX());
gearMotor.set(rightJoystick.getY()*gearMotorSpeed);
if(rightJoystick.getRawButton(4)) {
fuelGate.set(1.0*fuelGateSpeed);
} else if(rightJoystick.getRawButton(5)) {
fuelGate.set(-1*fuelGateSpeed);
} else {
fuelGate.set(0);
}
if(rightJoystick.getRawButton(6)) {
scissorLift.set(1.0*scissorLiftSpeed);
} else if(rightJoystick.getRawButton(7)) {
scissorLift.set(-1*scissorLiftSpeed);
} else {
scissorLift.set(0);
}
// Removal of while(true) loop
// }
}
Hope that helps,
Paul