PMSM_FOC SL application: Output current limiting setting

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

cross mob
BlueSky
Level 1
Level 1
10 sign-ins 5 replies posted 5 sign-ins

Processor card: KIT_XMC4400_DC_V1 

Drive board:   EVAL-M5-IMZ120R-SIC  board.   

Question:  How to set absolute current limit in software for I-V, I-U and I-W?   

Problem:  we can drive the motor for 2s.  However, the current of I-V/U/W keep increasing.  then trigger the CTRAP ..  

Thanks 

0 Likes
1 Solution
Krupashankar
Moderator
Moderator
Moderator
500 replies posted 50 likes received 25 likes received

Hi @BlueSky ,

The current loop code in PMSM_FOC_EXAMPLE_XMC44 is linked as a library so we cannot access the variables within it.

Can you please try changing Kp( reduce) and Ki( reduce) values so that di/dt will be limited and a gradual rise in current will happen which can help in the reduction of the false trigger.

Could you please try changing the current amplifier gain and shunt resistance to increase the current limit if the board supports a higher current.

 

Thanks,

Krupashankar

View solution in original post

0 Likes
5 Replies
Krupashankar
Moderator
Moderator
Moderator
500 replies posted 50 likes received 25 likes received

Hi @BlueSky .,

We will not be able to set IU, IV, and IW maximum current limit as the reference is always set using Iq and Id current.

Please try changing the macro for setting the maximum current.

#define PMSM_FOC_CURRENT_MIN_VALUE (-32768) /** Minimum value of the current in Q15 format */
#define PMSM_FOC_CURRENT_MAX_VALUE (32767U) /** Maximum value of the current in Q15 format */

 

Thanks,

Krupashankar

0 Likes
BlueSky
Level 1
Level 1
10 sign-ins 5 replies posted 5 sign-ins

Thanks @Krupashankar ,

Changed as per your suggestion.  However, after compilation, the binary was not changed.. surprised.  

Currently, the motor can move for 5 seconds. However, the IU/V/W keep increasing after power on, until the TRAP is triggered, because IU/V/W are too high. 

Any suggestion? 

Thanks. 

0 Likes
Krupashankar
Moderator
Moderator
Moderator
500 replies posted 50 likes received 25 likes received

Hi @BlueSky,

Yes, we have also tried it on our end yes we have seen that there is no change in binary as that part of code is not being called. We will contact our internal team to resolve this issue.

As PMSM_FOC_EXAMPLE_XMC44 is APP-based and it contains PMSM_FOC_LIB as a library linked as an object file, We recommend you to use https://www.infineon.com/cms/en/product/microcontroller/32-bit-industrial-microcontroller-based-on-a...  this code can be used to customize a lot of features and gives more flexibility.

 

Thanks,

Krupashankar

0 Likes
BlueSky
Level 1
Level 1
10 sign-ins 5 replies posted 5 sign-ins

@Krupashankar  thanks.

Yes, Actually, I am using PMSM_FOC_EXAMPLE_XMC44  project as baseline to modified  the motor parameter..   but still can't work well.  

Regards

 

0 Likes
Krupashankar
Moderator
Moderator
Moderator
500 replies posted 50 likes received 25 likes received

Hi @BlueSky ,

The current loop code in PMSM_FOC_EXAMPLE_XMC44 is linked as a library so we cannot access the variables within it.

Can you please try changing Kp( reduce) and Ki( reduce) values so that di/dt will be limited and a gradual rise in current will happen which can help in the reduction of the false trigger.

Could you please try changing the current amplifier gain and shunt resistance to increase the current limit if the board supports a higher current.

 

Thanks,

Krupashankar

0 Likes