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

48 lines
926 B
C
Raw Normal View History

2015-02-13 19:40:23 -05:00
#ifndef ROLLIN_H
#define ROLLIN_H
2015-01-16 19:29:55 -05:00
2015-01-17 12:55:51 -05:00
#include "Commands/Command.h"
#include "../../CommandBase.h"
#include "../../DentRobot.h"
2015-01-16 19:29:55 -05:00
#include "WPILib.h"
2015-03-01 17:19:00 -05:00
/**
* @brief Rolls collector motors in until a timeout is reached
*/
2015-02-13 19:40:23 -05:00
class RollIn: public Command{
2015-02-21 08:43:19 -05:00
private:
2015-03-02 08:28:03 -05:00
double rawSpeed; //<! Raw speed of the collector
2015-01-16 20:12:48 -05:00
public:
2015-03-07 13:27:11 -05:00
RollIn();
2015-03-01 17:19:00 -05:00
/**
* @brief Constructs RollIn
*
* @param double Timeout in seconds
*/
2015-02-21 08:43:19 -05:00
RollIn(double);
2015-03-01 17:19:00 -05:00
/**
* @brief Initializes the class
*/
2015-01-16 20:12:48 -05:00
void Initialize();
2015-03-01 17:19:00 -05:00
/**
* @brief Rolls the four collector motors in
*/
2015-01-16 20:12:48 -05:00
void Execute();
2015-03-01 17:19:00 -05:00
/**
* @brief Checks if the command is finished
*
* @return True only if the timeout was reached
*/
2015-01-16 20:12:48 -05:00
bool IsFinished();
2015-03-01 17:19:00 -05:00
/**
* @brief Sets the collector to stop
*/
2015-01-16 20:12:48 -05:00
void End();
2015-03-01 17:19:00 -05:00
/**
* @brief Calls End()
*/
2015-01-16 20:12:48 -05:00
void Interrupted();
2015-01-16 19:29:55 -05:00
};
#endif
2015-02-08 12:26:15 -05:00
// vim: ts=2:sw=2:et