cancel
Showing results for 
Search instead for 
Did you mean: 

Motor control with MCSDK

JamesWang
Associate II

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 .
1 ACCEPTED SOLUTION

Accepted Solutions

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

View solution in original post

8 REPLIES 8
Claire O.
ST Employee

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

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 Employee

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
Associate II
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 Employee

Dear James,

Thank you for the information.

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

Regards

Cedric

Hi Credric,

Is our issue can be reproduced?

Thanks,

James

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

Hi Credric,

This fix can work well and helpful.

Thanks,

James