blob: 4b88402f8c9d3d567da373454730cba4c912016c [file] [log] [blame]
James (Peilun) Lia70e5752024-09-18 20:43:00 -07001#include <unistd.h>
2
3#include <cmath>
4#include <cstdio>
5#include <cstring>
6
7#include "absl/flags/flag.h"
8
9#include "aos/actions/actions.h"
10#include "aos/init.h"
11#include "aos/logging/logging.h"
12#include "aos/network/team_number.h"
13#include "aos/util/log_interval.h"
14#include "frc971/autonomous/base_autonomous_actor.h"
15#include "frc971/constants/constants_sender_lib.h"
16#include "frc971/control_loops/drivetrain/localizer_generated.h"
17#include "frc971/control_loops/profiled_subsystem_generated.h"
18#include "frc971/control_loops/static_zeroing_single_dof_profiled_subsystem.h"
19#include "frc971/input/action_joystick_input.h"
20#include "frc971/input/driver_station_data.h"
21#include "frc971/input/drivetrain_input.h"
22#include "frc971/input/joystick_input.h"
23#include "frc971/input/redundant_joystick_data.h"
24#include "frc971/zeroing/wrap.h"
25#include "y2024_bot3/constants/constants_generated.h"
26#include "y2024_bot3/control_loops/superstructure/superstructure_goal_static.h"
27#include "y2024_bot3/control_loops/superstructure/superstructure_status_static.h"
28
29using frc971::CreateProfileParameters;
30using frc971::input::driver_station::ButtonLocation;
31using frc971::input::driver_station::ControlBit;
32using frc971::input::driver_station::JoystickAxis;
33using frc971::input::driver_station::POVLocation;
34
35namespace y2024_bot3::input::joysticks {
36
37namespace superstructure = y2024_bot3::control_loops::superstructure;
38
39// ButtonLocation constants go here
40
41class Reader : public ::frc971::input::ActionJoystickInput {};
42} // namespace y2024_bot3::input::joysticks
43
44int main(int argc, char **argv) {
45 ::aos::InitGoogle(&argc, &argv);
46
47 aos::FlatbufferDetachedBuffer<aos::Configuration> config =
48 aos::configuration::ReadConfig("aos_config.json");
49 frc971::constants::WaitForConstants<y2024_bot3::Constants>(&config.message());
50
51 ::aos::ShmEventLoop constant_fetcher_event_loop(&config.message());
52 frc971::constants::ConstantsFetcher<y2024_bot3::Constants> constants_fetcher(
53 &constant_fetcher_event_loop);
54 const y2024_bot3::Constants *robot_constants = &constants_fetcher.constants();
55
56 ::aos::ShmEventLoop event_loop(&config.message());
57 (void)robot_constants;
58 //::y2024_bot3::input::joysticks::Reader reader(&event_loop, robot_constants);
59
60 event_loop.Run();
61
62 return 0;
63}