Fixed naming convention

This commit is contained in:
2024-12-10 16:56:24 -08:00
parent 6695140d04
commit f3154a551e
3 changed files with 9 additions and 2 deletions

View File

@ -76,6 +76,11 @@ public class PedroConstants {
*/ */
public static final String WRIST_NAME = "wrist-servo"; public static final String WRIST_NAME = "wrist-servo";
/*
Skyhook configuration name
*/
public static final String SKYHOOK_NAME = "skyhook";
/* /*
Pedro's parameters Pedro's parameters
*/ */

View File

@ -1,6 +1,7 @@
package org.firstinspires.ftc.teamcode.subsystem; package org.firstinspires.ftc.teamcode.subsystem;
import static org.firstinspires.ftc.teamcode.PedroConstants.LEFT_ENCODER; import static org.firstinspires.ftc.teamcode.PedroConstants.LEFT_ENCODER;
import static org.firstinspires.ftc.teamcode.PedroConstants.SKYHOOK_NAME;
import static org.firstinspires.ftc.teamcode.configs.RobotConstants.liftPower; import static org.firstinspires.ftc.teamcode.configs.RobotConstants.liftPower;
import com.acmerobotics.roadrunner.Action; import com.acmerobotics.roadrunner.Action;
@ -19,7 +20,7 @@ public class SkyHookSubsystem {
private SkyHookState skyHookState; private SkyHookState skyHookState;
public SkyHookSubsystem(HardwareMap hardwareMap) { public SkyHookSubsystem(HardwareMap hardwareMap) {
hook = hardwareMap.get(DcMotor.class, "skyhook"); hook = hardwareMap.get(DcMotor.class, SKYHOOK_NAME);
} }

View File

@ -1,5 +1,6 @@
package org.firstinspires.ftc.teamcode.subsystem; package org.firstinspires.ftc.teamcode.subsystem;
import static org.firstinspires.ftc.teamcode.PedroConstants.WRIST_NAME;
import static org.firstinspires.ftc.teamcode.configs.RobotConstants.wristBucket; import static org.firstinspires.ftc.teamcode.configs.RobotConstants.wristBucket;
import static org.firstinspires.ftc.teamcode.configs.RobotConstants.wristFloor; import static org.firstinspires.ftc.teamcode.configs.RobotConstants.wristFloor;
import static org.firstinspires.ftc.teamcode.configs.RobotConstants.wristPickup; import static org.firstinspires.ftc.teamcode.configs.RobotConstants.wristPickup;
@ -26,7 +27,7 @@ public class WristActionsSubsystem {
public WristState state; public WristState state;
public WristActionsSubsystem(HardwareMap hardwareMap) { public WristActionsSubsystem(HardwareMap hardwareMap) {
this.wrist = hardwareMap.get(ServoImplEx.class, "wrist-servo"); this.wrist = hardwareMap.get(ServoImplEx.class, WRIST_NAME);
} }
public class MoveToPosition implements Action { public class MoveToPosition implements Action {