diff --git a/src/main/java/frc4388/robot/Constants.java b/src/main/java/frc4388/robot/Constants.java index 1504977..554f1cf 100644 --- a/src/main/java/frc4388/robot/Constants.java +++ b/src/main/java/frc4388/robot/Constants.java @@ -131,7 +131,7 @@ public final class Constants { /* TODO: Update motor IDS */ public static final int SHOULDER_ID = 1; public static final int ELBOW_ID = 3; - public static final int GYRO_ID = -1; + public static final int GYRO_ID = 14; // TODO Update this stuff too public static final double UPPER_ARM_LENGTH = 26; // Units should be in cm diff --git a/src/main/java/frc4388/robot/subsystems/Claws.java b/src/main/java/frc4388/robot/subsystems/Claws.java index 7476238..66d84ec 100644 --- a/src/main/java/frc4388/robot/subsystems/Claws.java +++ b/src/main/java/frc4388/robot/subsystems/Claws.java @@ -105,23 +105,17 @@ public class Claws extends SubsystemBase { * @param limit The current limit. * @return Whether to interrupt the RunClaw command or not. */ - public boolean checkSwitchAndCurrent(ClawType which) { - - // if still calibrating, stop RunClaw - /*if (((Double) m_leftOffset == null) || ((Double) m_rightOffset == null)) { - return true; - }*/ - + public boolean checkSwitchAndCurrent(ClawType which) { if (which == ClawType.LEFT) { if (m_leftLimitSwitchF.isPressed() || m_leftLimitSwitchR.isPressed() || m_leftClaw.getOutputCurrent() >= ClawConstants.CURRENT_LIMIT) { return true; } - } else if (which == ClawType.RIGHT) { + } + else if (which == ClawType.RIGHT) { if (m_rightLimitSwitchF.isPressed() || m_rightLimitSwitchR.isPressed() || m_rightClaw.getOutputCurrent() >= ClawConstants.CURRENT_LIMIT) { return true; } } - return false; }