We are using a TMS320F28062 on our own PCB.
On motor startup we are setting the following flags:
CTRL_setFlag_enableUserMotorParams( ctrlHandle, true );
EST_setFlag_enableForceAngle( ctrlObj->estHandle, true );
EST_setFlag_enableRsRecalc( ctrlObj->estHandle, true );
CTRL_setFlag_enableCtrl( ctrlHandle, true );
In the ISR we detect if the motor is running and we disable forced angle
if (gMotorVars.Speed_krpm != _IQ(0.0))
{
EST_setFlag_enableForceAngle( ctrlObj->estHandle, false );
}
Most of the time everything works fine, but sometimes the motor controller drives the motor into the wrong direction.
In this case the wrong behaviour is 100% reproducable.
If we command positive speed the motor turns very smooth with the correct speed in the correct direction. But if we command negative speed, the motor turns forward too but with a ribble on the motorspeed.
This will occur at every commanded (backward) speed. It is not depending if the speed is below or above USER_ZEROSPEEDLIMIT.
Any suggestions what's wrong ?