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 int32_t EST_getFullScaleFreq(EST_Handle handle);
Gets the full scale frequency value used in the estimator in Hertz (Hz).
Full-scale frequency can be used as a scale factor to convert values from per units to Hertz. The following example shows how to use this function to convert frequency from per units to Hz using floating point math:
float_t Mechanical_Frequency_pu = _IQtoF(EST_getFm_pu(handle));
float_t pu_to_hz_sf = EST_getFullScaleFreq(handle);
float_t Mechanical_Frequency_hz = Mechanical_Frequency_pu * pu_to_hz_sf
For faster execution, this function call can be avoided by using a definition of the full scale frequency that resides in user.h. The following example shows the same functionality but using fixed point math for faster execution:
#define USER_IQ_FULL_SCALE_FREQ_Hz (500.0)
_iq Mechanical_Frequency_pu = EST_getFm_pu(handle);
_iq pu_to_khz_sf = _IQ(USER_IQ_FULL_SCALE_FREQ_Hz/1000.0);
_iq Mechanical_Frequency_khz = _IQmpy(Mechanical_Frequency_pu, pu_to_khz_sf);
The estimator (EST) handle
The full scale frequency value, Hz