From 16d35e42ec9600043fb989faace0ca83addb4fea Mon Sep 17 00:00:00 2001 From: Sachet Korada Date: Sun, 17 Nov 2024 17:55:37 -0500 Subject: [PATCH] Sample Blue Park --- .../auto/blue/park/BlueParkObservationLeft.kt | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 TeamCode/src/main/kotlin/org/firstinspires/ftc/teamcode/opModes/auto/blue/park/BlueParkObservationLeft.kt diff --git a/TeamCode/src/main/kotlin/org/firstinspires/ftc/teamcode/opModes/auto/blue/park/BlueParkObservationLeft.kt b/TeamCode/src/main/kotlin/org/firstinspires/ftc/teamcode/opModes/auto/blue/park/BlueParkObservationLeft.kt new file mode 100644 index 0000000..16d7ea9 --- /dev/null +++ b/TeamCode/src/main/kotlin/org/firstinspires/ftc/teamcode/opModes/auto/blue/park/BlueParkObservationLeft.kt @@ -0,0 +1,25 @@ +package org.firstinspires.ftc.teamcode.opModes.auto.blue.park + +import com.qualcomm.robotcore.eventloop.opmode.Autonomous +import com.qualcomm.robotcore.eventloop.opmode.OpMode +import org.firstinspires.ftc.teamcode.constants.AutoStartPose +import org.firstinspires.ftc.teamcode.subsystems.drive.DriveSubsystem + +@Autonomous(name = "Blue Park (Observation) Left", group = "Observation", preselectTeleOp = "MainTeleOp") +class BlueParkObservationLeft : OpMode() { + private lateinit var driveSubsystem: DriveSubsystem + + override fun init() { + driveSubsystem = DriveSubsystem(hardwareMap) + + val trajectory = driveSubsystem.trajectorySequenceBuilder(AutoStartPose.BLUE_LEFT.startPose) + .strafeRight(48.0) + .build() + + driveSubsystem.followTrajectorySequenceAsync(trajectory) + } + + override fun loop() { + driveSubsystem.update() + } +} \ No newline at end of file