This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

problem with Direction change

Other Parts Discussed in Thread: MOTORWARE

I am driving a big propellor with a big motor using TI instapsin on custom PCBs. 

It does ok while starting up from zero speed in indoor as well as outdoor windy conditions. the startup is pretty jerky, it starts spinning in the opposite direction on startup but after about half a revolution, it starts rotating in the right direction. This initial half rev in opposite direction during force angle is little concerning to me. 

I haven't touched void updateIqRef(CTRL_Handle handle) at all. it what came with motorware

void updateIqRef(CTRL_Handle handle)
{
_iq iq_ref_pu = _IQmpy(gMotorVars.IqRef_A,_IQ(1.0/USER_IQ_FULL_SCALE_CURRENT_A));

// set the speed reference so that the forced angle rotates in the correct direction for startup
if(_IQabs(gMotorVars.Speed_krpm) < _IQ(0.01))
{
if(iq_ref_pu < _IQ(0.0))
{
CTRL_setSpd_ref_krpm(handle,_IQ(-0.01));
}
else if(iq_ref_pu > _IQ(0.0))
{
CTRL_setSpd_ref_krpm(handle,_IQ(0.01));
}
}

// Set the Iq reference that use to come out of the PI speed control
CTRL_setIq_ref_pu(handle, iq_ref_pu);

return;
} // end of updateIqRef() function

But the biggest problem is that when i am trying to change directions ie reduce Iq_ref and then increase iq_ref in the opposite direction, most times in windy conditions , it gets stuck in the force angle mode and never recovers so even when iq_ref is pretty high it keeps spinning at a very small rpm and never speeds up. some times it goes totally unresponsive. 

I was curious about trying to use the speed PID ie lab 5b  while in the range of 10 rpm to - 10 rpm for zero transition and then use iq_ref directly for higher speeds. what the differences between lab5a and lab 5b and is it safe to transition on the fly between these two modes?

We have to do this in sensorless even when we have an encoder because of various merits and robustness of sensorless compared to sensored. 

  • 1. on the issue of the initial start-up, I recommend doing an RsRecal before starting-up. If you set USER_MOTOR_CURRENT large enough the RsRecal will move the propeller into proper alignment with the D axis (rotor flux) so that when you start-up it will immediately go in the correct direction. If you don't want to use RsRecal you could write your own start-up logic that does the same, applying some + IdRef before starting up.

    2. you need to disable ForceAngle after starting up. To transition between CW/CCW you must insure that ForceAngle is disabled or else it will take over and supply an incorrect angle to the FOC system.
  • Thanks Chris.

    For 2) to disable force anlge, is it something already done in instaspin labs? Or I have to do it. What's the best way to do so?

  • So force angle is only needed for startup from zero speed but not needed for direction change even if it does pass through zero speed to change direction?
  • 1. ForceAngle is never required. It can be helpful to give a more consistent start-up from zero speed or if you want the motor to try to start back up during a very heavy load / stall event (like a power tool).

    2. ForceAngle should ALWAYS be disabled once the motor is running. You want to use FAST as the angle estimate anytime you aren't at zero speed.

    3. If your application needs to traverse through zero speed, ForceAngle should ALWAYS be disabled.

    4. If your application needs to pause at zero speed, the use of ForceAngle is application dependent. It is typically ok to continue to use FAST (disable ForceAngle) if the pause is short (<few seconds). After that you may have to consider the motor at zero speed again where you would divert back to rule #1 above.

    You enable/disable through
    // enable/disable the forced angle
    EST_setFlag_enableForceAngle(obj->estHandle,gMotorVars.Flag_enableForceAngle);