FOC Sensorless questions and thoughts [Case:3760197]

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

cross mob
Not applicable
I have spent the last days evaluating and reviewing the XMC FOC sensorless libraries for an ebike solution proof-of-concept.
Here I expose certain thoughts and questions that came up...

- I have noticed that the last version of the library (4.2.8) is provided at the DAVE repos as a pre-compiled library without chance to access the source code.
However I saw that previous versions are provided open-sourced with only some modules pre-compiled (like the PLL position estimator).
This implies certain restrictions when developing on-top solutions. Is the library offered somewhere open-source or at least partially open-sourced (like it used to be)? Would it be possible to get such code under request?

- Having a position feedback over Hall sensors might be required/interesting for certain applications. It is the case for my application. However, with this pre-compiled FOC library I am not even able to try to include such modification on my own.
With previous versions it was possible for developers to include and evaluate such functionalities. Is there really no way now to give a try to a Hall sensored self-implementation with the latest version?

- Previous versions have a comprehensive documentation. For the latest version all the documentation is a brief Help in DAVE which is somehow poor and certainly misleading in some cases.
No plan for an updated further documentation of the library?

- There are certain unstable and undesired behaviors of the library that would require in-depth analysis and debugging before going into an end-product, therefore my need of having the library code. See for example the video attached.

In the video I am running the motor under torque control at a constant torque and maximum controller output of 50%. It can be observed how the motor reacts to an opposite load (my fingers) differently in 2 consecutive attempts.
The first time, the motor slows down until stopped and after releasing the load, the motor resumes spinning normally (this is how it should be). The second time, the motor slows down until stopped and remains stall (this should not be).
Am I very wrong about this?




I hope someone find this thoughts interesting and can help me out with my questions.
Thanks for reading and all the best.
0 Likes
2 Replies
User13875
Level 1
Level 1
Hey atena,

Looks like this forum is not supported enough, I have had similar questions about FOC, and more specifically sensored FOC, but with no answer. The behavior you see is a result of sensorless Hall, which does not perform well in near-stall speeds. We use encoders for sensored FOC and it runs super smooth in our products.

Check this thread to see about enabling Hall feedback (worse than encoder, but still something):
https://www.infineonforums.com/threads/5320-How-to-change-Dave4-PMSM-FOC-app-from-sensorless-to-Hall...

We were quite excited about the XMC series processors for our products as they seemed ideal. However, after reviewing the current status of code, documentation, closed-source/non-modular FOC, etc, we decided not to make the jump to XMC. If you have any updates please share them.

Best,
Alex
0 Likes
User13760
Level 1
Level 1
Hi, the open sourced (except for the PLL estimator) version is on Infineon's website (https://www.infineon.com/cms/en/product/evaluation-boards/kit_xmc1x_ak_motor_001/#!tools), look under tools & software.

The behavior you see is normal for sensorless pmsm since there is limited knowledge as to where the rotor flux linkage is with respect to the stator. To get a good estimate of the flux linkage, the rotor needs to be 'sufficiently' excited. When you hold down the rotor, the excitation is limited, resulting in bad estimates. As such, FOC is not able to provide a the right phase currents to 'move' the rotor. The solution: sensored FOC, use halls or encoder with POSIF to replace the PLL estimate and you are good
0 Likes