2
0
mirror of https://github.com/team2059/Dent synced 2024-12-18 20:52:29 -05:00

Continued working on documentation

This commit is contained in:
Austen Adler 2015-03-02 08:28:03 -05:00
parent d35d8e95b4
commit c2d8ef3eea
8 changed files with 90 additions and 7 deletions

View File

@ -13,7 +13,8 @@
*/ */
class AutoDrive: public Command{ class AutoDrive: public Command{
private: private:
double x, y; double x, //<! The x value of the simulated joystick value
y; //<! The y value of the simulated joystick value
public: public:
/** /**
* @brief Constructs AutoDrive * @brief Constructs AutoDrive

View File

@ -13,7 +13,6 @@
*/ */
class Turn: public Command{ class Turn: public Command{
private: private:
int degrees;
public: public:
/** /**
* @brief Constructs Turn * @brief Constructs Turn

View File

@ -9,7 +9,7 @@
*/ */
class BinLower: public Command{ class BinLower: public Command{
private: private:
float timeout; float timeout; //<! The timeout
public: public:
/** /**
* @brief Constructs BinLower * @brief Constructs BinLower

View File

@ -9,7 +9,7 @@
*/ */
class BinRaise: public Command{ class BinRaise: public Command{
private: private:
float timeout; float timeout; //<! The timeout
public: public:
/** /**
* @brief Constructs BinRaise * @brief Constructs BinRaise

View File

@ -11,7 +11,7 @@
*/ */
class RollIn: public Command{ class RollIn: public Command{
private: private:
double rawSpeed; double rawSpeed; //<! Raw speed of the collector
public: public:
/** /**
* @brief Constructs RollIn * @brief Constructs RollIn

View File

@ -11,7 +11,7 @@
*/ */
class CheckDrive: public CommandGroup{ class CheckDrive: public CommandGroup{
private: private:
int motor; int motor; //<! TODO
public: public:
/** /**
* @brief TODO * @brief TODO

View File

@ -8,24 +8,77 @@
#include "Subsystems/Collector.h" #include "Subsystems/Collector.h"
#include "Subsystems/Pneumatics.h" #include "Subsystems/Pneumatics.h"
#include "Commands/Autonomous/Autonomous.h" #include "Commands/Autonomous/Autonomous.h"
/**
* @brief The Hitchhikers 2015 robot, Dent
*
* Features a 4-motor collector, 4-motor mecanum drivetrain, two one-motor elevators
*/
class DentRobot: public IterativeRobot { class DentRobot: public IterativeRobot {
private: private:
/**
* @brief The default driving command
*/
Command *driveCommand = NULL; Command *driveCommand = NULL;
public: public:
/**
* @brief Constructs DentRobot
*/
DentRobot(); DentRobot();
/**
* @brief The 2-joystick OI
*/
static OI* oi; static OI* oi;
/**
* @brief The 4-motor Collctor
*/
static Collector* collector; static Collector* collector;
/**
* @brief The 4-motor mechanum Drivetrain
*/
static Drivetrain* drivetrain; static Drivetrain* drivetrain;
/**
* @brief The main one-motor Elevator for lifting totes
*/
static Elevator* elevator; static Elevator* elevator;
/**
* @brief The back one-motor Elevator for lifting totes or bins
*/
static BinElevator* binElevator; static BinElevator* binElevator;
/**
* @brief The Pneumatics system (UNUSED)
*/
static Pneumatics* pneumatics; static Pneumatics* pneumatics;
/**
* @brief The Autonomous command
*/
static CommandGroup* aut; static CommandGroup* aut;
/**
* @brief Initializes the robot
*/
void RobotInit(); void RobotInit();
/**
* @brief Periodically run when disabled
*/
void DisabledPeriodic(); void DisabledPeriodic();
/**
* @brief Initializes the autonomous period
*/
void AutonomousInit(); void AutonomousInit();
/**
* @brief Periodically run when enabled in autonomous
*/
void AutonomousPeriodic(); void AutonomousPeriodic();
/**
* @brief Initializes the teleop period
*/
void TeleopInit(); void TeleopInit();
/**
* @brief Periodically run when enabled in autonomous
*/
void TeleopPeriodic(); void TeleopPeriodic();
/**
* @brief Periodically run when enabled in test mode
*/
void TestPeriodic(); void TestPeriodic();
}; };
#endif #endif

View File

@ -2,16 +2,46 @@
#define COLLECTOR_H #define COLLECTOR_H
#include "WPILib.h" #include "WPILib.h"
/**
* @brief Collects totes
*
* Uses four motors, two on the sides, one on the bottom, and one on the ramp to collect and eject totes
*/
class Collector: public Subsystem class Collector: public Subsystem
{ {
private: private:
CANTalon *collectorMotorLeft, *collectorMotorBottom, *collectorMotorRamp, *collectorMotorRight; CANTalon *collectorMotorLeft, //<! Left collector motor
*collectorMotorBottom, //<! Bottom collctor motor
*collectorMotorRamp, //<! Ramp collctor motor
*collectorMotorRight; //<! Right collector motor
/**
* @brief Analog input for sonar (UNUSED)
*/
AnalogInput *sonarAnalog; AnalogInput *sonarAnalog;
/**
* @brief Digital output for sonar (UNUSED)
*/
DigitalOutput *sonarDigital; DigitalOutput *sonarDigital;
public: public:
/**
* @brief Constructs Collector
*/
Collector(); Collector();
/**
* @brief No action
*/
void InitDefaultCommand(); void InitDefaultCommand();
/**
* @brief Moves the collectors
*
* @param double The speed to run the collectors
*/
void MoveRollers(double); void MoveRollers(double);
/**
* @brief Gets the distance of the sonar (UNUSED)
*
* @return The sonar distance
*/
double GetSonarDistance(); double GetSonarDistance();
}; };
#endif #endif