blob: c10baaeb35d582149d1dfb3e8f74961458dbe49e [file] [log] [blame]
Brian Silverman8c374e02015-09-06 23:02:21 -04001package(default_visibility = ['//visibility:public'])
2
Austin Schuhf0736512015-09-07 01:22:16 -07003load('/aos/build/queues', 'queue_library')
Brian Silverman8c374e02015-09-06 23:02:21 -04004
5cc_binary(
6 name = 'replay_shooter',
7 srcs = [
8 'replay_shooter.cc',
9 ],
10 deps = [
11 ':shooter_queue',
12 '//aos/common/controls:replay_control_loop',
13 '//aos/linux_code:init',
14 ],
15)
16
17queue_library(
18 name = 'shooter_queue',
19 srcs = [
20 'shooter.q',
21 ],
Brian Silverman100534c2015-09-07 15:51:23 -040022 deps = [
23 '//aos/common/controls:control_loop_queues',
24 '//frc971/control_loops:queues',
25 ],
Brian Silverman8c374e02015-09-06 23:02:21 -040026)
27
Austin Schuh9d4aca82015-11-08 14:41:31 -080028genrule(
29 name = 'genrule_shooter',
30 visibility = ['//visibility:private'],
31 cmd = '$(location //y2014/control_loops/python:shooter) $(OUTS)',
32 tools = [
33 '//y2014/control_loops/python:shooter',
34 ],
Austin Schuh9d4aca82015-11-08 14:41:31 -080035 outs = [
36 'shooter_motor_plant.cc',
37 'shooter_motor_plant.h',
38 'unaugmented_shooter_motor_plant.cc',
39 'unaugmented_shooter_motor_plant.h',
40 ],
41)
42
Brian Silverman8c374e02015-09-06 23:02:21 -040043cc_library(
44 name = 'shooter_lib',
45 srcs = [
46 'shooter.cc',
47 'shooter_motor_plant.cc',
48 'unaugmented_shooter_motor_plant.cc',
49 ],
Brian Silverman100534c2015-09-07 15:51:23 -040050 hdrs = [
51 'shooter.h',
52 'shooter_motor_plant.h',
53 'unaugmented_shooter_motor_plant.h',
54 ],
Brian Silverman8c374e02015-09-06 23:02:21 -040055 deps = [
56 ':shooter_queue',
57 '//aos/common/controls:control_loop',
58 '//y2014:constants',
59 '//frc971/control_loops:state_feedback_loop',
60 '//aos/common/logging:queue_logging',
Austin Schuh55139fe2015-10-14 23:55:24 -070061 '//debian:libm',
Brian Silverman8c374e02015-09-06 23:02:21 -040062 ],
63)
64
Brian Silverman100534c2015-09-07 15:51:23 -040065cc_test(
Brian Silverman8c374e02015-09-06 23:02:21 -040066 name = 'shooter_lib_test',
67 srcs = [
68 'shooter_lib_test.cc',
69 ],
70 deps = [
Brian Silverman258b9172015-09-19 14:32:57 -040071 '//aos/testing:googletest',
Brian Silverman8c374e02015-09-06 23:02:21 -040072 ':shooter_queue',
73 ':shooter_lib',
74 '//aos/common/controls:control_loop_test',
75 '//frc971/control_loops:state_feedback_loop',
76 ],
77)
78
79cc_binary(
80 name = 'shooter',
81 srcs = [
82 'shooter_main.cc',
83 ],
84 deps = [
85 '//aos/linux_code:init',
86 ':shooter_lib',
87 ],
88)