SPRUHJ1I January 2013 – October 2021 TMS320F2802-Q1 , TMS320F28026-Q1 , TMS320F28026F , TMS320F28027-Q1 , TMS320F28027F , TMS320F28027F-Q1 , TMS320F28052-Q1 , TMS320F28052F , TMS320F28052F-Q1 , TMS320F28052M , TMS320F28052M-Q1 , TMS320F28054-Q1 , TMS320F28054F , TMS320F28054F-Q1 , TMS320F28054M , TMS320F28054M-Q1 , TMS320F2806-Q1 , TMS320F28062-Q1 , TMS320F28062F , TMS320F28062F-Q1 , TMS320F28068F , TMS320F28068M , TMS320F28069-Q1 , TMS320F28069F , TMS320F28069F-Q1 , TMS320F28069M , TMS320F28069M-Q1
extern _iq EST_getFlux_pu(EST_Handle handle);
Gets the flux value in per unit (pu), IQ24
The estimator continuously calculates the flux linkage between the rotor and stator, which is the portion of the flux that produces torque. This function returns the flux linkage, ignoring the number of turns, between the rotor and stator coils, in per units. This functions returns a precise value only after the motor has been identified, which can be checked by the following code example:
if(EST_isMotorIdentified(handle))
{
// once the motor has been identified, get the flux
_iq Flux_pu = EST_getFlux_pu(handle);
}
For some applications it is important to get this value in per units, since it is much faster to process especially when the architecture of the microcontroller does not have a floating point processing unit. In order to translate this per units value into a scaled value in _iq, it is important to consider a scale factor to convert this flux in per units to the required units. The following example shows how to scale a per units value to Wb and V/Hz in IQ for faster processing:
float_t FullScaleFlux = (USER_IQ_FULL_SCALE_VOLTAGE_V/(float_t)USER_EST_FREQ_Hz);
float_t maxFlux = (USER_MOTOR_RATED_FLUX*((USER_MOTOR_TYPE==MOTOR_Type_Induction)?0.05:0.7));
float_t lShift = -ceil(log(FullScaleFlux/maxFlux)/log(2.0));
_iq gFlux_pu_to_Wb_sf = _IQ(FullScaleFlux/(2.0*MATH_PI)*pow(2.0,lShift));
_iq gFlux_pu_to_VpHz_sf = _IQ(FullScaleFlux*pow(2.0,lShift));
// The value of gFlux_pu_to_Wb_sf and gFlux_pu_to_VpHz_sf can be calculated once at the beginning of the
// code and stored as global variables
_iq Flux_Wb;
_iq Flux_VpHz;
_iq Flux_pu = EST_getFlux_pu(handle);
Flux_Wb = _IQmpy(Flux_pu, gFlux_pu_to_Wb_sf);
Flux_VpHz = _IQmpy(Flux_pu, gFlux_pu_to_VpHz_sf);
The estimator (EST) handle
The flux value, pu