mirror of https://github.com/ArduPilot/ardupilot
upped max target speed to center of loiter
This commit is contained in:
parent
1851dd541b
commit
8cc480f7e6
|
@ -103,7 +103,7 @@ static void calc_loiter(int x_error, int y_error)
|
||||||
{
|
{
|
||||||
// East/West
|
// East/West
|
||||||
int16_t x_target_speed = g.pi_loiter_lon.get_p(x_error);
|
int16_t x_target_speed = g.pi_loiter_lon.get_p(x_error);
|
||||||
x_target_speed = constrain(x_error, -150, 150);
|
x_target_speed = constrain(x_error, -250, 250);
|
||||||
// limit windup
|
// limit windup
|
||||||
x_error = constrain(x_error, -NAV_ERR_MAX, NAV_ERR_MAX);
|
x_error = constrain(x_error, -NAV_ERR_MAX, NAV_ERR_MAX);
|
||||||
int16_t x_iterm = g.pi_loiter_lon.get_i(x_error, dTnav);
|
int16_t x_iterm = g.pi_loiter_lon.get_i(x_error, dTnav);
|
||||||
|
@ -111,7 +111,7 @@ static void calc_loiter(int x_error, int y_error)
|
||||||
|
|
||||||
// North/South
|
// North/South
|
||||||
int16_t y_target_speed = g.pi_loiter_lat.get_p(y_error);
|
int16_t y_target_speed = g.pi_loiter_lat.get_p(y_error);
|
||||||
y_target_speed = constrain(y_error, -150, 150);
|
y_target_speed = constrain(y_error, -250, 250);
|
||||||
// limit windup
|
// limit windup
|
||||||
y_error = constrain(y_error, -NAV_ERR_MAX, NAV_ERR_MAX);
|
y_error = constrain(y_error, -NAV_ERR_MAX, NAV_ERR_MAX);
|
||||||
int16_t y_iterm = g.pi_loiter_lat.get_i(y_error, dTnav);
|
int16_t y_iterm = g.pi_loiter_lat.get_i(y_error, dTnav);
|
||||||
|
|
Loading…
Reference in New Issue