blob: a6a6d0e76e85e9514b8c484a442c120028b5fa56 [file] [log] [blame]
Comran Morshed41ed7c22015-11-04 21:03:37 +00001package y2014_bot3.control_loops;
Comran Morshede9b12922015-11-04 19:46:48 +00002
John Park33858a32018-09-28 23:05:48 -07003import "aos/controls/control_loops.q";
Comran Morshed41ed7c22015-11-04 21:03:37 +00004import "frc971/control_loops/control_loops.q";
Comran Morshede9b12922015-11-04 19:46:48 +00005
Austin Schuh30020d92019-05-27 13:07:02 -07006// on ".y2014_bot3.control_loops.rollers_queue"
Comran Morshed41ed7c22015-11-04 21:03:37 +00007queue_group RollersQueue {
Comran Morshede9b12922015-11-04 19:46:48 +00008 implements aos.control_loops.ControlLoop;
9
10 message Goal {
11 // -1 = back intake, 1 = front intake, all else = stationary.
12 int16_t intake;
13 // -1 = backwards, 1 = forwards, all else = stationary.
14 int16_t low_spit;
15 // Whether we want the human player load function.
16 bool human_player;
17 };
18
19 message Position {};
20
21 message Output {
22 // Positive voltage = intaking, Negative = spitting.
23 double front_intake_voltage;
24 double back_intake_voltage;
25 // Voltage for the low goal rollers.
26 // Positive voltage = ball towards back, Negative = ball towards front.
27 double low_goal_voltage;
28
29 // Whether the front and back intake pistons are extended.
30 bool front_extended;
31 bool back_extended;
32 };
33
34 message Status {};
35
36 queue Goal goal;
37 queue Position position;
38 queue Output output;
39 queue Status status;
40};
41
Comran Morshed41ed7c22015-11-04 21:03:37 +000042queue_group RollersQueue rollers_queue;