Browse Source

Rover: guided mode slows to stopping point on init

mission-4.1.18
Randy Mackay 7 years ago
parent
commit
5dc4b8e66d
  1. 6
      APMrover2/mode_guided.cpp

6
APMrover2/mode_guided.cpp

@ -6,8 +6,10 @@ bool ModeGuided::_enter() @@ -6,8 +6,10 @@ bool ModeGuided::_enter()
// initialise waypoint speed
set_desired_speed_to_default();
// when entering guided mode we set the target as the current location.
set_desired_location(rover.current_loc);
// set desired location to reasonable stopping point
Location stopping_point;
calc_stopping_location(_destination);
set_desired_location(stopping_point);
return true;
}

Loading…
Cancel
Save