2
0
mirror of https://github.com/team2059/Zaphod synced 2024-12-18 20:12:28 -05:00

Added a safety check for collecting the ball. Checks that the shooter arm is down before allowing the motor to be spun forwards.

This commit is contained in:
Adam Long 2014-04-03 13:58:02 -07:00
parent 69ded3ddad
commit 7d276da7a9

View File

@ -595,7 +595,7 @@ public:
//}}} //}}}
} }
//Collector Motor{{{ //Collector Motor{{{
if(Lstick.GetRawButton(11)==1){ if(Lstick.GetRawButton(11)==1&&50<=potToDegrees(armPot.GetAverageVoltage())){
setMotorValue(6,1,1); setMotorValue(6,1,1);
}else if(Lstick.GetRawButton(12)==1){ }else if(Lstick.GetRawButton(12)==1){
setMotorValue(6,1,255); setMotorValue(6,1,255);