Skip to content

Commit

Permalink
Re-add feeder instance
Browse files Browse the repository at this point in the history
  • Loading branch information
camearle20 committed Feb 10, 2024
1 parent 41ae696 commit 85912ce
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions src/main/java/org/littletonrobotics/frc2024/RobotContainer.java
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@
import org.littletonrobotics.frc2024.subsystems.superstructure.arm.ArmIO;
import org.littletonrobotics.frc2024.subsystems.superstructure.arm.ArmIOKrakenFOC;
import org.littletonrobotics.frc2024.subsystems.superstructure.arm.ArmIOSim;
import org.littletonrobotics.frc2024.subsystems.superstructure.feeder.Feeder;
import org.littletonrobotics.frc2024.subsystems.superstructure.feeder.FeederIO;
import org.littletonrobotics.frc2024.subsystems.superstructure.feeder.FeederIOSim;
import org.littletonrobotics.frc2024.subsystems.superstructure.flywheels.Flywheels;
import org.littletonrobotics.frc2024.subsystems.superstructure.flywheels.FlywheelsIO;
import org.littletonrobotics.frc2024.subsystems.superstructure.flywheels.FlywheelsIOSim;
Expand Down Expand Up @@ -66,6 +69,9 @@ public class RobotContainer {
private Flywheels flywheels;
private Intake intake;
private Arm arm;

private Feeder feeder;

private DevBotSuperstructure superstructure;

// Controller
Expand All @@ -88,6 +94,7 @@ public RobotContainer() {
new ModuleIOSparkMax(DriveConstants.moduleConfigs[3]));
arm = new Arm(new ArmIOKrakenFOC());
flywheels = new Flywheels(new FlywheelsIOSparkFlex());
feeder = new Feeder(new FeederIOSim());
aprilTagVision =
new AprilTagVision(
new AprilTagVisionIONorthstar(
Expand All @@ -97,7 +104,7 @@ public RobotContainer() {
AprilTagVisionConstants.instanceNames[1],
AprilTagVisionConstants.cameraIds[1]));
// intake = new Intake(new IntakeIOSparkMax());
superstructure = new DevBotSuperstructure(arm, flywheels);
superstructure = new DevBotSuperstructure(arm, flywheels, feeder);
}
case SIMBOT -> {
drive =
Expand All @@ -110,7 +117,8 @@ public RobotContainer() {
arm = new Arm(new ArmIOSim());
flywheels = new Flywheels(new FlywheelsIOSim());
intake = new Intake(new IntakeIOSim());
superstructure = new DevBotSuperstructure(arm, flywheels);
feeder = new Feeder(new FeederIOSim());
superstructure = new DevBotSuperstructure(arm, flywheels, feeder);
}
case COMPBOT -> {
// No impl yet
Expand Down Expand Up @@ -149,8 +157,12 @@ public RobotContainer() {
arm = new Arm(new ArmIO() {});
}

if (feeder == null) {
feeder = new Feeder(new FeederIO() {});
}

if (superstructure == null) {
superstructure = new DevBotSuperstructure(arm, flywheels);
superstructure = new DevBotSuperstructure(arm, flywheels, feeder);
}

autoChooser = new LoggedDashboardChooser<>("Auto Choices");
Expand Down

0 comments on commit 85912ce

Please sign in to comment.