blob: f80128d46400fdd28e3596d6fe953b74651d0d8e [file] [log] [blame]
Austin Schuheb99d072019-05-12 21:03:38 -07001package(default_visibility = ["//visibility:public"])
Comran Morshed9a9948c2016-01-16 15:58:04 +00002
Alex Perrycb7da4b2019-08-28 19:35:56 -07003load("@com_github_google_flatbuffers//:build_defs.bzl", "flatbuffer_cc_library")
Comran Morshed9a9948c2016-01-16 15:58:04 +00004
5filegroup(
Austin Schuheb99d072019-05-12 21:03:38 -07006 name = "binaries",
7 srcs = [
8 ":autonomous_action",
9 ":superstructure_action",
10 ],
Comran Morshed9a9948c2016-01-16 15:58:04 +000011)
12
Alex Perrycb7da4b2019-08-28 19:35:56 -070013flatbuffer_cc_library(
14 name = "superstructure_action_fbs",
Austin Schuheb99d072019-05-12 21:03:38 -070015 srcs = [
Alex Perrycb7da4b2019-08-28 19:35:56 -070016 "superstructure_action.fbs",
Austin Schuheb99d072019-05-12 21:03:38 -070017 ],
Alex Perrycb7da4b2019-08-28 19:35:56 -070018 gen_reflections = 1,
19 visibility = ["//visibility:public"],
Comran Morshed2f7b4672016-01-23 14:27:34 +000020)
21
22cc_library(
Austin Schuheb99d072019-05-12 21:03:38 -070023 name = "superstructure_action_lib",
24 srcs = [
25 "superstructure_actor.cc",
26 ],
27 hdrs = [
28 "superstructure_actor.h",
29 ],
30 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -070031 ":superstructure_action_fbs",
Austin Schuheb99d072019-05-12 21:03:38 -070032 "//aos/actions:action_lib",
Alex Perrycb7da4b2019-08-28 19:35:56 -070033 "//aos/events:event_loop",
Austin Schuheb99d072019-05-12 21:03:38 -070034 "//aos/logging",
35 "//aos/util:phased_loop",
Alex Perrycb7da4b2019-08-28 19:35:56 -070036 "//frc971/control_loops:control_loops_fbs",
37 "//y2016/control_loops/superstructure:superstructure_goal_fbs",
38 "//y2016/control_loops/superstructure:superstructure_status_fbs",
Austin Schuheb99d072019-05-12 21:03:38 -070039 ],
Comran Morshed2f7b4672016-01-23 14:27:34 +000040)
41
42cc_binary(
Austin Schuheb99d072019-05-12 21:03:38 -070043 name = "superstructure_action",
44 srcs = [
45 "superstructure_actor_main.cc",
46 ],
47 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -070048 ":superstructure_action_fbs",
Austin Schuheb99d072019-05-12 21:03:38 -070049 ":superstructure_action_lib",
Austin Schuheb99d072019-05-12 21:03:38 -070050 "//aos:init",
Alex Perrycb7da4b2019-08-28 19:35:56 -070051 "//aos/events:shm_event_loop",
Austin Schuheb99d072019-05-12 21:03:38 -070052 ],
Comran Morshed2f7b4672016-01-23 14:27:34 +000053)
Comran Morshede68e3732016-03-12 14:12:11 +000054
Comran Morshede68e3732016-03-12 14:12:11 +000055cc_library(
Austin Schuheb99d072019-05-12 21:03:38 -070056 name = "autonomous_action_lib",
57 srcs = [
58 "autonomous_actor.cc",
59 ],
60 hdrs = [
61 "autonomous_actor.h",
62 ],
63 deps = [
64 ":vision_align_action_lib",
65 "//aos/actions:action_lib",
66 "//aos/logging",
67 "//aos/util:phased_loop",
68 "//frc971/autonomous:base_autonomous_actor",
Austin Schuheb99d072019-05-12 21:03:38 -070069 "//y2016/control_loops/drivetrain:drivetrain_base",
Alex Perrycb7da4b2019-08-28 19:35:56 -070070 "//y2016/control_loops/shooter:shooter_goal_fbs",
71 "//y2016/control_loops/shooter:shooter_status_fbs",
72 "//y2016/control_loops/superstructure:superstructure_goal_fbs",
73 "//y2016/control_loops/superstructure:superstructure_status_fbs",
74 "//y2016/queues:ball_detector_fbs",
75 "//y2016/vision:vision_fbs",
Austin Schuheb99d072019-05-12 21:03:38 -070076 ],
Comran Morshede68e3732016-03-12 14:12:11 +000077)
78
79cc_binary(
Austin Schuheb99d072019-05-12 21:03:38 -070080 name = "autonomous_action",
81 srcs = [
82 "autonomous_actor_main.cc",
83 ],
84 deps = [
85 ":autonomous_action_lib",
86 "//aos:init",
87 ],
Comran Morshede68e3732016-03-12 14:12:11 +000088)
Austin Schuh18799112016-03-16 22:09:54 -070089
Alex Perrycb7da4b2019-08-28 19:35:56 -070090flatbuffer_cc_library(
91 name = "vision_align_action_fbs",
Austin Schuheb99d072019-05-12 21:03:38 -070092 srcs = [
Alex Perrycb7da4b2019-08-28 19:35:56 -070093 "vision_align_action.fbs",
Austin Schuheb99d072019-05-12 21:03:38 -070094 ],
Alex Perrycb7da4b2019-08-28 19:35:56 -070095 gen_reflections = 1,
96 visibility = ["//visibility:public"],
Austin Schuh18799112016-03-16 22:09:54 -070097)
98
99cc_library(
Austin Schuheb99d072019-05-12 21:03:38 -0700100 name = "vision_align_action_lib",
101 srcs = [
102 "vision_align_actor.cc",
103 ],
104 hdrs = [
105 "vision_align_actor.h",
106 ],
107 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -0700108 ":vision_align_action_fbs",
Austin Schuheb99d072019-05-12 21:03:38 -0700109 "//aos:math",
110 "//aos/actions:action_lib",
111 "//aos/logging",
Austin Schuheb99d072019-05-12 21:03:38 -0700112 "//aos/time",
113 "//aos/util:phased_loop",
114 "//aos/util:trapezoid_profile",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700115 "//frc971/control_loops:control_loops_fbs",
116 "//frc971/control_loops/drivetrain:drivetrain_goal_fbs",
Austin Schuheb99d072019-05-12 21:03:38 -0700117 "//y2016:constants",
118 "//y2016/control_loops/drivetrain:drivetrain_base",
Alex Perrycb7da4b2019-08-28 19:35:56 -0700119 "//y2016/vision:vision_fbs",
120 "@org_tuxfamily_eigen//:eigen",
Austin Schuheb99d072019-05-12 21:03:38 -0700121 ],
Austin Schuh18799112016-03-16 22:09:54 -0700122)
123
124cc_binary(
Austin Schuheb99d072019-05-12 21:03:38 -0700125 name = "vision_align_action",
126 srcs = [
127 "vision_align_actor_main.cc",
128 ],
129 deps = [
Alex Perrycb7da4b2019-08-28 19:35:56 -0700130 ":vision_align_action_fbs",
Austin Schuheb99d072019-05-12 21:03:38 -0700131 ":vision_align_action_lib",
Austin Schuheb99d072019-05-12 21:03:38 -0700132 "//aos:init",
133 ],
Austin Schuh18799112016-03-16 22:09:54 -0700134)