Small doubts regarding Angle and Speed Scaling in PMSM_FOC app.

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
User20200
Level 1
Level 1
Hi,
We are trying to do Sensored FOC using the PMSM_FOC dave app.
After taking a look at a previous forum post: https://www.infineonforums.com/threads/5432-Can-t-find-how-to-do-sensored-FOC

From the forum post we understand that we have to overwrite the FOCInput->RotorAngleQ31 beforeFOC_Controller_LIB (HandlePtr);.

We are able to measure the correct speed and rotor angle from the HALL_POSIF module. My question is regarding the scaling.

1 .Does the Q31 Scaling mean that 0-360 degrees is scaled as 0 - 2^31 ?
And no negative values of angle must be provided(for forward direction ramp, 0 to 2^31 and for reverse, ramp 2^31 to 0).


2. And is the following scaling correct to set the Speed where we measured the RPM directly from HALL.
FOCInput->RotorSpeed_In = (MEASURED_RPM_FROM HALL * (HandlePtr->foc_config_ptr->speed_scale)) >> PMSM_FOC_Q15;
0 Likes
1 Solution
Vasanth
Moderator
Moderator
Moderator
250 sign-ins 500 solutions authored First question asked
Hi ,

Please find the scale information from the app help section.

4929.attach

Best Regards,
Vasanth

View solution in original post

0 Likes
1 Reply
Vasanth
Moderator
Moderator
Moderator
250 sign-ins 500 solutions authored First question asked
Hi ,

Please find the scale information from the app help section.

4929.attach

Best Regards,
Vasanth
0 Likes