aboutsummaryrefslogtreecommitdiff
path: root/apps/px4io/protocol.h
diff options
context:
space:
mode:
authorpx4dev <px4@purgatory.org>2012-08-18 22:56:04 -0700
committerpx4dev <px4@purgatory.org>2012-08-18 22:56:04 -0700
commit84777544114d3d185a2fee0d30e3187c7f6ab27e (patch)
tree13e58186732ca45040b928a6c535ad83e3c3de4b /apps/px4io/protocol.h
parentfcad5b52c52484470c897cdde745e62008c61e7d (diff)
downloadpx4-firmware-84777544114d3d185a2fee0d30e3187c7f6ab27e.tar.gz
px4-firmware-84777544114d3d185a2fee0d30e3187c7f6ab27e.tar.bz2
px4-firmware-84777544114d3d185a2fee0d30e3187c7f6ab27e.zip
Share the PX4IO protocol header, such as it is, between the two apps.
Stop using systemlib in the PX4IO firmware; it has expectations that can't reasonably be met.
Diffstat (limited to 'apps/px4io/protocol.h')
-rw-r--r--apps/px4io/protocol.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/apps/px4io/protocol.h b/apps/px4io/protocol.h
index 92558a61d..96e0ca350 100644
--- a/apps/px4io/protocol.h
+++ b/apps/px4io/protocol.h
@@ -48,6 +48,8 @@
#define PX4IO_INPUT_CHANNELS 12
#define PX4IO_RELAY_CHANNELS 2
+#pragma pack(push, 1)
+
/* command from FMU to IO */
struct px4io_command {
uint16_t f2i_magic;
@@ -56,7 +58,7 @@ struct px4io_command {
uint16_t servo_command[PX4IO_OUTPUT_CHANNELS];
bool relay_state[PX4IO_RELAY_CHANNELS];
bool arm_ok;
-} __attribute__((packed));
+};
/* report from IO to FMU */
struct px4io_report {
@@ -66,4 +68,6 @@ struct px4io_report {
uint16_t rc_channel[PX4IO_INPUT_CHANNELS];
bool armed;
uint8_t channel_count;
-} __attribute__((packed));
+};
+
+#pragma pack(pop) \ No newline at end of file