Add boilerplate localizer code for LED control
Will use this to turn LEDs facing away from the target off
Signed-off-by: Milind Upadhyay <milind.upadhyay@gmail.com>
Change-Id: I4e03778f6b06db87b26ab3986dfebab7840d6de1
diff --git a/y2022/localizer/localizer_output.fbs b/y2022/localizer/localizer_output.fbs
index b07278b..ec3302a 100644
--- a/y2022/localizer/localizer_output.fbs
+++ b/y2022/localizer/localizer_output.fbs
@@ -10,6 +10,12 @@
z:double (id: 3);
}
+// Used to tell different LEDs to be on or off
+enum LedOutput : byte {
+ ON,
+ OFF
+}
+
table LocalizerOutput {
// Timestamp (on the source node) that this sample corresponds with. This
// may be older than the sent time to account for delays in sensor readings.
@@ -24,6 +30,10 @@
// Whether we have zeroed the IMU (may go false if we observe a fault with the
// IMU).
zeroed:bool (id: 5);
+
+ // Whether each led should be on.
+ // Indices correspond to pi number.
+ led_outputs:[LedOutput] (id: 6);
}
root_type LocalizerOutput;