mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-11 02:18:29 -04:00
ACM: Arducopter.pde - Added a constraint to the NO_NAV mode to be similar to the Loiter and rate nav modes.
This commit is contained in:
parent
a0717f082e
commit
c5344a2a85
@ -2210,6 +2210,9 @@ static void update_nav_wp()
|
||||
nav_lon = g.pid_loiter_rate_lon.get_integrator();
|
||||
nav_lat = g.pid_loiter_rate_lon.get_integrator();
|
||||
|
||||
nav_lon = constrain(nav_lon, -2000, 2000); // 20°
|
||||
nav_lat = constrain(nav_lat, -2000, 2000); // 20°
|
||||
|
||||
// rotate pitch and roll to the copter frame of reference
|
||||
calc_loiter_pitch_roll();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user