From 33a1d1392bfe509be3cf6fa000d2d7428f633b44 Mon Sep 17 00:00:00 2001 From: Sachet Korada Date: Mon, 2 Dec 2024 22:34:28 -0500 Subject: [PATCH] add safety check --- .../ftc/teamcode/subsystems/slides/ElevatorSubsystem.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TeamCode/src/main/kotlin/org/firstinspires/ftc/teamcode/subsystems/slides/ElevatorSubsystem.kt b/TeamCode/src/main/kotlin/org/firstinspires/ftc/teamcode/subsystems/slides/ElevatorSubsystem.kt index 63d49b6..e36427a 100644 --- a/TeamCode/src/main/kotlin/org/firstinspires/ftc/teamcode/subsystems/slides/ElevatorSubsystem.kt +++ b/TeamCode/src/main/kotlin/org/firstinspires/ftc/teamcode/subsystems/slides/ElevatorSubsystem.kt @@ -32,7 +32,7 @@ class ElevatorSubsystem( val clamped = if (slideAngle.invoke() < Math.toRadians(75.0)) clamp(value, 0.0, 20.0) else - value + clamp(value, 0.0, 30.0) controller.goal = TrapezoidProfile.State(clamped, 0.0) field = clamped