public class Elbow extends BaseElbow
Modifier and Type | Field and Description |
---|---|
static int |
FORWARD_LIMIT_SWITCH_TICKS |
static int |
FORWARD_SOFT_LIMIT |
static double |
MAX_ELBOW_OUTPUT |
static int |
REVERSE_LIMIT_SWITCH_TICKS |
static int |
REVERSE_SOFT_LIMIT |
Constructor and Description |
---|
Elbow() |
Modifier and Type | Method and Description |
---|---|
double |
getAngleInDegrees() |
double |
getForwardSoftLimitAngle() |
double |
getOutputCurrent()
Returns the output current
|
double |
getReverseSoftLimitAngle() |
void |
initDefaultCommand() |
boolean |
isForwardLimitPressed()
Sets the SensorCollection encoder value to encoderValue (use this to reset the encoder when at a known position
|
boolean |
isReverseLmitPressed() |
void |
sendDataToDashboard() |
void |
setClimbingCurrentLimit()
Sets the current limit for when the robot begins to climb
|
void |
setCurrentControl(int current)
Sets the elbow to Current-based PID Control
|
void |
setMotionMagicSetpointAngle(double elbowSetpointAngle)
Sets the setpoint for motion magic (in ticks)
|
void |
setNormalCurrentLimit()
Resets the currnet limit to its normal value
|
void |
setOutput(double output)
Sets the output for the elbow motor
|
void |
setQuadratureEncoder(double encoderValue)
Sets the SensorCollection encoder value to encoderValue (use this to reset the encoder when at a known position)
|
void |
updateArbitraryFeedForward()
Updates the arbitrary feed forward on this subsystem
|
clearSetpoint, enableBrakeMode, enableCoastMode, getMotionMagicSetpoint, getTimeout, moveByPercentOutput, stop
public static final int REVERSE_SOFT_LIMIT
public static final int FORWARD_SOFT_LIMIT
public static final double MAX_ELBOW_OUTPUT
public static final int FORWARD_LIMIT_SWITCH_TICKS
public static final int REVERSE_LIMIT_SWITCH_TICKS
public void setOutput(double output)
ElbowInterface
output
- the desired outputpublic double getOutputCurrent()
ElbowInterface
public void setClimbingCurrentLimit()
ElbowInterface
public void setNormalCurrentLimit()
ElbowInterface
public double getAngleInDegrees()
getAngleInDegrees
in interface ElbowInterface
getAngleInDegrees
in class RotatingSubsystem
public void initDefaultCommand()
public boolean isForwardLimitPressed()
ElbowInterface
public boolean isReverseLmitPressed()
public void setQuadratureEncoder(double encoderValue)
ElbowInterface
public void setMotionMagicSetpointAngle(double elbowSetpointAngle)
RotatingSubsystem
setMotionMagicSetpointAngle
in interface ElbowInterface
setMotionMagicSetpointAngle
in class RotatingSubsystem
public void setCurrentControl(int current)
ElbowInterface
current
- The current to control to. Positive means it will move forward, negative will move reverse.public void sendDataToDashboard()
public double getForwardSoftLimitAngle()
getForwardSoftLimitAngle
in class BaseElbow
public double getReverseSoftLimitAngle()
getReverseSoftLimitAngle
in class BaseElbow
public void updateArbitraryFeedForward()
RotatingSubsystem
updateArbitraryFeedForward
in class RotatingSubsystem