Package frc.robot.subsystems
Class CellSuperstructure
- java.lang.Object
-
- edu.wpi.first.wpilibj2.command.SubsystemBase
-
- frc.robot.subsystems.CellSuperstructure
-
- All Implemented Interfaces:
edu.wpi.first.wpilibj.Sendable
,edu.wpi.first.wpilibj2.command.Subsystem
public class CellSuperstructure extends edu.wpi.first.wpilibj2.command.SubsystemBase
The CellSuperstructure is the overarching subsystem and state machine in charge of managing the intake, sorting, and shooting of balls. This class should be called by other parts of the codebase, and will pass commands along to it's sub-subsystems. Do not call the sub-subsystems independently.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static CellSuperstructure
getInstance()
Get theCellSuperstructure
instancevoid
intakeCells(int amount)
Set the subsystems to intake an amount of cellsboolean
isDone()
boolean
isDoneIntake()
void
moveToBottom()
void
periodic()
void
shootCells(int amount)
Set the subsystems to shoot an amount of cellsvoid
stop()
Set the subsystems to stopvoid
unjam()
Set the subsystems to unjamvoid
unjamUp()
Set the subsystems to unjam up-
Methods inherited from class edu.wpi.first.wpilibj2.command.SubsystemBase
addChild, getName, getSubsystem, initSendable, setName, setSubsystem
-
-
-
-
Method Detail
-
getInstance
public static CellSuperstructure getInstance()
Get theCellSuperstructure
instance- Returns:
- Instance
-
periodic
public void periodic()
-
isDone
public boolean isDone()
- Returns:
- wether or not the superStructure has completed it's actions (if it is idle or not)
-
isDoneIntake
public boolean isDoneIntake()
- Returns:
- wether or not the superStructure has completed intake
-
moveToBottom
public void moveToBottom()
-
shootCells
public void shootCells(int amount)
Set the subsystems to shoot an amount of cells- Parameters:
amount
- amount of cells the subsystems should try to shoot
-
intakeCells
public void intakeCells(int amount)
Set the subsystems to intake an amount of cells- Parameters:
amount
- amount of cells we want to be holding by the end of the action
-
stop
public void stop()
Set the subsystems to stop
-
unjam
public void unjam()
Set the subsystems to unjam
-
unjamUp
public void unjamUp()
Set the subsystems to unjam up
-
-