How to change Dave4 PMSM-FOC app from sensorless to Hall ?

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

cross mob
Not applicable
Hi,
I had made a PMSM FOC controller PCBA successfully using DAVE4 PMSM_FOC V4.2.4. This app is using sensorless solution, the performance look good. However, our customer want FOC-hall solution rather than sensorless.

Application requirement :
The motor must able to provide continue stall torque during the stall period, the stall period is around 3-5s before it trigger the stall protection. The stall torque must be a continue torque instead of a pulsing.

I had modified my program with reference to the Infineon's application notes AP32289 (Position interface (POSIF)),P15-P.20.

I had assigned a digital I/O name it "FG" to indicated the hall frequency of motor rotation. At the end of routine "void POSIF0_0_IRQHandler(void)" , I toggle the "FG" . When I turn the motor manually, I saw the pulse appear at "FG" indicate the "void POSIF0_0_IRQHandler(void)" are working correctly, I can obtain the Hall position and motor speed within this in this IRQ.

My question is : how and where I can replace the sensorless estimator's speed and position parameter inside the app with the above position and speed parameters ?
can anyone help ?


Regards,
rocky
0 Likes
2 Replies
Eric1
Employee
Employee
Dear rocky,

you can manipulate the values PLL_Estimator.RotorSpeed_In and PLL_Estimator.RotorAngleQ31.
This values are update in the FOC so you need to change them after the FOC call.

Please consider the scaling of the value. For this uC Probe is very helpful to compare the HALL values and the sensorless values before you overwrite the values.

You can find more information in the Application Note:
AP32370 PMSM FOC motor control software using XMC™
(www.infineon.com/XMC1000 --> documents)
e.g. the Figure 4 shows the signal flow.

Using HALL and FOC are always critical in terms of interrupt priority.
Please consider this in your project.

Best Regards
Eric
0 Likes
User13875
Level 1
Level 1
Hi Eric,

We are looking to migrate to XMC4800 (and also to XMC1400 for a lite version of our products), but we need Sensored FOC (encoder input, either SPI or incremental).

Does what you wrote above also apply to change from sensorless to sensored (encoder)? I am referring to this part:

manipulate the values PLL_Estimator.RotorSpeed_In and PLL_Estimator.RotorAngleQ31

Other than scaling the values do you forsee any other issue?

Also do you plan in updating the PMSM_FOC app to support multiple types of position inputs in the future (Hall, Encoder, user defined)?

Best,

Alex
0 Likes