]> git.taranathan.com Git - FRC2026.git/commitdiff
Revert "breaking check"
authorWesley28w <wesleycwong@gmail.com>
Sat, 18 Apr 2026 13:50:57 +0000 (06:50 -0700)
committerWesley28w <wesleycwong@gmail.com>
Sat, 18 Apr 2026 13:50:57 +0000 (06:50 -0700)
This reverts commit c552358687ccd15fd5fe315af06405c69ea6a728.

src/main/java/frc/robot/subsystems/Breaker/Breaker.java
src/main/java/frc/robot/subsystems/Breaker/BreakerConstants.java [deleted file]

index e6644491e45af0e60e43a1cb83ac7ac14a45611c..7f7af64c915e6439746f90f147be5b11b0222742 100644 (file)
@@ -27,27 +27,10 @@ public class Breaker extends SubsystemBase {
         for (double index : trimmedCurrents) {
             sum += index;
         }
+        
         return sum/trimmedCurrents.size();
     }
 
-    public boolean thresholdPassed(double threshold, double secondsBackward) {
-        return average(secondsBackward) > threshold;
-    }
-
-    public boolean checkThresholdsBroken() {
-        if (
-            thresholdPassed(BreakerConstants.HALF_SECOND_THRESHOLD_AMPS, 0.5)
-            || thresholdPassed(BreakerConstants.ONE_SECOND_THRESHOLD_AMPS, 1)
-            || thresholdPassed(BreakerConstants.TWO_SECOND_THRESHOLD_AMPS, 2)
-            || thresholdPassed(BreakerConstants.FOUR_SECOND_THRESHOLD_AMPS, 4)
-            || thresholdPassed(BreakerConstants.EIGHT_SECOND_THRESHOLD_AMPS, 8)
-        ) {
-            return true;
-        } else {
-            return false;
-        }
-    }
-
     public double getCurrentFromPowerDistribution() {
         return pDis.getTotalCurrent(); // not using .getCurrent() and then an arguement for the port you can get just one port
     }
diff --git a/src/main/java/frc/robot/subsystems/Breaker/BreakerConstants.java b/src/main/java/frc/robot/subsystems/Breaker/BreakerConstants.java
deleted file mode 100644 (file)
index eba9dc6..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-package frc.robot.subsystems.Breaker;
-
-public class BreakerConstants {
-    public static final double HALF_SECOND_THRESHOLD_AMPS = 67.0;
-    public static final double ONE_SECOND_THRESHOLD_AMPS = 67.0;
-    public static final double TWO_SECOND_THRESHOLD_AMPS = 67.0;
-    public static final double FOUR_SECOND_THRESHOLD_AMPS = 67.0;
-    public static final double EIGHT_SECOND_THRESHOLD_AMPS = 67.0;
-    // TODO: add other time thresholds for the breaker
-}