diff options
author | Thomas Gubler <thomasgubler@gmail.com> | 2014-08-19 07:30:19 +0200 |
---|---|---|
committer | Thomas Gubler <thomasgubler@gmail.com> | 2014-08-19 07:30:19 +0200 |
commit | 7f9c996555975301288da58745f69b39f05facbe (patch) | |
tree | 560bb92814ad9b21a2c5b0bbae8eaf1ad6da746b /src/modules | |
parent | 99860da9b70bfa87ef2834efa5e7b9ba96ee4e9b (diff) | |
download | px4-firmware-7f9c996555975301288da58745f69b39f05facbe.tar.gz px4-firmware-7f9c996555975301288da58745f69b39f05facbe.tar.bz2 px4-firmware-7f9c996555975301288da58745f69b39f05facbe.zip |
engine fail: small state machine fix
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/navigator/enginefailure.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/modules/navigator/enginefailure.cpp b/src/modules/navigator/enginefailure.cpp index de567f0dc..e007b208b 100644 --- a/src/modules/navigator/enginefailure.cpp +++ b/src/modules/navigator/enginefailure.cpp @@ -76,7 +76,8 @@ EngineFailure::on_inactive() void EngineFailure::on_activation() { - _ef_state = EF_STATE_LOITERDOWN; + _ef_state = EF_STATE_NONE; + advance_ef(); set_ef_item(); } @@ -139,6 +140,7 @@ EngineFailure::advance_ef() { switch (_ef_state) { case EF_STATE_NONE: + mavlink_log_info(_navigator->get_mavlink_fd(), "#audio: Engine failure. Loitering down"); _ef_state = EF_STATE_LOITERDOWN; break; default: |