blob: 7e3620affca91edcacaa6e101b12ee88bcbd400c [file] [log] [blame]
Philipp Schradera501c912017-01-29 00:02:58 +00001package y2017.control_loops.serializer;
2
3import "aos/common/controls/control_loops.q";
4import "frc971/control_loops/control_loops.q";
5
6queue_group SerializerQueue {
7 implements aos.control_loops.ControlLoop;
8
9 // All angles are in radians, and angular velocities are in radians/second.
10 // For all angular velocities, positive is moving balls up towards the
11 // shooter.
12
13 message Goal {
14 // Angular velocity goals in radians/second.
15 double angular_velocity;
16 };
17
18 message Position {
19 // Serializer angle in radians.
20 double theta;
21 };
22
23 message Status {
24 // The current average velocity in radians/second.
25 double avg_angular_velocity;
26
27 // The current instantaneous filtered velocity in radians/second.
28 double angular_velocity;
29
30 // True if the shooter is ready. It is better to compare the velocities
31 // directly so there isn't confusion on if the goal is up to date.
32 bool ready;
33 };
34
35 message Output {
36 // Voltage in volts of the shooter motor.
37 double voltage;
38 };
39
40 queue Goal goal;
41 queue Position position;
42 queue Output output;
43 queue Status status;
44};
45
46queue_group SerializerQueue shooter_queue;