From: iefomit Date: Thu, 23 Apr 2026 05:13:51 +0000 (-0700) Subject: mostly old clutter X-Git-Url: https://git.taranathan.com/?a=commitdiff_plain;h=06049672afab3b9166b35a0fa137889bf4c132a5;p=FRC2026.git mostly old clutter a bit unrelated to autos, but unused. --- diff --git a/src/main/java/frc/robot/RobotContainer.java b/src/main/java/frc/robot/RobotContainer.java index 9187099..429c8b5 100644 --- a/src/main/java/frc/robot/RobotContainer.java +++ b/src/main/java/frc/robot/RobotContainer.java @@ -67,9 +67,6 @@ public class RobotContainer { private Intake intake = null; private LED led = null; - // this is inside addAuto() - // private Command auto = new DoNothing(); - // Controllers are defined here private BaseDriverConfig driver = null; private Operator operator = null; diff --git a/src/main/java/frc/robot/commands/gpm/PowerControl.java b/src/main/java/frc/robot/commands/gpm/PowerControl.java index 8e93384..a0fc40f 100644 --- a/src/main/java/frc/robot/commands/gpm/PowerControl.java +++ b/src/main/java/frc/robot/commands/gpm/PowerControl.java @@ -9,8 +9,8 @@ public class PowerControl extends Command { // my beautiful power control subsystems private EMABreaker breaker; private Battery battery; + // TODO: add subsystems back when implementing logic: // the real subsystems - // TODO: implement current limit logic for these subsystems // private Drivetrain drivetrain; // private Shooter shooter; // private Turret turret; @@ -32,7 +32,6 @@ public class PowerControl extends Command { public PowerControl( EMABreaker breaker, // pc Battery battery // pc - // TODO: add subsystems back when implementing logic: // Drivetrain drivetrain, // main draw // Shooter shooter, // aiming (vital) // Turret turret, // aiming @@ -42,7 +41,6 @@ public class PowerControl extends Command { ) { this.breaker = breaker; this.battery = battery; - // TODO: add these back when implementing logic: // this.drivetrain = drivetrain; // this.shooter = shooter; // this.turret = turret; diff --git a/src/main/java/frc/robot/util/Vision/Vision.java b/src/main/java/frc/robot/util/Vision/Vision.java index d17bdd2..e1c0c2c 100644 --- a/src/main/java/frc/robot/util/Vision/Vision.java +++ b/src/main/java/frc/robot/util/Vision/Vision.java @@ -549,79 +549,7 @@ public class Vision { inputs.connected = camera.isConnected(); inputs.results = camera.getAllUnreadResults(); - Logger.processInputs("Vision/"+camera.getName(), inputs); - - // Mechanical Advantage's vision logging - // // Read new camera observations - // Set tagIds = new HashSet<>(); - // List poseObservations = new LinkedList<>(); - // for (var result : camera.getAllUnreadResults()) { - // // Update latest target observation - // if (result.hasTargets()) { - // inputs.latestTargetObservation = - // new TargetObservation( - // Rotation2d.fromDegrees(result.getBestTarget().getYaw()), - // Rotation2d.fromDegrees(result.getBestTarget().getPitch())); - // } else { - // inputs.latestTargetObservation = new TargetObservation(new Rotation2d(), new Rotation2d()); - // } - // } - // // Add pose observation - // if (result.multitagResult.isPresent()) { // Multitag result - // var multitagResult = result.multitagResult.get(); - - // // Calculate robot pose - // Transform3d fieldToCamera = multitagResult.estimatedPose.best; - // Transform3d fieldToRobot = fieldToCamera.plus(VisionConstants.APRIL_TAG_CAMERAS.get(0).getSecond().inverse()); - // Pose3d robotPose = new Pose3d(fieldToRobot.getTranslation(), fieldToRobot.getRotation()); - - // // Calculate average tag distance - // double totalTagDistance = 0.0; - // for (var target : result.targets) { - // totalTagDistance += target.bestCameraToTarget.getTranslation().getNorm(); - // } - - // // Add tag IDs - // tagIds.addAll(multitagResult.fiducialIDsUsed); - - // // Add observation - // poseObservations.add( - // new PoseObservation( - // result.getTimestampSeconds(), // Timestamp - // robotPose, // 3D pose estimate - // multitagResult.estimatedPose.ambiguity, // Ambiguity - // multitagResult.fiducialIDsUsed.size(), // Tag count - // totalTagDistance / result.targets.size(), // Average tag distance - // PoseObservationType.PHOTONVISION)); // Observation type - - // } else if (!result.targets.isEmpty()) { // Single tag result - // var target = result.targets.get(0); - - // // Calculate robot pose - // var tagPose = aprilTagLayout.getTagPose(target.fiducialId); - // if (tagPose.isPresent()) { - // Transform3d fieldToTarget = - // new Transform3d(tagPose.get().getTranslation(), tagPose.get().getRotation()); - // Transform3d cameraToTarget = target.bestCameraToTarget; - // Transform3d fieldToCamera = fieldToTarget.plus(cameraToTarget.inverse()); - // Transform3d fieldToRobot = fieldToCamera.plus(robotToCamera.inverse()); - // Pose3d robotPose = new Pose3d(fieldToRobot.getTranslation(), fieldToRobot.getRotation()); - - // // Add tag ID - // tagIds.add((short) target.fiducialId); - - // // Add observation - // poseObservations.add( - // new PoseObservation( - // result.getTimestampSeconds(), // Timestamp - // robotPose, // 3D pose estimate - // target.poseAmbiguity, // Ambiguity - // 1, // Tag count - // cameraToTarget.getTranslation().getNorm(), // Average tag distance - // PoseObservationType.PHOTONVISION)); // Observation type - // } - // } - // } + Logger.processInputs("Vision/"+camera.getName(), inputs); } /**