mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-04-28 06:34:06 +08:00
Manual Traj - Avoid velocity jumps due to a modification of the constraints
This commit is contained in:
parent
57eef6b170
commit
f1262cbe84
@ -95,11 +95,11 @@ void FlightTaskManualPositionSmoothVel::_updateSetpoints()
|
||||
|
||||
if (_velocity_setpoint(2) < 0.f) { // up
|
||||
_smoothing[2].setMaxAccel(MPC_ACC_UP_MAX.get());
|
||||
_smoothing[2].setMaxVel(_constraints.speed_up);
|
||||
_smoothing[2].setMaxVel(MPC_Z_VEL_MAX_UP.get());
|
||||
|
||||
} else { // down
|
||||
_smoothing[2].setMaxAccel(MPC_ACC_DOWN_MAX.get());
|
||||
_smoothing[2].setMaxVel(_constraints.speed_down);
|
||||
_smoothing[2].setMaxVel(MPC_Z_VEL_MAX_DN.get());
|
||||
}
|
||||
|
||||
Vector2f vel_xy_sp = Vector2f(&_velocity_setpoint(0));
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user