diff options
author | Julian Oes <julian@oes.ch> | 2013-07-16 18:55:32 +0200 |
---|---|---|
committer | Julian Oes <julian@oes.ch> | 2013-07-16 18:56:31 +0200 |
commit | bcdedd9a35a5b9ebf3851a0d472adab8d3e7edac (patch) | |
tree | c91207643c0c9e1057dd1662556dbfe7f5b5322c /src/modules/mavlink/orb_listener.c | |
parent | 6e44a486c1511e980d54fead34676ea1bfed3b3d (diff) | |
download | px4-firmware-bcdedd9a35a5b9ebf3851a0d472adab8d3e7edac.tar.gz px4-firmware-bcdedd9a35a5b9ebf3851a0d472adab8d3e7edac.tar.bz2 px4-firmware-bcdedd9a35a5b9ebf3851a0d472adab8d3e7edac.zip |
Changed location of lots of flags and conditions, needs testing and more work
Diffstat (limited to 'src/modules/mavlink/orb_listener.c')
-rw-r--r-- | src/modules/mavlink/orb_listener.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/modules/mavlink/orb_listener.c b/src/modules/mavlink/orb_listener.c index 57a5d5dd5..d088d421e 100644 --- a/src/modules/mavlink/orb_listener.c +++ b/src/modules/mavlink/orb_listener.c @@ -272,7 +272,10 @@ l_vehicle_status(const struct listener *l) orb_copy(ORB_ID(actuator_armed), mavlink_subs.armed_sub, &armed); /* enable or disable HIL */ - set_hil_on_off(v_status.flag_hil_enabled); + if (v_status.hil_state == HIL_STATE_ON) + set_hil_on_off(true); + else if (v_status.hil_state == HIL_STATE_OFF) + set_hil_on_off(false); /* translate the current syste state to mavlink state and mode */ uint8_t mavlink_state = 0; |