Austin Schuh | 99f7c6a | 2024-06-25 22:07:44 -0700 | [diff] [blame] | 1 | #include "absl/flags/flag.h" |
| 2 | |
James Kuszmaul | 910fbe4 | 2023-04-09 16:18:40 -0700 | [diff] [blame] | 3 | #include "aos/events/shm_event_loop.h" |
| 4 | #include "aos/init.h" |
| 5 | #include "y2023/vision/camera_monitor_lib.h" |
| 6 | |
Austin Schuh | 99f7c6a | 2024-06-25 22:07:44 -0700 | [diff] [blame] | 7 | ABSL_FLAG(std::string, config, "aos_config.json", |
| 8 | "Path to the config file to use."); |
James Kuszmaul | 910fbe4 | 2023-04-09 16:18:40 -0700 | [diff] [blame] | 9 | |
| 10 | int main(int argc, char *argv[]) { |
| 11 | aos::InitGoogle(&argc, &argv); |
| 12 | |
| 13 | aos::FlatbufferDetachedBuffer<aos::Configuration> config = |
Austin Schuh | 99f7c6a | 2024-06-25 22:07:44 -0700 | [diff] [blame] | 14 | aos::configuration::ReadConfig(absl::GetFlag(FLAGS_config)); |
James Kuszmaul | 910fbe4 | 2023-04-09 16:18:40 -0700 | [diff] [blame] | 15 | |
| 16 | aos::ShmEventLoop event_loop(&config.message()); |
| 17 | |
| 18 | y2023::vision::CameraMonitor monitor(&event_loop); |
| 19 | |
| 20 | event_loop.Run(); |
| 21 | } |