This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

What does STPOSCTL_setVelocityMaximum() actually do?



Hi all

Does anyone know what STPOSCTL_setVelocityMaximum() actually does?

For me there are two options:

  • It actually limits the velocity inside Position Control, between 0..1 of full motor speed. Sounds plausible, right?
  • It sets a limit for the velocity reference feedforward that you supply with STPOSCTL_setVelocityReference().

The Doxygen says:

//! \brief      Sets the Maximum Position (cfg.VelMax) for SpinTAC Position Controller
//! \param[in]  handle The handle for the SpinTAC Position Controller Object
//! \param[in]  velMax Velocity reference signal upper limit{ unit: [pu/s], Value range: (0, 1] }

"Sets the Maximum Position" seems a bit wrong. "velMax Velocity reference signal upper limit" makes me think that my second meaning applies rather than being an actual velocity limiter.

Does anyone know how to limit the rotation velocity in position control?

Thanks

Rich

  • Rich,

    Looks like we have a typo in the Doxygen for that function.  I'll correct it in the next release.

    RichB said:
    • It actually limits the velocity inside Position Control, between 0..1 of full motor speed. Sounds plausible, right?
    • It sets a limit for the velocity reference feedforward that you supply with STPOSCTL_setVelocityReference().

    The value that is set with this function does both of those two tasks.  It is used to limit the output of the position control loop internal to PosCtl and it limits the velocity reference feedforward.  This is also used as the velocity minimum.  So the controller assumes that it can run as fast as positive or negative speed set by this function.