Browse Source

Plane: on takeoff set prev_WP_loc to current_loc

master
Andrew Tridgell 10 years ago
parent
commit
1e3c23e5a3
  1. 1
      ArduPlane/commands_logic.pde

1
ArduPlane/commands_logic.pde

@ -304,6 +304,7 @@ static void do_RTL(void) @@ -304,6 +304,7 @@ static void do_RTL(void)
static void do_takeoff(const AP_Mission::Mission_Command& cmd)
{
prev_WP_loc = current_loc;
set_next_WP(cmd.content.location);
// pitch in deg, airspeed m/s, throttle %, track WP 1 or 0
auto_state.takeoff_pitch_cd = (int16_t)cmd.p1 * 100;

Loading…
Cancel
Save