blob: 52a54bb258ee868673e8add66867efc9916f6aae [file] [log] [blame]
Niko Sohmers3860f8a2024-01-12 21:05:19 -08001include "frc971/vision/target_map.fbs";
Niko Sohmersb21dbdc2024-01-20 20:06:59 -08002include "frc971/control_loops/profiled_subsystem.fbs";
3include "frc971/zeroing/constants.fbs";
Niko Sohmers3860f8a2024-01-12 21:05:19 -08004
5namespace y2024;
6
Maxwell Henderson93f37f22024-01-19 17:08:23 -08007table ShotParams {
8 shot_velocity: double (id: 0);
9 shot_angle: double (id: 1);
10}
11
12table InterpolationTablePoint {
13 distance_from_goal: double (id: 0);
14 shot_params: ShotParams (id: 1);
15}
Niko Sohmers3860f8a2024-01-12 21:05:19 -080016
Niko Sohmersb21dbdc2024-01-20 20:06:59 -080017// Amount of voltage to give to the intake rollers when:
18// spitting, which represents voltage when IntakeRollerGoal is SPITTING
19// and intaking, which represents voltage when IntakeRollerGoal is INTAKING
20table IntakeRollerVoltages {
21 spitting:double (id: 0);
22 intaking:double (id: 1);
23}
Niko Sohmers3860f8a2024-01-12 21:05:19 -080024
Niko Sohmersb21dbdc2024-01-20 20:06:59 -080025// Set points for the pivot in radians when:
26// extended, which represents radians for when IntakePivotGoal is EXTENDED
27// and retracted, which represents radians for when IntakePivotGoal is RETRACTED or NONE
28table IntakePivotSetPoints {
29 extended:double (id: 0);
30 retracted:double (id: 1);
31}
32
33// Intake Constants
34table IntakeConstants {
35 intake_pivot_zero:frc971.zeroing.PotAndAbsoluteEncoderZeroingConstants (id: 0);
36 potentiometer_offset:double (id: 1);
37}
38
39table RobotConstants {
40 intake_constants:IntakeConstants (id: 0);
41}
42
43// Common table for constants unrelated to the robot
44table Common {
45 target_map:frc971.vision.TargetMap (id: 0);
46 shooter_interpolation_table: [InterpolationTablePoint] (id: 1);
47 intake_roller_voltages:IntakeRollerVoltages (id : 2);
48 intake_pivot_set_points:IntakePivotSetPoints (id: 3);
49 intake_pivot:frc971.control_loops.StaticZeroingSingleDOFProfiledSubsystemCommonParams (id: 4);
Niko Sohmers3860f8a2024-01-12 21:05:19 -080050}
51
52table Constants {
Niko Sohmersb21dbdc2024-01-20 20:06:59 -080053 robot:RobotConstants (id: 0);
54 common:Common (id: 1);
Niko Sohmers3860f8a2024-01-12 21:05:19 -080055}
56
Niko Sohmersb21dbdc2024-01-20 20:06:59 -080057root_type Constants;