AMMCLIB for S32K14xx

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

AMMCLIB for S32K14xx

640 Views
zhouwenxiang
Contributor II

Dear NXPS:

Recently, I was reading the S32K14XMCLUG and using the AMMCLIB to control PMSM. I used the function AMCLIB_BemfObsrvDQ. I am a little confused about this function. According to the structure diagram in the document, it is composed of two PIrAW controllers. Can I understand that ed (n) and eq (n) in the formula in the attachment are the output of this function? There is also the AMCLIB_BemfObsrvDQSetState. Because it is not recorded in the document, I don't know how to use it. Finally, if I want to view or modify the source code of the AMMCLIB, what do I need to do?

Thanks!

Tags (1)
0 Kudos
Reply
1 Reply

562 Views
petrz_
NXP Employee
NXP Employee

Hello,

the equation AMCLIB_BemfObsrvDQ_Eq2 corresponds to the implemented observer structure which intentionally presumes that the phase error between the estimated quasi-synchronous frame gamma/delta and the synchronous rotor flux frame d/q is zero. If we assume that the feedback loop has converged to a steady state, the function will return zero angle theta_err, the term ed(n) in the AMCLIB_BemfObsrvDQ_Eq2 will be zero, and the term eq(n) will be proportional to the magnitude of the induced back-electromotive force. If, however, the two reference frames are not aligned (e.g. during a transient), the PI controllers will attempt to compensate the alignment error by increasing/decreasing ed(n)/eq(n) and the function will return non-zero value theta_err. The return value theta_err of the BEMF observer function is the only output that is needed for the feedback loop and can be used as an input for the angle tracking observer (AMCLIB_TrackObsrv). Outputs ed(n) and eq(n) (which are provided in the structure pEObsrv) can be used for debugging purposes or to detect fault states.

Function AMCLIB_BemfObsrvDQSetState is explained in the AMMCLib 1.1.31 User's Guide in the chapter 2.2.7.

If you are interested in obtaining the source code of AMMCLib, please contact the NXP sales by clicking the "Buy from NXP" button in the AMMCLib Offerings Table.

0 Kudos
Reply