Wait for VTOL transition command to complete

This commit is contained in:
sander
2016-04-02 21:29:26 +01:00
committed by Lorenz Meier
parent 240c8fbee1
commit b99e3e0ae2
2 changed files with 3 additions and 8 deletions
+3 -2
View File
@@ -112,10 +112,11 @@ MissionBlock::is_mission_item_reached()
* We wait half a second to give the transition command time to propagate.
* As soon as the timeout is over or when we're in transition mode let the mission continue.
*/
if (hrt_absolute_time() - _action_start > 500000 ||
_navigator->get_vstatus()->in_transition_mode) {
if (hrt_absolute_time() - _action_start > 500000 &&
!_navigator->get_vstatus()->in_transition_mode) {
_action_start = 0;
printf("transition reached \n");
return true;
} else {