PMSM vs ACIM reference solutions.

cancel
Showing results for 
Search instead for 
Did you mean: 

PMSM vs ACIM reference solutions.

Jump to solution
289 Views
peterkostadinov
Contributor III

pastedImage_1.png

In the picture above are PMSM and ACIM control loops. It is obvious that they are pretty similar. After browsing in the reference solutions "MCRSP_ACIM_V1.2.0" and "MCRSP_PMSM_V1.2.0" I saw that on application level and in state_machine level also they are absolutely equal.

My questions are:

1. Why one of the project uses "float", but the other "frac" variables? Just to demonstrate that it is possible and to show how to implement this?

2. Why these so similar drivers are split?

3. Is it possible to unify them and just with one global flag to control in runtime which specific code snippet for currently used type of motor to be execute and in the rest of the time to  execute common code?

In our projects we have to control both type of motors and now have to make the decision which approach to use - separate projects or unified project. I just want to protect myself from the wrong decision, which will take me a long time before I find out in the hard way that I have taken the wrong path.

Regards,

Peter

0 Kudos
1 Solution
143 Views
Sabina_Bruce
NXP Employee
NXP Employee

Dear Peter,

Here are the answers to your questions above:

  1. There is a difference between float and frac variables. The FRAC variable  has been created and included in the mlib.h, this is  part of the Math Library that was written in assembly language with C callable interface. This has been used in different codes for portability reasons, if you see the mlib_types.h you will find the macros that convert between float variables and frac variables. You can read about this with detail in the following document.
  2. Sometimes when there are similarities between applications, there are drivers that can be reutilized. In this case as you mention these two different motor control applications have a lot in common, however there are differences in how they work.
  3. If you would like to work with one global flag and switch between the type of motor that is being used, I don't see that being a problem. I'd recommend to work with them separately first and make sure each work as you expect before combining the two types. Currently there are not ready made examples that manage both in the same project.

 

For more information in regards to the differences and details of each type please refer to these powerpoint presentations.

Introduction to ACIM and PMSM Motor Control P1

Introduction to ACIM and PMSM Motor Control P2

 

Please let me know if you have any additional questions.

Have a great day!

 

Sabina

View solution in original post

0 Kudos
2 Replies
144 Views
Sabina_Bruce
NXP Employee
NXP Employee

Dear Peter,

Here are the answers to your questions above:

  1. There is a difference between float and frac variables. The FRAC variable  has been created and included in the mlib.h, this is  part of the Math Library that was written in assembly language with C callable interface. This has been used in different codes for portability reasons, if you see the mlib_types.h you will find the macros that convert between float variables and frac variables. You can read about this with detail in the following document.
  2. Sometimes when there are similarities between applications, there are drivers that can be reutilized. In this case as you mention these two different motor control applications have a lot in common, however there are differences in how they work.
  3. If you would like to work with one global flag and switch between the type of motor that is being used, I don't see that being a problem. I'd recommend to work with them separately first and make sure each work as you expect before combining the two types. Currently there are not ready made examples that manage both in the same project.

 

For more information in regards to the differences and details of each type please refer to these powerpoint presentations.

Introduction to ACIM and PMSM Motor Control P1

Introduction to ACIM and PMSM Motor Control P2

 

Please let me know if you have any additional questions.

Have a great day!

 

Sabina

View solution in original post

0 Kudos
143 Views
peterkostadinov
Contributor III

Hi Sabina,

Thank you very much for your answer.

Best Regards,

Peter

0 Kudos