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.

Explanation of CTRL_runTraj()

Hi,

Can you explain what trajectory is being updated in the call to CTRL_runTraj() from function CTR_setup();

Maybe related to this, in CTRL_runOnLine_User() when the estimator is run (EST_run() ) the last argument in the call is the intermediate value of a speed trajectory.   But lab 10b uses SpinTAC for speed control.

Does the estimator need the speed trajectory intermediate value and how is it used?

In my case this is an ACIM motor and using SpinTAC move and velocity control.

Thanks

  • TRAJ are used to calculate the intermediate values between the starting point and the ending point that feeds the Speed Reference to the Speed Controller. TRAJ is also used to do the same for the Id Reference. Id Reference is changed during motor ID, field weakening, and with ACI Motors only.

    For the EST_run, a speed reference must be passed to the estimator (even if a speed loop is not being used in CTRL) so that the estimator knows if the reference is clockwise or counter clockwise (the polarity of the speed ref needs to match the polarity of the IqRef_A).

    I'll have Adam comment on how the traj is updated by SpinTAC
  • The speed TRAJ block is not updated by SpinTAC Move. The expectation is the since FAST only needs to know the sign of the speed reference, this code could remain unchanged since the speed TRAJ block is still running and has the sign of the speed correct even if it isn't the exact right value.

    If you wanted to remove the speed TRAJ block you could replace that call with STVELMOVE_getVelocityReference(st_obj.velMoveHandle) and it should still work.
  • Sounds good. Thanks.