File tree Expand file tree Collapse file tree 3 files changed +9
-6
lines changed
commands/ShooterArmCommands Expand file tree Collapse file tree 3 files changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -231,6 +231,9 @@ public static class ShooterArmConstants {
231
231
232
232
// ArmPoseReset Constant
233
233
public static final double resetPose = 0.0 ;
234
- public static final double resetSpeed = -1 ;
234
+ public static final double resetSpeed = -1.0 ;
235
+
236
+ public static final double startPose =0.0 ;
237
+
235
238
}
236
239
}
Original file line number Diff line number Diff line change @@ -22,14 +22,14 @@ public MoveShooterArmUntil() {
22
22
// Called when the command is initially scheduled.
23
23
@ Override
24
24
public void initialize () {
25
- shooterArmSubsystem .movementArmToReset ( );
25
+ shooterArmSubsystem .moveArmBySpeed ( resetSpeed );
26
26
}
27
27
28
28
29
29
// Called once the command ends or is interrupted.
30
30
@ Override
31
31
public void end (boolean interrupted ) {
32
- shooterArmSubsystem .setPosition (resetPose );
32
+ shooterArmSubsystem .setPosition (startPose );
33
33
}
34
34
35
35
// Returns true when the command should end.
Original file line number Diff line number Diff line change @@ -72,7 +72,7 @@ private ShooterArmSubsystem() {
72
72
if (!statusCode .isOK ())
73
73
System .out .println ("Arm could not apply config, error code:" + statusCode .toString ());
74
74
75
- m_ArmMotor .setPosition (0 );
75
+ m_ArmMotor .setPosition (startPose );
76
76
77
77
}
78
78
@@ -101,8 +101,8 @@ public boolean getSwitch(){
101
101
return this .limitSwitch .get ();
102
102
}
103
103
104
- public void movementArmToReset ( ){
105
- m_ArmMotor .set (resetSpeed );
104
+ public void moveArmBySpeed ( double speed ){
105
+ m_ArmMotor .set (speed );
106
106
}
107
107
108
108
You can’t perform that action at this time.
0 commit comments