Skip to main content
JamesWang
Associate
January 17, 2019
Solved

Motor control with MCSDK

  • January 17, 2019
  • 8 replies
  • 2100 views

Hi everyone:

We tried the MCSDK and deployed it in stm32f407. But we got a problem, for example:

  1. We use the motor control GUI trigger the motor to 20k rpm.
  2. We press the stop button.
  3. The motor go into free run status.
  4. When the motor speed decrease and not reach to zero , may be 10k rpm.
  5. Than we start motor again, wish to reach 20k rpm.
  6. But the motor speed is higher than 20k rpm. And the speed indicator of GUI is not correct .
This topic has been closed for replies.
Best answer by cedric H

Dear James,

Sorry for the delay.

Your issue is reproduced, and will be fixed in the next release.

You can already test it by commenting the line 205 of the file hall_speed_pos_fdbk.c :

 // pHandle->ElSpeedSum = 0;

Let me know if it does the job.

Regards

Cedric

8 replies

Claire O.
ST Employee
January 18, 2019

Hello James,

Are you using the STM3240G-EVAL from ST or some custom board?

Can you please also indicates which SDK version you are using?

It should help us to reproduce your problem.

Thanks,

Claire

JamesWang
JamesWangAuthor
Associate
January 21, 2019

Hello Claire,

We are using the STM32f4Discovery and IHM08m1 3Sh from ST. And the problem also appear in the combination of Nucleo-F302R8 and IHM08m1 3Sh. We've used SDK 5.12, 5.20 and 5.32, they have the same results.

​

Thanks,

James

cedric H
ST Technical Moderator
January 21, 2019

Dear James,

Could you confirm that your issue appears only when you start your motor from a non zero speed ?

Could you describe your configuration : are you sensorless ? Do you use an encoder or a hall sensors ?

when your issue appears, what is the speed indicated by the WB ? Are you able from this stage to stop the motor and to re-start after a 0 speed into a correct state ( correct speed )

Did you enable the On the fly parameter in the Workbench ?

Regards

Cedric

JamesWang
JamesWangAuthor
Associate
January 22, 2019
Hi Credric, Here is our answer: 1. Our issue only appears when the motor start from a non zero speed. 2. Our motor is sensed by hall sensors. 3. We cant get the “WB�? means, if you are talking about the MCSDK GUI, the speed indicates will lower than the target speed, but the actual motor speed is more than target and indicator speed. 4. We can stop the motor and restart it from speed 0, and it will go into correct stage. 5. When we use the hall sensor there has no On-the -fly parameter can be set. Thanks , James Sent from Mail<> for Windows 10
cedric H
ST Technical Moderator
January 22, 2019

Dear James,

Thank you for the information.

We will try to reproduce your issue and keep you aware of our findings.

Regards

Cedric

JamesWang
JamesWangAuthor
Associate
February 11, 2019

Hi Credric,

Is our issue can be reproduced?

Thanks,

James

cedric H
cedric HBest answer
ST Technical Moderator
March 6, 2019

Dear James,

Sorry for the delay.

Your issue is reproduced, and will be fixed in the next release.

You can already test it by commenting the line 205 of the file hall_speed_pos_fdbk.c :

 // pHandle->ElSpeedSum = 0;

Let me know if it does the job.

Regards

Cedric