blob: 1ff531cd9baedc5019a85a88904631a96241488d [file] [log] [blame]
Austin Schuh2a3e0632018-02-19 16:24:49 -08001load("//aos/downloader:downloader.bzl", "aos_downloader")
Brian Silverman37281fc2018-03-11 18:42:17 -07002load("//aos/build:queues.bzl", "queue_library")
Neil Balchacfca5b2018-01-28 14:04:08 -08003
4aos_downloader(
Austin Schuh2a3e0632018-02-19 16:24:49 -08005 name = "download",
6 srcs = [
7 "//aos:prime_binaries",
8 ],
9 restricted_to = ["//tools:roborio"],
10 start_srcs = [
11 ":joystick_reader",
12 ":wpilib_interface",
13 "//aos:prime_start_binaries",
14 "//y2018/control_loops/drivetrain:drivetrain",
Austin Schuh6829f762018-03-02 21:36:01 -080015 "//y2018/control_loops/superstructure:superstructure.stripped",
Austin Schuh2a3e0632018-02-19 16:24:49 -080016 ],
Neil Balchacfca5b2018-01-28 14:04:08 -080017)
18
19aos_downloader(
Austin Schuh2a3e0632018-02-19 16:24:49 -080020 name = "download_stripped",
21 srcs = [
22 "//aos:prime_binaries_stripped",
23 ],
24 restricted_to = ["//tools:roborio"],
25 start_srcs = [
26 ":joystick_reader.stripped",
27 ":wpilib_interface.stripped",
28 "//aos:prime_start_binaries_stripped",
29 "//y2018/control_loops/drivetrain:drivetrain.stripped",
Austin Schuh6829f762018-03-02 21:36:01 -080030 "//y2018/control_loops/superstructure:superstructure.stripped",
Austin Schuh2a3e0632018-02-19 16:24:49 -080031 ],
Neil Balchacfca5b2018-01-28 14:04:08 -080032)
33
34cc_binary(
Austin Schuh2a3e0632018-02-19 16:24:49 -080035 name = "joystick_reader",
36 srcs = [
37 "joystick_reader.cc",
38 ],
39 deps = [
40 "//aos/common:time",
41 "//aos/common/actions:action_lib",
42 "//aos/common/logging",
43 "//aos/common/util:log_interval",
44 "//aos/input:drivetrain_input",
45 "//aos/input:joystick_input",
46 "//aos/linux_code:init",
47 "//frc971/autonomous:auto_queue",
48 "//frc971/control_loops/drivetrain:drivetrain_queue",
49 "//y2018/control_loops/drivetrain:drivetrain_base",
50 "//y2018/control_loops/superstructure:superstructure_queue",
Austin Schuhab15c4d2018-03-09 21:21:03 -080051 "//y2018/control_loops/superstructure/arm:generated_graph",
Austin Schuh2a3e0632018-02-19 16:24:49 -080052 ],
53)
54
55cc_library(
56 name = "constants",
57 srcs = [
58 "constants.cc",
59 ],
60 hdrs = [
61 "constants.h",
62 ],
63 visibility = ["//visibility:public"],
64 deps = [
65 "//aos:once",
66 "//aos/common:mutex",
67 "//aos/common/logging",
68 "//aos/common/network:team_number",
69 "//frc971:constants",
70 "//frc971/shooter_interpolation:interpolation",
71 "//y2018/control_loops/drivetrain:polydrivetrain_plants",
72 "//y2018/control_loops/superstructure/arm:dynamics",
73 "//y2018/control_loops/superstructure/intake:intake_plants",
74 ],
75)
76
77cc_binary(
78 name = "wpilib_interface",
79 srcs = [
80 "wpilib_interface.cc",
81 ],
82 restricted_to = ["//tools:roborio"],
83 deps = [
Brian Silverman37281fc2018-03-11 18:42:17 -070084 ":status_light",
Austin Schuh2a3e0632018-02-19 16:24:49 -080085 "//aos/common:math",
86 "//aos/common:stl_mutex",
87 "//aos/common:time",
88 "//aos/common/controls:control_loop",
89 "//aos/common/logging",
90 "//aos/common/logging:queue_logging",
91 "//aos/common/messages:robot_state",
92 "//aos/common/util:log_interval",
93 "//aos/common/util:phased_loop",
94 "//aos/common/util:wrapping_counter",
95 "//aos/linux_code:init",
96 "//frc971/autonomous:auto_queue",
97 "//frc971/control_loops:queues",
98 "//frc971/control_loops/drivetrain:drivetrain_queue",
99 "//frc971/wpilib:ADIS16448",
100 "//frc971/wpilib:buffered_pcm",
101 "//frc971/wpilib:dma",
102 "//frc971/wpilib:dma_edge_counting",
103 "//frc971/wpilib:encoder_and_potentiometer",
Austin Schuh2a3e0632018-02-19 16:24:49 -0800104 "//frc971/wpilib:interrupt_edge_counting",
105 "//frc971/wpilib:joystick_sender",
106 "//frc971/wpilib:logging_queue",
107 "//frc971/wpilib:loop_output_handler",
108 "//frc971/wpilib:pdp_fetcher",
109 "//frc971/wpilib:wpilib_interface",
110 "//frc971/wpilib:wpilib_robot_base",
111 "//third_party:wpilib",
Brian Silverman37281fc2018-03-11 18:42:17 -0700112 "//third_party/Phoenix-frc-lib:phoenix",
Austin Schuh2a3e0632018-02-19 16:24:49 -0800113 "//y2018:constants",
114 "//y2018/control_loops/superstructure:superstructure_queue",
115 ],
Neil Balchacfca5b2018-01-28 14:04:08 -0800116)
Brian Silverman37281fc2018-03-11 18:42:17 -0700117
118queue_library(
119 name = "status_light",
120 srcs = [
121 "status_light.q",
122 ],
123)