From 2a06f7e98d313f0e5703706e796a8246fb297dc8 Mon Sep 17 00:00:00 2001 From: Carlos Rivas Date: Tue, 5 Nov 2024 16:40:46 -0800 Subject: [PATCH] Added basic states for motor --- .../ftc/teamcode/subsystem/MotorsSubsystem.java | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/TeamCode/src/main/java/org/firstinspires/ftc/teamcode/subsystem/MotorsSubsystem.java b/TeamCode/src/main/java/org/firstinspires/ftc/teamcode/subsystem/MotorsSubsystem.java index 30fb764..e217312 100644 --- a/TeamCode/src/main/java/org/firstinspires/ftc/teamcode/subsystem/MotorsSubsystem.java +++ b/TeamCode/src/main/java/org/firstinspires/ftc/teamcode/subsystem/MotorsSubsystem.java @@ -18,7 +18,6 @@ import org.firstinspires.ftc.robotcore.external.Telemetry; public class MotorsSubsystem { public HardwareMap hardwareMap; - public Telemetry telemetry; public DcMotor frontLeftMotor; @@ -26,6 +25,12 @@ public class MotorsSubsystem { public DcMotor frontRightMotor; public DcMotor backRightMotor; + public enum TravelState { + PARKED, BUCKET, SUBMARINE + } + + public TravelState travelState; + public double power; public MotorsSubsystem(HardwareMap hardwareMap, Telemetry telemetry) { @@ -114,4 +119,12 @@ public class MotorsSubsystem { this.telemetry.update(); } + public void setState(TravelState travelState) { + this.travelState = travelState; + } + + public TravelState getState() { + return this.travelState; + } + }