-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRedArrowMain.h
More file actions
executable file
·103 lines (85 loc) · 2.51 KB
/
RedArrowMain.h
File metadata and controls
executable file
·103 lines (85 loc) · 2.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
#include "WPILib.h"
#include "SmartDashboard/SmartDashboard.h"
#include "Utilities/CxTimer.h"
#include "Utilities/AutonomousManager.h"
#include "Subsystems/ArmControl.h"
#include "Subsystems/FeederControl.h"
#include "Subsystems/TwoStateServoControl.h"
#include "Subsystems/PotentiometerControl.h"
#include "Subsystems/DriveTrain.h"
#include "Subsystems/ShooterControl.h"
#include "Subsystems/MotorControl.h"
#include "Subsystems/DistanceSensor.h"
class BuiltinDefaultCode : public IterativeRobot
{
public:
/**
* Constructor for this "BuiltinDefaultCode" Class.
*
* The constructor creates all of the objects used for the different inputs and outputs of
* the robot. Essentially, the constructor defines the input/output mapping for the robot,
* providing named objects for each of the robot interfaces.
*/
BuiltinDefaultCode(void);
~BuiltinDefaultCode(void);
/********************************** Init Routines *************************************/
void RobotInit(void);
void DisabledInit(void);
void AutonomousInit(void);
void TeleopInit(void);
/********************************** Periodic Routines *************************************/
void DisabledPeriodic(void);
void AutonomousPeriodic(void);
void TeleopPeriodic(void);
void GetDS();
void ResetSubsystems();
bool UpdateSubsystems();
//private:
// Declare variale for the robot drive system
DriveTrain *m_robotDrive;
CxTimer *m_t1;
TwoStateServoControl *m_gripRight;
TwoStateServoControl *m_gripLeft;
TwoStateServoControl *m_flag;
ShooterControl *m_shooter;
MotorControl *m_roller;
DistanceSensor *m_distanceSensor;
MotorControl *m_winch;
private:
AutonomousManager<BuiltinDefaultCode> *m_autonomousManager;
float RSy;
float RSx;
float RSz;
bool RS_B1;
bool RS_B2;
bool RS_B3;
bool RS_B4;
bool RS_B5;
bool RS_B6;
bool RS_B7;
bool RS_B8;
bool RS_B9;
bool RS_B10;
bool RS_B11;
float LSy;
float LSx;
float LSz;
bool LS_B1;
bool prev_LS_B2;
bool LS_B2;
bool LS_B3;
bool LS_B4;
bool LS_B5;
bool LS_B6;
bool LS_B7;
bool LS_B8;
bool LS_B9;
bool LS_B10;
bool LS_B11;
// Declare a variable to use to access the driver station object
DriverStation *m_ds; // driver station object
SendableChooser *m_autonomousModeChooser;
// Declare variables for the two joysticks being used
Joystick *m_rightStick; // joystick 1 (arcade stick or right tank stick)
Joystick *m_leftStick; // joystick 2 (tank left stick)
};