blob: 6cae51862f2742fd0f4316ac1d11f984ba535c47 [file] [log] [blame]
Nikolai Sohmers3cc1fc22024-05-04 12:27:58 -07001#ifndef Y2024_SWERVE_SWERVE_PUBLISHER_H_
2#define Y2024_SWERVE_SWERVE_PUBLISHER_H_
Maxwell Hendersonf63a0d92023-06-24 14:49:51 -07003
Austin Schuh99f7c6a2024-06-25 22:07:44 -07004#include "absl/flags/flag.h"
5#include "absl/log/check.h"
6#include "absl/log/log.h"
Maxwell Hendersonf63a0d92023-06-24 14:49:51 -07007
8#include "aos/events/event_loop.h"
9#include "aos/flatbuffer_merge.h"
10#include "aos/init.h"
11#include "aos/json_to_flatbuffer.h"
James Kuszmauleaba6d92024-07-31 20:42:20 -070012#include "frc971/control_loops/swerve/swerve_drivetrain_goal_static.h"
Maxwell Hendersonf63a0d92023-06-24 14:49:51 -070013
Nikolai Sohmers3cc1fc22024-05-04 12:27:58 -070014namespace y2024_swerve {
Maxwell Hendersonf63a0d92023-06-24 14:49:51 -070015
Maxwell Hendersonf63a0d92023-06-24 14:49:51 -070016class SwervePublisher {
17 public:
18 SwervePublisher(aos::EventLoop *event_loop, aos::ExitHandle *exit_handle,
19 const std::string &filename, double duration);
20
James Kuszmauleaba6d92024-07-31 20:42:20 -070021 ~SwervePublisher();
22
Maxwell Hendersonf63a0d92023-06-24 14:49:51 -070023 private:
James Kuszmauleaba6d92024-07-31 20:42:20 -070024 aos::Sender<frc971::control_loops::swerve::GoalStatic>
25 drivetrain_goal_sender_;
Maxwell Hendersonf63a0d92023-06-24 14:49:51 -070026};
27
Nikolai Sohmers3cc1fc22024-05-04 12:27:58 -070028} // namespace y2024_swerve
Maxwell Hendersonf63a0d92023-06-24 14:49:51 -070029
Nikolai Sohmers3cc1fc22024-05-04 12:27:58 -070030#endif // Y2024_SWERVE_SWERVE_PUBLISHER_H_