1516b Over Under 2.0
Codebase for 1516b over under season
|
The Autonomous class contains classes and functions related to the robot's autonomous behavior. More...
#include <auton.h>
Public Member Functions | |
void | AutoDrive (Puncher &puncher, bool autono) |
Drives the robot autonomously. | |
void | AutonSwitcher () |
Switches the autonomous program. | |
Static Public Attributes | |
static int | auton = 1 |
Sets the number of the autonomous program to use. | |
Private Member Functions | |
void | Auton1 () |
Runs the autonomous path for the far side defensive game strategy. | |
void | Auton2 () |
Runs the autonomous path for the near side offensive game strategy. | |
void | Auton3 (Puncher &puncher) |
Runs the puncher routine for the Skills Challenge. | |
The Autonomous class contains classes and functions related to the robot's autonomous behavior.
We use Lemlib extensively for our documentation. You can find the documentation for Lemlib at Lemlib documentation.
void Autonomous::AutoDrive | ( | Puncher & | puncher, |
bool | autono = false ) |
Drives the robot autonomously.
This function drives the robot autonomously based on the selected autonomous program. It takes a reference to a Puncher object and a boolean value indicating whether to use autonomous mode.
puncher | A reference to the Puncher object. |
autono | A boolean value indicating whether to use autonomous mode. |
Definition at line 60 of file auton.cpp.
References auton, Auton1(), Auton2(), Auton3(), and AutonSwitcher().
Referenced by autonomous().
|
private |
Runs the autonomous path for the far side defensive game strategy.
This function executes the autonomous path for the far side defensive game strategy. It contains the specific actions and movements required for this strategy.
Definition at line 11 of file auton.cpp.
References auton, and Robot::Globals::chassis.
Referenced by AutoDrive().
|
private |
Runs the autonomous path for the near side offensive game strategy.
This function executes the autonomous path for the near side offensive game strategy. It contains the specific actions and movements required for this strategy.
Definition at line 31 of file auton.cpp.
References auton, and Robot::Globals::chassis.
Referenced by AutoDrive().
|
private |
Runs the puncher routine for the Skills Challenge.
This function executes the puncher routine for the Skills Challenge. It takes a reference to a Puncher object and performs the necessary actions for the challenge.
puncher | A reference to the Puncher object. |
Definition at line 51 of file auton.cpp.
References auton, and Robot::Puncher::run().
Referenced by AutoDrive().
void Autonomous::AutonSwitcher | ( | ) |
Switches the autonomous program.
Make sure to pass in a reference to the Puncher object with .
This function switches the autonomous program to the next available program. It allows the user to cycle through different autonomous programs during runtime.
Definition at line 82 of file auton.cpp.
References auton, and Robot::Globals::controller.
Referenced by AutoDrive(), and Robot::Utility::toggleSubsystemOptions().
|
static |
Sets the number of the autonomous program to use.
This function allows the user to specify the autonomous program to be executed by the robot. The autonomous program number determines the specific actions and movements the robot will perform.
auton | The number of the autonomous program to use. |
Definition at line 22 of file auton.h.
Referenced by AutoDrive(), Auton1(), Auton2(), Auton3(), and AutonSwitcher().