altos: Send serial/flight to companion board
authorKeith Packard <keithp@keithp.com>
Sun, 14 Aug 2011 01:30:00 +0000 (18:30 -0700)
committerKeith Packard <keithp@keithp.com>
Sun, 14 Aug 2011 01:46:12 +0000 (18:46 -0700)
Lets the companion log them for later matching with TeleMetrum log

Signed-off-by: Keith Packard <keithp@keithp.com>
src/ao.h
src/ao_companion.c

index b14b65f..6a4da31 100644 (file)
--- a/src/ao.h
+++ b/src/ao.h
@@ -1587,6 +1587,8 @@ struct ao_companion_command {
        uint8_t         command;
        uint8_t         flight_state;
        uint16_t        tick;
+       uint16_t        serial;
+       uint16_t        flight;
 };
 
 struct ao_companion_setup {
index f0ce3f1..8f23ba2 100644 (file)
@@ -43,6 +43,8 @@ ao_companion_send_command(uint8_t command)
        ao_companion_command.command = command;
        ao_companion_command.flight_state = ao_flight_state;
        ao_companion_command.tick = ao_time();
+       ao_companion_command.serial = ao_serial_number;
+       ao_companion_command.flight = ao_flight_number;
        ao_spi_send(&ao_companion_command, sizeof (ao_companion_command));
 }