James Kuszmaul | 7077d34 | 2021-06-09 20:23:58 -0700 | [diff] [blame] | 1 | load("//aos:config.bzl", "aos_config") |
| 2 | load("@com_github_google_flatbuffers//:build_defs.bzl", "flatbuffer_cc_library") |
| 3 | |
Philipp Schrader | cc016b3 | 2021-12-30 08:59:58 -0800 | [diff] [blame^] | 4 | package(default_visibility = ["//visibility:public"]) |
| 5 | |
Brian Silverman | 100534c | 2015-09-07 15:51:23 -0400 | [diff] [blame] | 6 | cc_library( |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 7 | name = "joystick_input", |
| 8 | srcs = [ |
| 9 | "joystick_input.cc", |
| 10 | ], |
| 11 | hdrs = [ |
| 12 | "joystick_input.h", |
| 13 | ], |
Philipp Schrader | dada107 | 2020-11-24 11:34:46 -0800 | [diff] [blame] | 14 | target_compatible_with = ["@platforms//os:linux"], |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 15 | deps = [ |
James Kuszmaul | 7077d34 | 2021-06-09 20:23:58 -0700 | [diff] [blame] | 16 | ":robot_state_fbs", |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 17 | "//aos/events:event_loop", |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 18 | "//aos/logging", |
Austin Schuh | 0a3c9d4 | 2021-07-15 22:36:24 -0700 | [diff] [blame] | 19 | "//frc971/input:driver_station_data", |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 20 | ], |
Brian Silverman | 100534c | 2015-09-07 15:51:23 -0400 | [diff] [blame] | 21 | ) |
Sabina Davis | 92d2efa | 2017-11-04 22:35:25 -0700 | [diff] [blame] | 22 | |
| 23 | cc_library( |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 24 | name = "drivetrain_input", |
| 25 | srcs = [ |
| 26 | "drivetrain_input.cc", |
| 27 | ], |
| 28 | hdrs = [ |
| 29 | "drivetrain_input.h", |
| 30 | ], |
Philipp Schrader | dada107 | 2020-11-24 11:34:46 -0800 | [diff] [blame] | 31 | target_compatible_with = ["@platforms//os:linux"], |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 32 | deps = [ |
James Kuszmaul | 7077d34 | 2021-06-09 20:23:58 -0700 | [diff] [blame] | 33 | ":robot_state_fbs", |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 34 | "//aos:math", |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 35 | "//aos/logging", |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 36 | "//frc971/control_loops:control_loops_fbs", |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 37 | "//frc971/control_loops/drivetrain:drivetrain_config", |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 38 | "//frc971/control_loops/drivetrain:drivetrain_goal_fbs", |
| 39 | "//frc971/control_loops/drivetrain:drivetrain_status_fbs", |
James Kuszmaul | 75a18c5 | 2021-03-10 22:02:07 -0800 | [diff] [blame] | 40 | "//frc971/control_loops/drivetrain:spline_goal_fbs", |
Austin Schuh | 0a3c9d4 | 2021-07-15 22:36:24 -0700 | [diff] [blame] | 41 | "//frc971/input:driver_station_data", |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 42 | ], |
Sabina Davis | 92d2efa | 2017-11-04 22:35:25 -0700 | [diff] [blame] | 43 | ) |
John Park | 33858a3 | 2018-09-28 23:05:48 -0700 | [diff] [blame] | 44 | |
| 45 | cc_library( |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 46 | name = "driver_station_data", |
| 47 | srcs = [ |
| 48 | "driver_station_data.cc", |
| 49 | ], |
| 50 | hdrs = [ |
| 51 | "driver_station_data.h", |
| 52 | ], |
Philipp Schrader | dada107 | 2020-11-24 11:34:46 -0800 | [diff] [blame] | 53 | target_compatible_with = ["@platforms//os:linux"], |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 54 | deps = [ |
James Kuszmaul | 7077d34 | 2021-06-09 20:23:58 -0700 | [diff] [blame] | 55 | ":joystick_state_fbs", |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 56 | "@com_github_google_glog//:glog", |
Austin Schuh | 3e45c75 | 2019-02-02 12:19:11 -0800 | [diff] [blame] | 57 | ], |
John Park | 33858a3 | 2018-09-28 23:05:48 -0700 | [diff] [blame] | 58 | ) |
Sabina Davis | 91b2360 | 2019-01-21 00:06:01 -0800 | [diff] [blame] | 59 | |
| 60 | cc_library( |
| 61 | name = "action_joystick_input", |
| 62 | srcs = ["action_joystick_input.cc"], |
| 63 | hdrs = ["action_joystick_input.h"], |
Philipp Schrader | dada107 | 2020-11-24 11:34:46 -0800 | [diff] [blame] | 64 | target_compatible_with = ["@platforms//os:linux"], |
Sabina Davis | 91b2360 | 2019-01-21 00:06:01 -0800 | [diff] [blame] | 65 | deps = [ |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 66 | ":drivetrain_input", |
Sabina Davis | 91b2360 | 2019-01-21 00:06:01 -0800 | [diff] [blame] | 67 | "//aos:init", |
| 68 | "//aos/actions:action_lib", |
Sabina Davis | 91b2360 | 2019-01-21 00:06:01 -0800 | [diff] [blame] | 69 | "//aos/logging", |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 70 | "//frc971/autonomous:auto_fbs", |
Austin Schuh | ed5b26d | 2019-12-05 20:51:59 -0800 | [diff] [blame] | 71 | "//frc971/autonomous:auto_mode_fbs", |
Sabina Davis | 91b2360 | 2019-01-21 00:06:01 -0800 | [diff] [blame] | 72 | "//frc971/autonomous:base_autonomous_actor", |
Austin Schuh | 0a3c9d4 | 2021-07-15 22:36:24 -0700 | [diff] [blame] | 73 | "//frc971/input:joystick_input", |
Sabina Davis | 91b2360 | 2019-01-21 00:06:01 -0800 | [diff] [blame] | 74 | ], |
| 75 | ) |
James Kuszmaul | 7077d34 | 2021-06-09 20:23:58 -0700 | [diff] [blame] | 76 | |
| 77 | flatbuffer_cc_library( |
| 78 | name = "robot_state_fbs", |
| 79 | srcs = ["robot_state.fbs"], |
| 80 | gen_reflections = 1, |
| 81 | target_compatible_with = ["@platforms//os:linux"], |
| 82 | ) |
| 83 | |
| 84 | flatbuffer_cc_library( |
| 85 | name = "joystick_state_fbs", |
| 86 | srcs = ["joystick_state.fbs"], |
| 87 | gen_reflections = 1, |
| 88 | target_compatible_with = ["@platforms//os:linux"], |
| 89 | ) |
| 90 | |
| 91 | aos_config( |
| 92 | name = "config", |
| 93 | src = "robot_state_config.json", |
| 94 | flatbuffers = [ |
| 95 | ":joystick_state_fbs", |
| 96 | ":robot_state_fbs", |
| 97 | ], |
| 98 | target_compatible_with = ["@platforms//os:linux"], |
| 99 | visibility = ["//visibility:public"], |
| 100 | deps = ["//aos/events:config"], |
| 101 | ) |