upped max target speed to center of loiter

This commit is contained in:
Jason Short 2012-02-10 22:46:27 -08:00
parent 1851dd541b
commit 8cc480f7e6
1 changed files with 2 additions and 2 deletions

View File

@ -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);