Package frc.robot
Class RobotContainer
java.lang.Object
frc.robot.RobotContainer
This class is where the bulk of the robot should be declared. Since Command-based is a
"declarative" paradigm, very little robot logic should actually be handled in the
Robot
periodic methods (other than the scheduler calls). Instead, the structure of the robot (including
subsystems, commands, and trigger mappings) should be declared here.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
autoInit()
This method is run at the start of Auto.void
Use this to pass the autonomous command to the mainRobot
class.Gets thegamepieceMode
.boolean
boolean
void
setAutoChooser
(SendableChooser<Command> auto) Set the auto chooservoid
This method is run at the start of Teleop.
-
Constructor Details
-
RobotContainer
public RobotContainer()The container for the robot. Contains subsystems, OI devices, and commands.
-
-
Method Details
-
autoInit
public void autoInit()This method is run at the start of Auto. -
teleopInit
public void teleopInit()This method is run at the start of Teleop. -
getGamepieceMode
Gets thegamepieceMode
.- Returns:
- The current
gamepieceMode
.
-
isHoldingAlgae
public boolean isHoldingAlgae() -
isHoldingCoral
public boolean isHoldingCoral() -
createNamedCommands
public void createNamedCommands() -
getAutonomousCommand
Use this to pass the autonomous command to the mainRobot
class.- Returns:
- the command to run in autonomous
-
setAutoChooser
Set the auto chooser- Parameters:
auto
- a sendable chooser with Commands for the autos
-