cancel
Showing results for 
Search instead for 
Did you mean: 

Speed monitoring and Single stepping a motor

RoyStevens
Associate III

I am running a 28 pole 20A nominal motor using x-Nucleo IHM08M1 and a nucleo -G431RB. I have been doing a number of tests verifying locked rotor current/torque and checking the effect of different settings of proportional gain. 
I am using Stm32CubeMonitor to monitor all the variables.

I am using 6 step control. and Hall devices for sensing

My understanding seems to be progressing. answers to the following two questions would assist me greatly.

1/        When I use the following code to monitor the speed 

 

MC_ProgramSpeedRampMotor1(1,0);

MC_StartMotor1();

for (int i = 1; i <= 200; i++)

{

Faults =MC_GetOccurredFaultsMotor1();

speed = MC_GetAverageMecSpeedMotor1_F();

HAL_Delay(50);

}

MC_StopMotor1();

I get integer values for speed and in multiples of 6. eg the speed value jumps from 0 to 6 to 12 etc whereas I am expecting a float as an answer. 

The final speed is 36 rpm whereas I expect it to be 6 rpm.

What am I doing wrong?

 

2/      At 28 poles x 6 steps gives me 168 positions per rotation and with a 300 mm Outside diameter rotor I expect to be able to do position control giving me approximately a 3mm resolution.

How do I single step this motor or move it a set number of steps.

 

Thanks

Roy

 

1 ACCEPTED SOLUTION

Accepted Solutions

Clearly I  am not getting any response to this  question. So I will close it off. With regard to the speed being integer values in multiples of 6 I think this is related to the speed unit of 0.1Hz  which is 6rpm. So I will ask the question again in a new post and hopefully will get a response.

View solution in original post

3 REPLIES 3
RoyStevens
Associate III

Could some kind soul point me in the right direction on this - thanks

RoyStevens
Associate III

Can AnyBody help?

Clearly I  am not getting any response to this  question. So I will close it off. With regard to the speed being integer values in multiples of 6 I think this is related to the speed unit of 0.1Hz  which is 6rpm. So I will ask the question again in a new post and hopefully will get a response.