mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-23 02:33:34 +08:00
Enable DO_SET_SPEED commands outside of missions in other AUTO modes (#18834)
* Navigator: enable DO_CHANGE_SPEED for outside of mission - update _mission_cruising_speed_mc/_fw also if DO_CHANGE_SPEED command is received outside of mission (e.g. while Loitering doing an Orbit) - if vehicle is in AUTO_LOITER when receiving the change speed, then immediately apply it by doing a reposition without updating any other field than cruising_speed and cruising_throttle -when RTL is activated reset the cruising speed and throttle * Navigator: reset cruise speed and throttle to default when VTOL-transitioning Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
This commit is contained in:
@@ -96,11 +96,6 @@ void Mission::mission_init()
|
||||
void
|
||||
Mission::on_inactive()
|
||||
{
|
||||
/* We need to reset the mission cruising speed, otherwise the
|
||||
* mission velocity which might have been set using mission items
|
||||
* is used for missions such as RTL. */
|
||||
_navigator->set_cruising_speed();
|
||||
|
||||
// if we were executing an landing but have been inactive for 2 seconds, then make the landing invalid
|
||||
// this prevents RTL to just continue at the current mission index
|
||||
if (_navigator->getMissionLandingInProgress() && (hrt_absolute_time() - _time_mission_deactivated) > 2_s) {
|
||||
|
||||
Reference in New Issue
Block a user