Skip to content

Commit 1b7c607

Browse files
committed
create the trashbin subsystem 🗿
Signed-off-by: Dasun Abeykoon <[email protected]>
1 parent d56008b commit 1b7c607

File tree

4 files changed

+32
-1
lines changed

4 files changed

+32
-1
lines changed

src/main/java/org/frc6423/robot/Robot.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222
import org.frc6423.monologue.Monologue;
2323
import org.frc6423.monologue.Monologue.MonologueConfig;
2424
import org.frc6423.robot.Constants.Flags;
25+
import org.frc6423.robot.subsystems.trashBin.TrashBin;
26+
import org.frc6423.robot.subsystems.trashBin.TrashBinIOSim;
2527

2628
/**
2729
* Declares the structure of the robot program (subsystems, commands, triggers, etc.).
@@ -35,7 +37,7 @@ public class Robot extends CommandRobot implements Logged {
3537
private final XboxController operatorController = new XboxController(1);
3638

3739
// * SUBSYSTEM INIT
38-
/** Replace this line with subsystem declerations */
40+
private final TrashBin bin = new TrashBin(new TrashBinIOSim());
3941

4042
// * ALERT INIT
4143
private final Alert batteryBrownout = new Alert("Battery voltage output low", AlertType.kWarning);
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
package org.frc6423.robot.subsystems.trashBin;
2+
3+
import org.frc6423.lib.drivers.LoggedSubsystem;
4+
import org.frc6423.monologue.Annotations.FlattenedLogged;
5+
6+
public class TrashBin extends LoggedSubsystem {
7+
@FlattenedLogged private final TrashBinIO hardware;
8+
9+
public TrashBin(TrashBinIO hardware) {
10+
this.hardware = hardware;
11+
}
12+
}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
package org.frc6423.robot.subsystems.trashBin;
2+
3+
import org.frc6423.monologue.Logged;
4+
import org.frc6423.monologue.Annotations.Log;
5+
6+
public interface TrashBinIO extends Logged {
7+
@Log
8+
public double test();
9+
}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
package org.frc6423.robot.subsystems.trashBin;
2+
3+
public class TrashBinIOSim implements TrashBinIO {
4+
@Override
5+
public double test() {
6+
return 69.69;
7+
}
8+
}

0 commit comments

Comments
 (0)