blob: 4df648630485f510fc1fb88966b1d58d82d0a54a [file] [log] [blame]
James Kuszmaulf01da392023-12-14 11:22:14 -08001load("//aos/flatbuffers:generate.bzl", "static_flatbuffer")
Philipp Schrader3de4dfc2023-02-15 20:18:25 -08002load("//tools/build_rules:js.bzl", "ts_project")
Austin Schuha1d006e2022-09-14 21:50:42 -07003load("@com_github_google_flatbuffers//:typescript.bzl", "flatbuffer_ts_library")
Alex Perrycb7da4b2019-08-28 19:35:56 -07004load("//aos:config.bzl", "aos_config")
Philipp Schraderdada1072020-11-24 11:34:46 -08005load("//tools/build_rules:select.bzl", "cpu_select")
Austin Schuh41fad8c2021-10-23 21:25:12 -07006load("//aos:flatbuffers.bzl", "cc_static_flatbuffer")
Comran Morshed5323ecb2015-12-26 20:50:55 +00007
Philipp Schradercc016b32021-12-30 08:59:58 -08008package(default_visibility = ["//visibility:public"])
9
James Kuszmaulf01da392023-12-14 11:22:14 -080010static_flatbuffer(
Maxwell Hendersoncef6f042023-05-26 14:38:09 -070011 name = "drivetrain_can_position_fbs",
12 srcs = ["drivetrain_can_position.fbs"],
Maxwell Henderson10ed5c32024-01-09 12:40:54 -080013 deps = ["//frc971/control_loops:can_talonfx_fbs"],
Maxwell Hendersoncef6f042023-05-26 14:38:09 -070014)
15
James Kuszmaulf01da392023-12-14 11:22:14 -080016static_flatbuffer(
James Kuszmaul75a18c52021-03-10 22:02:07 -080017 name = "spline_goal_fbs",
18 srcs = ["spline_goal.fbs"],
James Kuszmaulf01da392023-12-14 11:22:14 -080019 deps = ["//frc971/control_loops:control_loops_fbs"],
James Kuszmaul75a18c52021-03-10 22:02:07 -080020)
21
James Kuszmaulf01da392023-12-14 11:22:14 -080022static_flatbuffer(
Alex Perrycb7da4b2019-08-28 19:35:56 -070023 name = "drivetrain_goal_fbs",
24 srcs = ["drivetrain_goal.fbs"],
James Kuszmaulf01da392023-12-14 11:22:14 -080025 deps = [
26 ":spline_goal_fbs",
27 "//frc971/control_loops:control_loops_fbs",
James Kuszmaul75a18c52021-03-10 22:02:07 -080028 ],
Comran Morshed5323ecb2015-12-26 20:50:55 +000029)
30
James Kuszmaulf01da392023-12-14 11:22:14 -080031static_flatbuffer(
Alex Perrycb7da4b2019-08-28 19:35:56 -070032 name = "drivetrain_output_fbs",
33 srcs = ["drivetrain_output.fbs"],
Alex Perrycb7da4b2019-08-28 19:35:56 -070034)
35
James Kuszmaulf01da392023-12-14 11:22:14 -080036static_flatbuffer(
Alex Perrycb7da4b2019-08-28 19:35:56 -070037 name = "drivetrain_position_fbs",
38 srcs = ["drivetrain_position.fbs"],
Alex Perrycb7da4b2019-08-28 19:35:56 -070039)
40
James Kuszmaulf01da392023-12-14 11:22:14 -080041static_flatbuffer(
Alex Perrycb7da4b2019-08-28 19:35:56 -070042 name = "drivetrain_status_fbs",
43 srcs = ["drivetrain_status.fbs"],
James Kuszmaulf01da392023-12-14 11:22:14 -080044 deps = ["//frc971/control_loops:control_loops_fbs"],
Alex Perrycb7da4b2019-08-28 19:35:56 -070045)
46
James Kuszmaulf01da392023-12-14 11:22:14 -080047static_flatbuffer(
James Kuszmaul75a18c52021-03-10 22:02:07 -080048 name = "trajectory_fbs",
49 srcs = ["trajectory.fbs"],
James Kuszmaulf01da392023-12-14 11:22:14 -080050 deps = ["//frc971/control_loops:control_loops_fbs"],
James Kuszmaul75a18c52021-03-10 22:02:07 -080051)
52
Austin Schuh41fad8c2021-10-23 21:25:12 -070053cc_static_flatbuffer(
54 name = "trajectory_schema",
55 function = "frc971::control_loops::drivetrain::fb::TrajectorySchema",
56 target = ":trajectory_fbs_reflection_out",
57 visibility = ["//visibility:public"],
58)
59
Alex Perry2124ae82020-03-07 14:19:06 -080060flatbuffer_ts_library(
61 name = "drivetrain_status_ts_fbs",
62 srcs = ["drivetrain_status.fbs"],
Philipp Schraderdada1072020-11-24 11:34:46 -080063 target_compatible_with = ["@platforms//os:linux"],
James Kuszmauldac091f2022-03-22 09:35:06 -070064 deps = ["//frc971/control_loops:control_loops_ts_fbs"],
Alex Perry2124ae82020-03-07 14:19:06 -080065)
66
Niko Sohmers76f47562023-12-20 20:59:06 -080067flatbuffer_ts_library(
68 name = "drivetrain_position_ts_fbs",
69 srcs = ["drivetrain_position.fbs"],
70 target_compatible_with = ["@platforms//os:linux"],
71)
72
73flatbuffer_ts_library(
74 name = "drivetrain_can_position_ts_fbs",
75 srcs = ["drivetrain_can_position.fbs"],
76 target_compatible_with = ["@platforms//os:linux"],
Maxwell Henderson10ed5c32024-01-09 12:40:54 -080077 deps = ["//frc971/control_loops:can_talonfx_ts_fbs"],
Niko Sohmers76f47562023-12-20 20:59:06 -080078)
79
Alex Perrycb7da4b2019-08-28 19:35:56 -070080genrule(
81 name = "drivetrain_goal_float_fbs_generated",
82 srcs = ["drivetrain_goal.fbs"],
83 outs = ["drivetrain_goal_float.fbs"],
84 cmd = "cat $(SRCS) | sed 's/double/float/g' > $(OUTS)",
Alex Perrycb7da4b2019-08-28 19:35:56 -070085)
86
87genrule(
88 name = "drivetrain_position_float_fbs_generated",
89 srcs = ["drivetrain_position.fbs"],
90 outs = ["drivetrain_position_float.fbs"],
91 cmd = "cat $(SRCS) | sed 's/double/float/g' > $(OUTS)",
Alex Perrycb7da4b2019-08-28 19:35:56 -070092)
93
94genrule(
95 name = "drivetrain_output_float_fbs_generated",
96 srcs = ["drivetrain_output.fbs"],
97 outs = ["drivetrain_output_float.fbs"],
98 cmd = "cat $(SRCS) | sed 's/double/float/g' > $(OUTS)",
Alex Perrycb7da4b2019-08-28 19:35:56 -070099)
100
101genrule(
102 name = "drivetrain_status_float_fbs_generated",
103 srcs = ["drivetrain_status.fbs"],
104 outs = ["drivetrain_status_float.fbs"],
105 cmd = "cat $(SRCS) | sed 's/double/float/g' > $(OUTS)",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700106)
107
James Kuszmaulf01da392023-12-14 11:22:14 -0800108static_flatbuffer(
Alex Perrycb7da4b2019-08-28 19:35:56 -0700109 name = "drivetrain_goal_float_fbs",
110 srcs = ["drivetrain_goal_float.fbs"],
James Kuszmaulf01da392023-12-14 11:22:14 -0800111 deps = [
112 ":spline_goal_fbs",
113 "//frc971/control_loops:control_loops_fbs",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800114 ],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700115)
116
James Kuszmaulf01da392023-12-14 11:22:14 -0800117static_flatbuffer(
Alex Perrycb7da4b2019-08-28 19:35:56 -0700118 name = "drivetrain_output_float_fbs",
119 srcs = ["drivetrain_output_float.fbs"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700120)
121
James Kuszmaulf01da392023-12-14 11:22:14 -0800122static_flatbuffer(
Alex Perrycb7da4b2019-08-28 19:35:56 -0700123 name = "drivetrain_position_float_fbs",
124 srcs = ["drivetrain_position_float.fbs"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700125)
126
James Kuszmaulf01da392023-12-14 11:22:14 -0800127static_flatbuffer(
Alex Perrycb7da4b2019-08-28 19:35:56 -0700128 name = "drivetrain_status_float_fbs",
129 srcs = ["drivetrain_status_float.fbs"],
James Kuszmaulf01da392023-12-14 11:22:14 -0800130 deps = ["//frc971/control_loops:control_loops_fbs"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700131)
132
133aos_config(
James Kuszmaul74d8f972020-02-11 17:13:17 -0800134 name = "simulation_channels",
135 src = "drivetrain_simulation_channels.json",
136 flatbuffers = [
137 ":drivetrain_status_fbs",
138 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800139 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul74d8f972020-02-11 17:13:17 -0800140 visibility = ["//visibility:public"],
141)
142
143aos_config(
144 name = "simulation_config",
145 src = "drivetrain_simulation_config.json",
Philipp Schraderdada1072020-11-24 11:34:46 -0800146 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul74d8f972020-02-11 17:13:17 -0800147 visibility = ["//visibility:public"],
148 deps = [
Austin Schuhc5fa6d92022-02-25 14:36:28 -0800149 ":aos_config",
James Kuszmaul74d8f972020-02-11 17:13:17 -0800150 ":simulation_channels",
151 ],
152)
153
154aos_config(
Austin Schuhc5fa6d92022-02-25 14:36:28 -0800155 name = "aos_config",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700156 src = "drivetrain_config.json",
157 flatbuffers = [
158 ":drivetrain_goal_fbs",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800159 ":trajectory_fbs",
160 ":spline_goal_fbs",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700161 ":drivetrain_output_fbs",
162 ":drivetrain_status_fbs",
163 ":drivetrain_position_fbs",
164 ":localizer_fbs",
Tyler Chatow24b5db12020-01-06 21:16:56 -0800165 "//frc971/queues:gyro_fbs",
166 "//frc971/queues:gyro_uid_fbs",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700167 "//frc971/wpilib:imu_fbs",
Austin Schuhac17fba2020-03-28 15:55:33 -0700168 "//frc971/wpilib:imu_batch_fbs",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700169 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800170 target_compatible_with = ["@platforms//os:linux"],
Alex Perrycb7da4b2019-08-28 19:35:56 -0700171 visibility = ["//visibility:public"],
Austin Schuhbcce26a2018-03-26 23:41:24 -0700172 deps = [
Austin Schuhc5fa6d92022-02-25 14:36:28 -0800173 "//frc971/input:aos_config",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700174 ],
Comran Morshed5323ecb2015-12-26 20:50:55 +0000175)
176
177cc_library(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700178 name = "drivetrain_config",
179 hdrs = [
180 "drivetrain_config.h",
181 ],
182 deps = [
183 "//frc971:shifter_hall_effect",
184 "//frc971/control_loops:state_feedback_loop",
James Kuszmaul68025332024-01-20 17:06:02 -0800185 "//frc971/control_loops:state_feedback_loop_converters",
186 ":drivetrain_config_fbs",
Philipp Schraderdada1072020-11-24 11:34:46 -0800187 ] + select({
James Kuszmaul68025332024-01-20 17:06:02 -0800188 "@platforms//os:linux": [
189 "//frc971/control_loops:hybrid_state_feedback_loop",
190 "//frc971/control_loops:hybrid_state_feedback_loop_converters",
191 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800192 "//conditions:default": [],
193 }),
Comran Morshed5323ecb2015-12-26 20:50:55 +0000194)
195
196cc_library(
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800197 name = "hybrid_ekf",
198 hdrs = ["hybrid_ekf.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800199 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800200 deps = [
201 ":drivetrain_config",
James Kuszmaul3c5b4d32020-02-11 17:22:14 -0800202 "//aos:math",
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800203 "//aos/containers:priority_queue",
James Kuszmaulfedc4612019-03-10 11:24:51 -0700204 "//aos/util:math",
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800205 "//frc971/control_loops:c2d",
206 "//frc971/control_loops:runge_kutta",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700207 "@org_tuxfamily_eigen//:eigen",
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800208 ],
209)
210
211cc_test(
212 name = "hybrid_ekf_test",
213 srcs = ["hybrid_ekf_test.cc"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800214 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800215 deps = [
216 ":drivetrain_test_lib",
217 ":hybrid_ekf",
218 ":trajectory",
219 "//aos/testing:googletest",
220 "//aos/testing:random_seed",
221 "//aos/testing:test_shm",
222 ],
223)
224
James Kuszmaulf01da392023-12-14 11:22:14 -0800225static_flatbuffer(
Alex Perrycb7da4b2019-08-28 19:35:56 -0700226 name = "localizer_fbs",
227 srcs = ["localizer.fbs"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800228 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaulef428a02019-03-02 22:19:41 -0800229)
230
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800231cc_library(
James Kuszmaul3431d622019-02-17 17:07:44 -0800232 name = "localizer",
233 hdrs = ["localizer.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800234 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul3431d622019-02-17 17:07:44 -0800235 deps = [
236 ":drivetrain_config",
James Kuszmaul3c5b4d32020-02-11 17:22:14 -0800237 ":drivetrain_status_fbs",
James Kuszmaul3431d622019-02-17 17:07:44 -0800238 ":hybrid_ekf",
James Kuszmaul5398fae2020-02-17 16:44:03 -0800239 "//frc971/control_loops:control_loops_fbs",
James Kuszmaul5bc6fc92019-03-01 21:50:06 -0800240 "//frc971/control_loops:pose",
James Kuszmaul3431d622019-02-17 17:07:44 -0800241 ],
242)
243
244cc_library(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700245 name = "gear",
246 hdrs = [
247 "gear.h",
248 ],
Austin Schuh093535c2016-03-05 23:21:00 -0800249)
250
251cc_library(
Alex Perry731b4602019-02-02 22:13:01 -0800252 name = "splinedrivetrain",
253 srcs = [
254 "splinedrivetrain.cc",
255 ],
256 hdrs = [
257 "splinedrivetrain.h",
258 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800259 target_compatible_with = ["@platforms//os:linux"],
Alex Perry731b4602019-02-02 22:13:01 -0800260 deps = [
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800261 ":distance_spline",
Alex Perry731b4602019-02-02 22:13:01 -0800262 ":drivetrain_config",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700263 ":drivetrain_goal_fbs",
264 ":drivetrain_output_fbs",
265 ":drivetrain_status_fbs",
Alex Perry731b4602019-02-02 22:13:01 -0800266 ":spline",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800267 ":spline_goal_fbs",
Alex Perry731b4602019-02-02 22:13:01 -0800268 ":trajectory",
Austin Schuh3d9ccd72020-08-01 15:42:40 -0700269 "//aos:condition",
Alex Perry1ec34522019-02-17 22:44:10 -0800270 "//aos:init",
James Kuszmaulc73bb222019-04-07 12:15:35 -0700271 "//aos/util:math",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700272 "//frc971/control_loops:control_loops_fbs",
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800273 ],
Alex Perry731b4602019-02-02 22:13:01 -0800274)
275
276cc_library(
James Kuszmaule39cbcf2019-02-27 20:48:34 -0800277 name = "line_follow_drivetrain",
278 srcs = [
279 "line_follow_drivetrain.cc",
280 ],
281 hdrs = [
282 "line_follow_drivetrain.h",
283 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800284 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaule39cbcf2019-02-27 20:48:34 -0800285 deps = [
286 ":drivetrain_config",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700287 ":drivetrain_goal_fbs",
288 ":drivetrain_output_fbs",
289 ":drivetrain_status_fbs",
James Kuszmaul5bc6fc92019-03-01 21:50:06 -0800290 ":localizer",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800291 ":spline_goal_fbs",
James Kuszmaule39cbcf2019-02-27 20:48:34 -0800292 "//aos:math",
293 "//aos/util:math",
294 "//frc971/control_loops:c2d",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700295 "//frc971/control_loops:control_loops_fbs",
James Kuszmaule39cbcf2019-02-27 20:48:34 -0800296 "//frc971/control_loops:dlqr",
297 "//frc971/control_loops:pose",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700298 "//frc971/control_loops:profiled_subsystem_fbs",
299 "//y2019/control_loops/superstructure:superstructure_goal_fbs",
300 "@org_tuxfamily_eigen//:eigen",
James Kuszmaule39cbcf2019-02-27 20:48:34 -0800301 ],
302)
303
304cc_test(
305 name = "line_follow_drivetrain_test",
306 srcs = ["line_follow_drivetrain_test.cc"],
307 linkstatic = True,
Philipp Schraderdada1072020-11-24 11:34:46 -0800308 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaule39cbcf2019-02-27 20:48:34 -0800309 deps = [
310 ":drivetrain_config",
311 ":drivetrain_test_lib",
312 ":line_follow_drivetrain",
313 ":trajectory",
314 "//aos/testing:googletest",
315 "//aos/testing:test_shm",
316 "//third_party/matplotlib-cpp",
317 "@com_github_gflags_gflags//:gflags",
318 ],
319)
320
321cc_library(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700322 name = "ssdrivetrain",
323 srcs = [
324 "ssdrivetrain.cc",
325 ],
326 hdrs = [
327 "ssdrivetrain.h",
328 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800329 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhbcce26a2018-03-26 23:41:24 -0700330 deps = [
331 ":drivetrain_config",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700332 ":drivetrain_goal_fbs",
333 ":drivetrain_output_fbs",
Austin Schuh95771d92021-01-23 14:42:25 -0800334 ":drivetrain_states",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700335 ":drivetrain_status_fbs",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700336 ":gear",
James Kuszmaul3431d622019-02-17 17:07:44 -0800337 ":localizer",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800338 ":spline_goal_fbs",
John Park33858a32018-09-28 23:05:48 -0700339 "//aos:math",
John Park33858a32018-09-28 23:05:48 -0700340 "//aos/util:log_interval",
341 "//aos/util:trapezoid_profile",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700342 "//frc971:shifter_hall_effect",
343 "//frc971/control_loops:coerce_goal",
Austin Schuh0a3c9d42021-07-15 22:36:24 -0700344 "//frc971/control_loops:control_loop",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700345 "//frc971/control_loops:control_loops_fbs",
Austin Schuh0a3c9d42021-07-15 22:36:24 -0700346 "//frc971/control_loops:polytope",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700347 "//frc971/control_loops:state_feedback_loop",
Austin Schuh0a3c9d42021-07-15 22:36:24 -0700348 "//frc971/input:robot_state_fbs",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700349 ],
Comran Morshed5323ecb2015-12-26 20:50:55 +0000350)
351
352cc_library(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700353 name = "polydrivetrain",
354 srcs = [
355 "polydrivetrain.cc",
356 ],
357 hdrs = [
358 "polydrivetrain.h",
359 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800360 copts = select({
361 "@platforms//os:none": ["-Wno-type-limits"],
362 "//conditions:default": [],
363 }),
Austin Schuhbcce26a2018-03-26 23:41:24 -0700364 deps = [
365 ":drivetrain_config",
Austin Schuh95771d92021-01-23 14:42:25 -0800366 ":drivetrain_states",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700367 ":gear",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700368 ":spline_goal_fbs",
John Park33858a32018-09-28 23:05:48 -0700369 "//aos:math",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700370 "//frc971/control_loops:coerce_goal",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700371 "//frc971/control_loops:control_loops_fbs",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700372 "//frc971/control_loops:polytope",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700373 "//frc971/control_loops:state_feedback_loop",
Philipp Schraderdada1072020-11-24 11:34:46 -0800374 ] + select({
375 "@platforms//os:linux": [
376 ":drivetrain_goal_fbs",
377 ":drivetrain_output_fbs",
378 ":drivetrain_position_fbs",
379 ":drivetrain_status_fbs",
Philipp Schraderdada1072020-11-24 11:34:46 -0800380 "//aos/util:log_interval",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700381 "//frc971/input:robot_state_fbs",
Philipp Schraderdada1072020-11-24 11:34:46 -0800382 ],
383 "@platforms//os:none": [
384 ":drivetrain_goal_float_fbs",
385 ":drivetrain_output_float_fbs",
386 ":drivetrain_position_float_fbs",
387 ":drivetrain_status_float_fbs",
388 ],
389 }),
Comran Morshed5323ecb2015-12-26 20:50:55 +0000390)
391
Austin Schuh05c5a612016-04-02 15:10:25 -0700392genrule(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700393 name = "genrule_down_estimator",
394 outs = [
395 "down_estimator.h",
396 "down_estimator.cc",
397 ],
398 cmd = "$(location //frc971/control_loops/python:down_estimator) $(OUTS)",
Philipp Schraderdada1072020-11-24 11:34:46 -0800399 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhbcce26a2018-03-26 23:41:24 -0700400 tools = [
401 "//frc971/control_loops/python:down_estimator",
402 ],
403 visibility = ["//visibility:private"],
Austin Schuh05c5a612016-04-02 15:10:25 -0700404)
405
406cc_library(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700407 name = "down_estimator",
408 srcs = [
409 "down_estimator.cc",
410 ],
411 hdrs = [
412 "down_estimator.h",
413 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800414 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhbcce26a2018-03-26 23:41:24 -0700415 deps = [
416 "//frc971/control_loops:state_feedback_loop",
417 ],
Austin Schuh05c5a612016-04-02 15:10:25 -0700418)
419
Comran Morshed5323ecb2015-12-26 20:50:55 +0000420cc_library(
Austin Schuh95771d92021-01-23 14:42:25 -0800421 name = "drivetrain_states",
422 hdrs = ["drivetrain_states.h"],
423)
424
425cc_library(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700426 name = "drivetrain_lib",
427 srcs = [
428 "drivetrain.cc",
429 ],
430 hdrs = [
431 "drivetrain.h",
432 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800433 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhbcce26a2018-03-26 23:41:24 -0700434 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -0700435 ":drivetrain_goal_fbs",
436 ":drivetrain_output_fbs",
437 ":drivetrain_position_fbs",
Austin Schuh95771d92021-01-23 14:42:25 -0800438 ":drivetrain_states",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700439 ":drivetrain_status_fbs",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700440 ":gear",
James Kuszmaul3e1bb272020-01-17 18:38:19 -0800441 ":improved_down_estimator",
James Kuszmaule39cbcf2019-02-27 20:48:34 -0800442 ":line_follow_drivetrain",
James Kuszmaul3431d622019-02-17 17:07:44 -0800443 ":localizer",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700444 ":localizer_fbs",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700445 ":polydrivetrain",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800446 ":spline_goal_fbs",
Alex Perry731b4602019-02-02 22:13:01 -0800447 ":splinedrivetrain",
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800448 ":ssdrivetrain",
John Park33858a32018-09-28 23:05:48 -0700449 "//aos/util:log_interval",
Austin Schuh0a3c9d42021-07-15 22:36:24 -0700450 "//frc971/control_loops:control_loop",
Austin Schuh3a378462019-01-04 21:48:04 -0800451 "//frc971/control_loops:runge_kutta",
Tyler Chatow24b5db12020-01-06 21:16:56 -0800452 "//frc971/queues:gyro_fbs",
Austin Schuhac17fba2020-03-28 15:55:33 -0700453 "//frc971/wpilib:imu_batch_fbs",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700454 "//frc971/wpilib:imu_fbs",
James Kuszmaul3e1bb272020-01-17 18:38:19 -0800455 "//frc971/zeroing:imu_zeroer",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700456 ],
Comran Morshed5323ecb2015-12-26 20:50:55 +0000457)
458
James Kuszmaul109ed8d2019-02-17 21:41:04 -0800459cc_library(
460 name = "drivetrain_test_lib",
461 testonly = True,
462 srcs = ["drivetrain_test_lib.cc"],
463 hdrs = ["drivetrain_test_lib.h"],
James Kuszmaul74d8f972020-02-11 17:13:17 -0800464 defines =
465 cpu_select({
466 "amd64": [
467 "SUPPORT_PLOT=1",
468 ],
469 "arm": [],
470 }),
Philipp Schraderdada1072020-11-24 11:34:46 -0800471 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaul109ed8d2019-02-17 21:41:04 -0800472 deps = [
473 ":drivetrain_config",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700474 ":drivetrain_goal_fbs",
475 ":drivetrain_output_fbs",
476 ":drivetrain_position_fbs",
477 ":drivetrain_status_fbs",
James Kuszmaul109ed8d2019-02-17 21:41:04 -0800478 ":trajectory",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700479 "//aos/events:event_loop",
James Kuszmaul109ed8d2019-02-17 21:41:04 -0800480 "//aos/testing:googletest",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700481 "//frc971/control_loops:control_loops_fbs",
James Kuszmaul109ed8d2019-02-17 21:41:04 -0800482 "//frc971/control_loops:state_feedback_loop",
Tyler Chatow24b5db12020-01-06 21:16:56 -0800483 "//frc971/queues:gyro_fbs",
Austin Schuhac17fba2020-03-28 15:55:33 -0700484 "//frc971/wpilib:imu_batch_fbs",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700485 "//frc971/wpilib:imu_fbs",
James Kuszmaul109ed8d2019-02-17 21:41:04 -0800486 "//y2016:constants",
487 "//y2016/control_loops/drivetrain:polydrivetrain_plants",
James Kuszmaul74d8f972020-02-11 17:13:17 -0800488 ] + cpu_select({
489 "amd64": [
490 "//third_party/matplotlib-cpp",
491 ],
492 "arm": [],
493 }),
James Kuszmaul109ed8d2019-02-17 21:41:04 -0800494)
495
Comran Morshed5323ecb2015-12-26 20:50:55 +0000496cc_test(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700497 name = "drivetrain_lib_test",
498 srcs = [
499 "drivetrain_lib_test.cc",
500 ],
Austin Schuh14d7d3d2020-09-10 18:14:36 -0700501 data = [":simulation_config"],
Alex Perry04300d62019-02-17 14:37:04 -0800502 defines =
503 cpu_select({
504 "amd64": [
505 "SUPPORT_PLOT=1",
506 ],
507 "arm": [],
508 }),
509 linkstatic = True,
Philipp Schraderdada1072020-11-24 11:34:46 -0800510 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhbcce26a2018-03-26 23:41:24 -0700511 deps = [
512 ":drivetrain_config",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700513 ":drivetrain_goal_fbs",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700514 ":drivetrain_lib",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700515 ":drivetrain_output_fbs",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700516 ":drivetrain_position_fbs",
517 ":drivetrain_status_fbs",
James Kuszmaul109ed8d2019-02-17 21:41:04 -0800518 ":drivetrain_test_lib",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700519 ":localizer_fbs",
520 ":trajectory_generator",
Austin Schuhb06f03b2021-02-17 22:00:37 -0800521 "//aos/events/logging:log_writer",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700522 "//aos/testing:googletest",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700523 "//frc971/control_loops:control_loop_test",
Tyler Chatow24b5db12020-01-06 21:16:56 -0800524 "//frc971/queues:gyro_fbs",
James Kuszmaul3e1bb272020-01-17 18:38:19 -0800525 "//frc971/wpilib:imu_fbs",
Alex Perry04300d62019-02-17 14:37:04 -0800526 ] + cpu_select({
527 "amd64": [
528 "//third_party/matplotlib-cpp",
529 ],
530 "arm": [],
531 }),
Comran Morshed5323ecb2015-12-26 20:50:55 +0000532)
Brian Silverman6260c092018-01-14 15:21:36 -0800533
534genrule(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700535 name = "genrule_haptic_wheel",
536 outs = [
537 "haptic_wheel.h",
538 "haptic_wheel.cc",
539 "integral_haptic_wheel.h",
540 "integral_haptic_wheel.cc",
541 "haptic_trigger.h",
542 "haptic_trigger.cc",
543 "integral_haptic_trigger.h",
544 "integral_haptic_trigger.cc",
545 ],
546 cmd = "$(location //frc971/control_loops/python:haptic_wheel) $(OUTS)",
Austin Schuhbcce26a2018-03-26 23:41:24 -0700547 tools = [
548 "//frc971/control_loops/python:haptic_wheel",
549 ],
550 visibility = ["//visibility:private"],
Brian Silverman6260c092018-01-14 15:21:36 -0800551)
552
553cc_library(
Austin Schuhbcce26a2018-03-26 23:41:24 -0700554 name = "haptic_wheel",
555 srcs = [
556 "haptic_trigger.cc",
557 "haptic_wheel.cc",
558 "integral_haptic_trigger.cc",
559 "integral_haptic_wheel.cc",
560 ],
561 hdrs = [
562 "haptic_trigger.h",
563 "haptic_wheel.h",
564 "integral_haptic_trigger.h",
565 "integral_haptic_wheel.h",
566 ],
567 deps = [
568 "//frc971/control_loops:state_feedback_loop",
569 ],
Brian Silverman6260c092018-01-14 15:21:36 -0800570)
Austin Schuhc2b08772018-12-19 18:05:06 +1100571
572cc_library(
573 name = "spline",
574 srcs = ["spline.cc"],
575 hdrs = ["spline.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800576 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhc2b08772018-12-19 18:05:06 +1100577 deps = [
Austin Schuhf49b4e32019-01-13 17:26:58 -0800578 "//frc971/control_loops:binomial",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700579 "@org_tuxfamily_eigen//:eigen",
Austin Schuhc2b08772018-12-19 18:05:06 +1100580 ],
581)
582
Alex Perrya60da442019-01-21 19:00:27 -0500583cc_binary(
584 name = "spline.so",
585 srcs = ["libspline.cc"],
James Kuszmaul2ed7b3c2019-02-09 18:26:19 -0800586 linkshared = True,
Philipp Schraderdada1072020-11-24 11:34:46 -0800587 target_compatible_with = ["@platforms//os:linux"],
Alex Perrya60da442019-01-21 19:00:27 -0500588 deps = [
589 ":distance_spline",
590 ":spline",
Alex Perry0603b542019-01-25 20:29:51 -0800591 ":trajectory",
Austin Schuhfc0caa82023-08-25 14:25:03 -0700592 "//aos/logging",
Alex Perry0603b542019-01-25 20:29:51 -0800593 "//aos/network:team_number",
James Kuszmaul8aa37cb2020-03-01 10:27:58 -0800594 "//y2020/control_loops/drivetrain:drivetrain_base",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700595 "@org_tuxfamily_eigen//:eigen",
Alex Perrya60da442019-01-21 19:00:27 -0500596 ],
Alex Perrya60da442019-01-21 19:00:27 -0500597)
598
Austin Schuhc2b08772018-12-19 18:05:06 +1100599cc_test(
600 name = "spline_test",
601 srcs = [
602 "spline_test.cc",
603 ],
James Kuszmaule32fa932021-05-11 21:38:16 -0700604 linkstatic = True,
Philipp Schraderdada1072020-11-24 11:34:46 -0800605 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhc2b08772018-12-19 18:05:06 +1100606 deps = [
607 ":spline",
608 "//aos/testing:googletest",
James Kuszmaule32fa932021-05-11 21:38:16 -0700609 "//frc971/analysis:in_process_plotter",
Austin Schuhc2b08772018-12-19 18:05:06 +1100610 "@com_github_gflags_gflags//:gflags",
611 ],
612)
Austin Schuh941b46d2018-12-19 18:06:05 +1100613
614cc_library(
615 name = "distance_spline",
616 srcs = ["distance_spline.cc"],
617 hdrs = ["distance_spline.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800618 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh941b46d2018-12-19 18:06:05 +1100619 deps = [
620 ":spline",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800621 ":trajectory_fbs",
Austin Schuhf7c65202022-11-04 21:28:20 -0700622 "//aos/containers:sized_array",
Austin Schuha6e7b212019-01-20 13:53:01 -0800623 "//aos/logging",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800624 "//frc971/control_loops:control_loops_fbs",
Austin Schuh941b46d2018-12-19 18:06:05 +1100625 "//frc971/control_loops:fixed_quadrature",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800626 "@com_github_google_glog//:glog",
Austin Schuhf7c65202022-11-04 21:28:20 -0700627 "@com_google_absl//absl/types:span",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700628 "@org_tuxfamily_eigen//:eigen",
Austin Schuh941b46d2018-12-19 18:06:05 +1100629 ],
630)
631
632cc_test(
633 name = "distance_spline_test",
634 srcs = [
635 "distance_spline_test.cc",
636 ],
Austin Schuh9b0b6432019-01-13 21:15:17 -0800637 defines =
638 cpu_select({
639 "amd64": [
640 "SUPPORT_PLOT=1",
641 ],
642 "arm": [],
643 }),
644 linkstatic = True,
Philipp Schraderdada1072020-11-24 11:34:46 -0800645 target_compatible_with = ["@platforms//os:linux"],
Austin Schuh941b46d2018-12-19 18:06:05 +1100646 deps = [
647 ":distance_spline",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800648 "//aos:flatbuffers",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700649 "//aos/testing:googletest",
Austin Schuha6e7b212019-01-20 13:53:01 -0800650 "//aos/testing:test_shm",
Austin Schuh941b46d2018-12-19 18:06:05 +1100651 "@com_github_gflags_gflags//:gflags",
Austin Schuh9b0b6432019-01-13 21:15:17 -0800652 ] + cpu_select({
653 "amd64": [
654 "//third_party/matplotlib-cpp",
655 ],
656 "arm": [],
657 }),
Austin Schuh941b46d2018-12-19 18:06:05 +1100658)
Austin Schuhec7f06d2019-01-04 07:47:15 +1100659
660cc_library(
661 name = "trajectory",
662 srcs = ["trajectory.cc"],
663 hdrs = ["trajectory.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800664 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhec7f06d2019-01-04 07:47:15 +1100665 deps = [
666 ":distance_spline",
667 ":drivetrain_config",
James Kuszmaul75a18c52021-03-10 22:02:07 -0800668 ":spline_goal_fbs",
669 ":trajectory_fbs",
James Kuszmaul5e8ce312021-03-27 14:59:17 -0700670 "//aos/util:math",
Austin Schuhec7f06d2019-01-04 07:47:15 +1100671 "//frc971/control_loops:c2d",
672 "//frc971/control_loops:dlqr",
673 "//frc971/control_loops:hybrid_state_feedback_loop",
674 "//frc971/control_loops:runge_kutta",
675 "//frc971/control_loops:state_feedback_loop",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700676 "@org_tuxfamily_eigen//:eigen",
Austin Schuhec7f06d2019-01-04 07:47:15 +1100677 ],
678)
679
James Kuszmaul75a18c52021-03-10 22:02:07 -0800680cc_library(
681 name = "trajectory_generator",
682 srcs = ["trajectory_generator.cc"],
683 hdrs = ["trajectory_generator.h"],
684 target_compatible_with = ["@platforms//os:linux"],
685 deps = [
686 ":distance_spline",
687 ":drivetrain_config",
688 ":spline_goal_fbs",
689 ":trajectory",
690 ":trajectory_fbs",
691 ],
692)
693
Austin Schuhec7f06d2019-01-04 07:47:15 +1100694cc_binary(
695 name = "trajectory_plot",
696 srcs = [
697 "trajectory_plot.cc",
698 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800699 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhec7f06d2019-01-04 07:47:15 +1100700 deps = [
701 ":distance_spline",
702 ":trajectory",
Austin Schuhfc0caa82023-08-25 14:25:03 -0700703 "//aos/logging",
Austin Schuhec7f06d2019-01-04 07:47:15 +1100704 "//aos/network:team_number",
Austin Schuhec7f06d2019-01-04 07:47:15 +1100705 "//third_party/matplotlib-cpp",
Austin Schuh11043182019-03-23 22:29:12 -0700706 "//y2019/control_loops/drivetrain:drivetrain_base",
Austin Schuhec7f06d2019-01-04 07:47:15 +1100707 "@com_github_gflags_gflags//:gflags",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700708 "@org_tuxfamily_eigen//:eigen",
Austin Schuhec7f06d2019-01-04 07:47:15 +1100709 ],
710)
711
712cc_test(
713 name = "trajectory_test",
714 srcs = [
715 "trajectory_test.cc",
716 ],
Austin Schuh719a33e2019-01-07 15:13:34 -0800717 defines =
718 cpu_select({
719 "amd64": [
720 "SUPPORT_PLOT=1",
721 ],
722 "arm": [],
723 }),
724 linkstatic = True,
Philipp Schraderdada1072020-11-24 11:34:46 -0800725 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhec7f06d2019-01-04 07:47:15 +1100726 deps = [
James Kuszmaulea314d92019-02-18 19:45:06 -0800727 ":drivetrain_test_lib",
Maxwell Hendersoncef6f042023-05-26 14:38:09 -0700728 ":trajectory",
Austin Schuhec7f06d2019-01-04 07:47:15 +1100729 "//aos/testing:googletest",
730 "//aos/testing:test_shm",
731 "//y2016:constants",
732 "//y2016/control_loops/drivetrain:polydrivetrain_plants",
James Kuszmaulea314d92019-02-18 19:45:06 -0800733 "//y2019/control_loops/drivetrain:drivetrain_base",
Austin Schuh719a33e2019-01-07 15:13:34 -0800734 ] + cpu_select({
735 "amd64": [
736 "//third_party/matplotlib-cpp",
737 ],
738 "arm": [],
739 }),
Austin Schuhec7f06d2019-01-04 07:47:15 +1100740)
Austin Schuhca080812017-05-10 19:31:55 -0700741
742cc_library(
743 name = "improved_down_estimator",
744 srcs = [
745 "improved_down_estimator.cc",
746 ],
747 hdrs = [
748 "improved_down_estimator.h",
749 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800750 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhca080812017-05-10 19:31:55 -0700751 deps = [
James Kuszmaul7f55f072020-03-01 10:21:26 -0800752 ":drivetrain_config",
James Kuszmaul3e1bb272020-01-17 18:38:19 -0800753 ":drivetrain_status_fbs",
754 "//aos/events:event_loop",
755 "//frc971/control_loops:control_loops_fbs",
Austin Schuh0a3c9d42021-07-15 22:36:24 -0700756 "//frc971/control_loops:quaternion_utils",
Austin Schuhca080812017-05-10 19:31:55 -0700757 "//frc971/control_loops:runge_kutta",
James Kuszmaul3e1bb272020-01-17 18:38:19 -0800758 "@//aos/time",
Austin Schuhca080812017-05-10 19:31:55 -0700759 "@com_github_google_glog//:glog",
760 "@org_tuxfamily_eigen//:eigen",
761 ],
762)
763
764cc_test(
765 name = "improved_down_estimator_test",
766 srcs = [
767 "improved_down_estimator_test.cc",
768 ],
Philipp Schraderdada1072020-11-24 11:34:46 -0800769 target_compatible_with = ["@platforms//os:linux"],
Austin Schuhca080812017-05-10 19:31:55 -0700770 deps = [
James Kuszmaul7f55f072020-03-01 10:21:26 -0800771 ":drivetrain_test_lib",
Austin Schuhca080812017-05-10 19:31:55 -0700772 "//aos/testing:googletest",
773 "//aos/testing:random_seed",
Austin Schuh0a3c9d42021-07-15 22:36:24 -0700774 "//frc971/control_loops:quaternion_utils",
Austin Schuhca080812017-05-10 19:31:55 -0700775 "//frc971/control_loops/drivetrain:improved_down_estimator",
776 "@org_tuxfamily_eigen//:eigen",
777 ],
778)
James Kuszmaulf4ede202020-02-14 08:47:40 -0800779
780cc_library(
781 name = "camera",
782 srcs = ["camera.h"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800783 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaulf4ede202020-02-14 08:47:40 -0800784 visibility = ["//visibility:public"],
785 deps = [
786 "//aos/containers:sized_array",
787 "//frc971/control_loops:pose",
788 ],
789)
790
791cc_test(
792 name = "camera_test",
793 srcs = ["camera_test.cc"],
Philipp Schraderdada1072020-11-24 11:34:46 -0800794 target_compatible_with = ["@platforms//os:linux"],
James Kuszmaulf4ede202020-02-14 08:47:40 -0800795 deps = [
796 ":camera",
797 "//aos/testing:googletest",
798 ],
799)
James Kuszmaulc4ae11c2020-12-26 16:26:58 -0800800
Philipp Schrader3de4dfc2023-02-15 20:18:25 -0800801ts_project(
James Kuszmaulac2b6b42021-03-07 22:38:06 -0800802 name = "down_estimator_plotter",
803 srcs = ["down_estimator_plotter.ts"],
804 target_compatible_with = ["@platforms//os:linux"],
805 deps = [
806 "//aos/network/www:aos_plotter",
807 "//aos/network/www:colors",
808 "//aos/network/www:proxy",
809 "//frc971/wpilib:imu_plot_utils",
810 ],
811)
812
Philipp Schrader3de4dfc2023-02-15 20:18:25 -0800813ts_project(
James Kuszmaul73fc1352021-04-09 22:31:25 -0700814 name = "spline_plotter",
815 srcs = ["spline_plotter.ts"],
816 target_compatible_with = ["@platforms//os:linux"],
817 deps = [
818 "//aos/network/www:aos_plotter",
819 "//aos/network/www:colors",
820 "//aos/network/www:proxy",
821 ],
822)
823
Philipp Schrader3de4dfc2023-02-15 20:18:25 -0800824ts_project(
James Kuszmaulc4ae11c2020-12-26 16:26:58 -0800825 name = "drivetrain_plotter",
826 srcs = ["drivetrain_plotter.ts"],
827 target_compatible_with = ["@platforms//os:linux"],
828 deps = [
829 "//aos/network/www:aos_plotter",
James Kuszmaul933a9742021-03-07 19:59:06 -0800830 "//aos/network/www:colors",
James Kuszmaulc4ae11c2020-12-26 16:26:58 -0800831 "//aos/network/www:proxy",
832 "//frc971/wpilib:imu_plot_utils",
833 ],
834)
milind upadhyay9bd381d2021-01-23 13:44:13 -0800835
Philipp Schrader3de4dfc2023-02-15 20:18:25 -0800836ts_project(
milind upadhyay9bd381d2021-01-23 13:44:13 -0800837 name = "robot_state_plotter",
838 srcs = ["robot_state_plotter.ts"],
839 target_compatible_with = ["@platforms//os:linux"],
840 deps = [
841 "//aos/network/www:aos_plotter",
James Kuszmaul933a9742021-03-07 19:59:06 -0800842 "//aos/network/www:colors",
milind upadhyay9bd381d2021-01-23 13:44:13 -0800843 "//aos/network/www:proxy",
844 ],
845)
James Kuszmaul68025332024-01-20 17:06:02 -0800846
847static_flatbuffer(
848 name = "drivetrain_config_fbs",
849 srcs = ["drivetrain_config.fbs"],
850 visibility = ["//visibility:public"],
851 deps = ["//frc971/control_loops:state_feedback_loop_fbs"],
852)