Max_pilot_speed not functioning

I am flying indoors and I want to limit my drone velocity in the altitude loop (I know I need to limit accel as well). I have reduced the MAX_PILOT_SPEED_UP & DN to 10cm/s but the commands I get are still higher than that.
Do I need to enable anything else? Do I understand this feature the wrong way? Is it not supposed to limit the maximum command input to the climb rate loop?

image

AFAIK that only works in LOITER flight mode. I doubt you are using LOITER flight mode indoors.

Yap, I am using alt hold…
That’s weird… in previous versions that worked for me :frowning:

Ok, I have verified it with the code.
In the 3.X version the following line of code was there:

In AC_PosControl.cpp

    // check speed limits
    // To-Do: check these speed limits here or in the pos->rate controller
    _limit.vel_up = false;
    _limit.vel_down = false;
    if (_vel_target.z < _speed_down_cms) {
        _vel_target.z = _speed_down_cms;
        _limit.vel_down = true;
    }
    if (_vel_target.z > _speed_up_cms) {
        _vel_target.z = _speed_up_cms;
        _limit.vel_up = true;
    }

    // add feed forward component
    if (_flags.use_desvel_ff_z) {
        _vel_target.z += _vel_desired.z;
    }

This section was completely changed in 4.1.

I’ll create a PR and hope to merge this for future versions