MotorWare f2806x Module API Documentation

- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

32b/est.h
Go to the documentation of this file.
1 #ifndef _EST_H_
2 #define _EST_H_
3
9
10
11 // **************************************************************************
12 // the includes
13
14 // modules
15 #include "sw/modules/math/src/32b/math.h"
16 #include "sw/modules/iqmath/src/32b/IQmathLib.h"
17 #include "sw/modules/est/src/est_states.h"
18
19
24
25
26 // Include the algorithm overview defined in modules/<module>/docs/doxygen/doxygen.h
28
29 #ifdef __cplusplus
30 extern "C" {
31 #endif
32
33
34 // **************************************************************************
35 // the defines
36
37
38 // **************************************************************************
39 // the typedefs
40
43 typedef enum
44 {
45 EST_RsOnLineFilterType_Current=0,
46 EST_RsOnLineFilterType_Voltage
47 } EST_RsOnLineFilterType_e;
48
49
52 typedef struct _EST_Obj_ *EST_Handle;
53
54
55 // **************************************************************************
56 // the globals
57
58
59 // **************************************************************************
60 // the function prototypes
61
66 #ifdef __TMS320C28XX_FPU32__
67 extern int32_t EST_computeLr_H(EST_Handle handle,const _iq current);
68 #else
69 extern float_t EST_computeLr_H(EST_Handle handle,const _iq current);
70 #endif
71
72
76 extern bool EST_doCurrentCtrl(EST_Handle handle);
77
78
82 extern bool EST_doSpeedCtrl(EST_Handle handle);
83
84
90 extern void EST_genOutputLimits_Pid_Id(EST_Handle handle,
91 const _iq maxDutyCycle,
92 _iq *outMin,_iq *outMax);
93
94
101 extern void EST_genOutputLimits_Pid_Iq(EST_Handle handle,
102 const _iq maxDutyCycle,
103 const _iq out_Id,
104 _iq *outMin,_iq *outMax);
105
106
123 extern _iq EST_get_krpm_to_pu_sf(EST_Handle handle);
124
125
141 extern _iq EST_get_pu_to_krpm_sf(EST_Handle handle);
142
143
153 extern _iq EST_getAngle_pu(EST_Handle handle);
154
155
172 extern _iq EST_getDcBus_pu(EST_Handle handle);
173
174
178 extern EST_ErrorCode_e EST_getErrorCode(EST_Handle handle);
179
180
186 #ifdef __TMS320C28XX_FPU32__
187 extern int32_t EST_getFe(EST_Handle handle);
188 #else
189 extern float_t EST_getFe(EST_Handle handle);
190 #endif
191
192
205 extern _iq EST_getFe_pu(EST_Handle handle);
206
207
230 extern bool EST_getFlag_enableForceAngle(EST_Handle handle);
231
232
247 extern bool EST_getFlag_enableRsOnLine(EST_Handle handle);
248
249
263 extern bool EST_getFlag_enableRsRecalc(EST_Handle handle);
264
265
280 extern bool EST_getFlag_estComplete(EST_Handle handle);
281
282
302 extern bool EST_getFlag_updateRs(EST_Handle handle);
303
304
320 #ifdef __TMS320C28XX_FPU32__
321 extern int32_t EST_getFlux_VpHz(EST_Handle handle);
322 #else
323 extern float_t EST_getFlux_VpHz(EST_Handle handle);
324 #endif
325
326
342 #ifdef __TMS320C28XX_FPU32__
343 extern int32_t EST_getFlux_Wb(EST_Handle handle);
344 #else
345 extern float_t EST_getFlux_Wb(EST_Handle handle);
346 #endif
347
348
386 extern _iq EST_getFlux_pu(EST_Handle handle);
387
388
404 #ifdef __TMS320C28XX_FPU32__
405 extern int32_t EST_getFm(EST_Handle handle);
406 #else
407 extern float_t EST_getFm(EST_Handle handle);
408 #endif
409
410
426 extern _iq EST_getFm_pu(EST_Handle handle);
427
428
451 extern _iq EST_getForceAngleDelta_pu(EST_Handle handle);
452
453
488 extern bool EST_getForceAngleStatus(EST_Handle handle);
489
490
494 extern _iq EST_getFreqB0_lp_pu(EST_Handle handle);
495
496
501 extern _iq EST_getFreqBeta_lp_pu(EST_Handle handle);
502
503
512 #ifdef __TMS320C28XX_FPU32__
513 extern int32_t EST_getFslip(EST_Handle handle);
514 #else
515 extern float_t EST_getFslip(EST_Handle handle);
516 #endif
517
518
532 extern _iq EST_getFslip_pu(EST_Handle handle);
533
534
557 #ifdef __TMS320C28XX_FPU32__
558 extern int32_t EST_getFullScaleCurrent(EST_Handle handle);
559 #else
560 extern float_t EST_getFullScaleCurrent(EST_Handle handle);
561 #endif
562
563
567 #ifdef __TMS320C28XX_FPU32__
568 extern int32_t EST_getFullScaleFlux(EST_Handle handle);
569 #else
570 extern float_t EST_getFullScaleFlux(EST_Handle handle);
571 #endif
572
573
595 #ifdef __TMS320C28XX_FPU32__
596 extern int32_t EST_getFullScaleFreq(EST_Handle handle);
597 #else
598 extern float_t EST_getFullScaleFreq(EST_Handle handle);
599 #endif
600
601
636 #ifdef __TMS320C28XX_FPU32__
637 extern int32_t EST_getFullScaleInductance(EST_Handle handle);
638 #else
639 extern float_t EST_getFullScaleInductance(EST_Handle handle);
640 #endif
641
642
674 #ifdef __TMS320C28XX_FPU32__
675 extern int32_t EST_getFullScaleResistance(EST_Handle handle);
676 #else
677 extern float_t EST_getFullScaleResistance(EST_Handle handle);
678 #endif
679
680
703 #ifdef __TMS320C28XX_FPU32__
704 extern int32_t EST_getFullScaleVoltage(EST_Handle handle);
705 #else
706 extern float_t EST_getFullScaleVoltage(EST_Handle handle);
707 #endif
708
709
713 extern void EST_getIab_pu(EST_Handle handle,MATH_vec2 *pIab);
714
715
719 #ifdef __TMS320C28XX_FPU32__
720 extern int32_t EST_getIdRated(EST_Handle handle);
721 #else
722 extern float_t EST_getIdRated(EST_Handle handle);
723 #endif
724
725
729 extern _iq EST_getIdRated_pu(EST_Handle handle);
730
731
736 extern _iq EST_getIdRated_indEst_pu(EST_Handle handle);
737
738
742 extern _iq EST_getIdRated_ratedFlux_pu(EST_Handle handle);
743
744
748 #ifdef __TMS320C28XX_FPU32__
749 extern int32_t EST_getLr_H(EST_Handle handle);
750 #else
751 extern float_t EST_getLr_H(EST_Handle handle);
752 #endif
753
754
776 extern _iq EST_getLr_pu(EST_Handle handle);
777
778
803 extern uint_least8_t EST_getLr_qFmt(EST_Handle handle);
804
805
809 #ifdef __TMS320C28XX_FPU32__
810 extern int32_t EST_getLs_d_H(EST_Handle handle);
811 #else
812 extern float_t EST_getLs_d_H(EST_Handle handle);
813 #endif
814
815
837 extern _iq EST_getLs_d_pu(EST_Handle handle);
838
839
847 extern void EST_getLs_dq_pu(EST_Handle handle,MATH_vec2 *pLs_dq_pu);
848
849
853 #ifdef __TMS320C28XX_FPU32__
854 extern int32_t EST_getLs_q_H(EST_Handle handle);
855 #else
856 extern float_t EST_getLs_q_H(EST_Handle handle);
857 #endif
858
859
881 extern _iq EST_getLs_q_pu(EST_Handle handle);
882
883
908 extern uint_least8_t EST_getLs_qFmt(EST_Handle handle);
909
910
914 extern _iq EST_getLs_max_pu(EST_Handle handle);
915
916
920 extern _iq EST_getLs_min_pu(EST_Handle handle);
921
922
926 extern _iq EST_getLs_coarse_max_pu(EST_Handle handle);
927
928
971 extern _iq EST_getMaxAccel_pu(EST_Handle handle);
972
973
1016 extern _iq EST_getMaxAccel_est_pu(EST_Handle handle);
1017
1018
1055 extern _iq EST_getMaxCurrentSlope_pu(EST_Handle handle);
1056
1057
1096 extern _iq EST_getMaxCurrentSlope_epl_pu(EST_Handle handle);
1097
1098
1102 extern _iq EST_getOneOverDcBus_pu(EST_Handle handle);
1103
1104
1108 #ifdef __TMS320C28XX_FPU32__
1109 extern int32_t EST_getRr_Ohm(EST_Handle handle);
1110 #else
1111 extern float_t EST_getRr_Ohm(EST_Handle handle);
1112 #endif
1113
1114
1118 extern _iq EST_getRr_pu(EST_Handle handle);
1119
1120
1124 extern uint_least8_t EST_getRr_qFmt(EST_Handle handle);
1125
1126
1130 #ifdef __TMS320C28XX_FPU32__
1131 extern int32_t EST_getRs_Ohm(EST_Handle handle);
1132 #else
1133 extern float_t EST_getRs_Ohm(EST_Handle handle);
1134 #endif
1135
1136
1140 extern _iq EST_getRs_pu(EST_Handle handle);
1141
1142
1146 extern uint_least8_t EST_getRs_qFmt(EST_Handle handle);
1147
1148
1158 extern void EST_getRsOnLineFilterParams(EST_Handle handle,const EST_RsOnLineFilterType_e filterType,
1159 _iq *pFilter_0_b0,_iq *pFilter_0_a1,_iq *pFilter_0_y1,
1160 _iq *pFilter_1_b0,_iq *pFilter_1_a1,_iq *pFilter_1_y1);
1161
1162
1166 #ifdef __TMS320C28XX_FPU32__
1167 extern int32_t EST_getRsOnLine_Ohm(EST_Handle handle);
1168 #else
1169 extern float_t EST_getRsOnLine_Ohm(EST_Handle handle);
1170 #endif
1171
1172
1176 extern _iq EST_getRsOnLine_pu(EST_Handle handle);
1177
1178
1182 extern uint_least8_t EST_getRsOnLine_qFmt(EST_Handle handle);
1183
1184
1188 extern _iq EST_getRsOnLineId_mag_pu(EST_Handle handle);
1189
1190
1194 extern _iq EST_getRsOnLineId_pu(EST_Handle handle);
1195
1196
1200 extern void EST_setRsOnLineId_pu(EST_Handle handle,const _iq Id_pu);
1201
1202
1206 extern int_least8_t EST_getSignOfDirection(EST_Handle handle);
1207
1208
1212 extern _iq EST_getSpeed_krpm(EST_Handle handle);
1213
1214
1218 extern EST_State_e EST_getState(EST_Handle handle);
1219
1220
1224 extern _iq EST_getTorque_lbin(EST_Handle handle);
1225
1226
1230 extern _iq EST_getTorque_Nm(EST_Handle handle);
1231
1232
1236 extern bool EST_isError(EST_Handle handle);
1237
1238
1242 extern bool EST_isIdle(EST_Handle handle);
1243
1244
1248 extern bool EST_isLockRotor(EST_Handle handle);
1249
1250
1254 extern bool EST_isMotorIdentified(EST_Handle handle);
1255
1256
1260 extern bool EST_isOnLine(EST_Handle handle);
1261
1262
1265 extern void EST_resetCounter_ctrl(EST_Handle handle);
1266
1267
1270 extern void EST_resetCounter_state(EST_Handle handle);
1271
1272
1279 extern void EST_run(EST_Handle handle,
1280 const MATH_vec2 *pIab_pu,
1281 const MATH_vec2 *pVab_pu,
1282 const _iq dcBus_pu,
1283 const _iq speed_ref_pu);
1284
1285
1300 extern void EST_setAngle_pu(EST_Handle handle,const _iq angle_pu);
1301
1302
1306 extern void EST_setDcBus_pu(EST_Handle handle,const _iq dcBus_pu);
1307
1308
1312 extern void EST_setFlag_enableFluxControl(EST_Handle handle,const bool state);
1313
1314
1330 extern void EST_setFlag_enableForceAngle(EST_Handle handle,const bool state);
1331
1332
1344 extern void EST_setFlag_enableRsOnLine(EST_Handle handle,const bool state);
1345
1346
1358 extern void EST_setFlag_enableRsRecalc(EST_Handle handle,const bool state);
1359
1360
1364 extern void EST_setFlag_estComplete(EST_Handle handle,const bool state);
1365
1366
1384 extern void EST_setFlag_updateRs(EST_Handle handle,const bool state);
1385
1386
1410 extern void EST_setForceAngleDelta_pu(EST_Handle handle,const _iq angleDelta_pu);
1411
1412
1416 extern void EST_setFreqB0_lp_pu(EST_Handle handle,const _iq b0_lp_pu);
1417
1418
1423 extern void EST_setFreqBeta_lp_pu(EST_Handle handle,const _iq beta_lp_pu);
1424
1425
1429 extern void EST_setFullScaleCurrent(EST_Handle handle,const float_t fullScaleCurrent);
1430
1431
1435 extern void EST_setFullScaleFlux(EST_Handle handle,const float_t fullScaleFlux);
1436
1437
1441 extern void EST_setFullScaleFreq(EST_Handle handle,const float_t fullScaleFreq);
1442
1443
1447 extern void EST_setFullScaleInductance(EST_Handle handle,const float_t fullScaleInductance);
1448
1449
1453 extern void EST_setFullScaleResistance(EST_Handle handle,const float_t fullScaleResistance);
1454
1455
1459 extern void EST_setFullScaleVoltage(EST_Handle handle,const float_t fullScaleVoltage);
1460
1461
1464 extern void EST_setIdle(EST_Handle handle);
1465
1466
1469 extern void EST_setIdle_all(EST_Handle handle);
1470
1471
1475 extern void EST_setId_ref_pu(EST_Handle handle,const _iq Id_ref_pu);
1476
1477
1481 extern void EST_setIdRated_pu(EST_Handle handle,const _iq IdRated_pu);
1482
1483
1487 extern void EST_setIq_ref_pu(EST_Handle handle,const _iq Iq_ref_pu);
1488
1489
1508 extern void EST_setLs_d_pu(EST_Handle handle,const _iq Ls_d_pu);
1509
1510
1514 extern _iq EST_getLs_delta_pu(EST_Handle handle);
1515
1516
1520 extern void EST_setLs_delta_pu(EST_Handle handle,const _iq Ls_delta_pu);
1521
1522
1526 extern _iq EST_getRs_delta_pu(EST_Handle handle);
1527
1528
1532 extern void EST_setRs_delta_pu(EST_Handle handle,const _iq Rs_delta_pu);
1533
1534
1557 extern void EST_setLs_dq_pu(EST_Handle handle,const MATH_vec2 *pLs_dq_pu);
1558
1559
1578 extern void EST_setLs_q_pu(EST_Handle handle,const _iq Ls_q_pu);
1579
1580
1606 extern void EST_setLs_qFmt(EST_Handle handle,const uint_least8_t Ls_qFmt);
1607
1608
1612 extern void EST_setMaxAccel_pu(EST_Handle handle,const _iq maxAccel_pu);
1613
1614
1618 extern void EST_setMaxAccel_est_pu(EST_Handle handle,const _iq maxAccel_pu);
1619
1620
1624 extern void EST_setMaxCurrentSlope_pu(EST_Handle handle,const _iq maxCurrentSlope_pu);
1625
1626
1631 extern void EST_setMaxCurrentSlope_epl_pu(EST_Handle handle,const _iq maxCurrentSlope_pu);
1632
1633
1637 extern void EST_setRr_pu(EST_Handle handle,const _iq Rr_pu);
1638
1639
1643 extern void EST_setRr_qFmt(EST_Handle handle,uint_least8_t Rr_qFmt);
1644
1645
1649 extern void EST_setRsOnLineAngleDelta_pu(EST_Handle handle,const _iq angleDelta_pu);
1650
1651
1655 extern void EST_setRsOnLine_pu(EST_Handle handle,const _iq Rs_pu);
1656
1657
1662 extern void EST_setRsOnLine_qFmt(EST_Handle handle,const uint_least8_t Rs_qFmt);
1663
1664
1674 extern void EST_setRsOnLineFilterParams(EST_Handle handle,const EST_RsOnLineFilterType_e filterType,
1675 const _iq filter_0_b0,const _iq filter_0_a1,const _iq filter_0_y1,
1676 const _iq filter_1_b0,const _iq filter_1_a1,const _iq filter_1_y1);
1677
1678
1682 extern void EST_setRsOnLineId_mag_pu(EST_Handle handle,const _iq Id_mag_pu);
1683
1684
1688 extern void EST_setRs_pu(EST_Handle handle,const _iq Rs_pu);
1689
1690
1694 extern void EST_setRs_qFmt(EST_Handle handle,uint_least8_t Rs_qFmt);
1695
1696
1700 extern void EST_updateId_ref_pu(EST_Handle handle,_iq *pId_ref_pu);
1701
1702
1707 extern bool EST_updateState(EST_Handle handle,const _iq Id_target_pu);
1708
1709
1713 extern bool EST_useZeroIq_ref(EST_Handle handle);
1714
1715
1720 #ifdef __TMS320C28XX_FPU32__
1721 extern uint_least8_t EST_computeDirection_qFmt(EST_Handle handle,const int32_t flux_max);
1722 #else
1723 extern uint_least8_t EST_computeDirection_qFmt(EST_Handle handle,const float_t flux_max);
1724 #endif
1725
1726
1730 extern uint_least8_t EST_getDir_qFmt(EST_Handle handle);
1731
1732
1736 extern void EST_setDir_qFmt(EST_Handle handle,const uint_least8_t dir_qFmt);
1737
1738
1742 extern void EST_setFe_neg_max_pu(EST_Handle handle,const _iq fe_neg_max_pu);
1743
1744
1748 extern void EST_setFe_pos_min_pu(EST_Handle handle,const _iq fe_pos_min_pu);
1749
1750
1751 #ifdef __cplusplus
1752 }
1753 #endif // extern "C"
1754
1756 #endif // end of _EST_H_ definition
1757
EST_getFlux_VpHz
float_t EST_getFlux_VpHz(EST_Handle handle)
Gets the flux value in Volts per Hertz (V/Hz).
EST_getIdRated_pu
_iq EST_getIdRated_pu(EST_Handle handle)
Gets the Id rated current value from the estimator in per unit (pu), IQ24.
EST_isError
bool EST_isError(EST_Handle handle)
Determines if there is an estimator error.
EST_getRsOnLine_Ohm
float_t EST_getRsOnLine_Ohm(EST_Handle handle)
Gets the online stator resistance value in Ohms ( ).
EST_getRs_pu
_iq EST_getRs_pu(EST_Handle handle)
Gets the stator resistance value in per unit (pu), IQ30.
EST_setRr_pu
void EST_setRr_pu(EST_Handle handle, const _iq Rr_pu)
Sets the rotor resistance value in the estimator in per unit (pu), IQ30.
EST_getMaxCurrentSlope_epl_pu
_iq EST_getMaxCurrentSlope_epl_pu(EST_Handle handle)
Gets the maximum EPL (Efficient Partial Load) current slope value used in the estimator in per unit (...
EST_setFlag_enableForceAngle
void EST_setFlag_enableForceAngle(EST_Handle handle, const bool state)
Sets the enable force angle flag in the estimator.
EST_getMaxAccel_est_pu
_iq EST_getMaxAccel_est_pu(EST_Handle handle)
Gets the maximum estimation acceleration value used in the estimator in per unit (pu), IQ24.
EST_getRsOnLine_pu
_iq EST_getRsOnLine_pu(EST_Handle handle)
Gets the online stator resistance value in per unit (pu), IQ30.
EST_setRs_delta_pu
void EST_setRs_delta_pu(EST_Handle handle, const _iq Rs_delta_pu)
Sets the delta stator resistance value.
EST_getLs_coarse_max_pu
_iq EST_getLs_coarse_max_pu(EST_Handle handle)
Gets the maximum stator inductance value during coarse estimation in the stator inductance estimator...
EST_getFlag_enableForceAngle
bool EST_getFlag_enableForceAngle(EST_Handle handle)
Gets the enable force angle flag value from the estimator.
EST_getFlag_estComplete
bool EST_getFlag_estComplete(EST_Handle handle)
Gets the value of the flag which denotes when the estimation is complete.
EST_getFlux_Wb
float_t EST_getFlux_Wb(EST_Handle handle)
Gets the flux value in Webers (Wb).
EST_setMaxAccel_pu
void EST_setMaxAccel_pu(EST_Handle handle, const _iq maxAccel_pu)
Sets the maximum acceleration value in the estimator in per unit (pu), IQ24.
EST_ErrorCode_e
EST_ErrorCode_e
Enumeration for the estimator error codes.
Definition: est_states.h:38
EST_setId_ref_pu
void EST_setId_ref_pu(EST_Handle handle, const _iq Id_ref_pu)
Sets the direct current (Id) reference value in the estimator in per unit (pu), IQ24.
EST_getSpeed_krpm
_iq EST_getSpeed_krpm(EST_Handle handle)
Gets the speed value in per unit (pu), IQ24.
EST_setRsOnLineAngleDelta_pu
void EST_setRsOnLineAngleDelta_pu(EST_Handle handle, const _iq angleDelta_pu)
Sets the delta angle value in the online stator resistance estimator.
EST_getTorque_lbin
_iq EST_getTorque_lbin(EST_Handle handle)
Gets the torque value in per unit (pu), IQ24.
EST_setIq_ref_pu
void EST_setIq_ref_pu(EST_Handle handle, const _iq Iq_ref_pu)
Sets the quadrature current (Iq) reference value in the estimator in per unit (pu), IQ24.
EST_setRsOnLineId_mag_pu
void EST_setRsOnLineId_mag_pu(EST_Handle handle, const _iq Id_mag_pu)
Sets the Id magnitude value used for online stator resistance estimation in per unit (pu)...
EST_getFe_pu
_iq EST_getFe_pu(EST_Handle handle)
Gets the electrical frequency of the motor in per unit (pu), IQ24.
EST_setFe_pos_min_pu
void EST_setFe_pos_min_pu(EST_Handle handle, const _iq fe_pos_min_pu)
Sets minimum positive electrical frequency from the estimator.
_MATH_vec2_
Defines a two element vector.
Definition: 32b/math.h:248
EST_setFe_neg_max_pu
void EST_setFe_neg_max_pu(EST_Handle handle, const _iq fe_neg_max_pu)
Sets maximum negative electrical frequency from the estimator.
EST_isOnLine
bool EST_isOnLine(EST_Handle handle)
Determines if the estimator is ready for online control.
EST_getFlag_updateRs
bool EST_getFlag_updateRs(EST_Handle handle)
Gets the value of the flag which enables the updating of the stator resistance (Rs) value...
EST_setMaxCurrentSlope_pu
void EST_setMaxCurrentSlope_pu(EST_Handle handle, const _iq maxCurrentSlope_pu)
Sets the maximum current slope value in the estimator in per unit (pu), IQ24.
EST_Handle
struct _EST_Obj_ * EST_Handle
Defines the estimator (EST) handle.
Definition: 32b/est.h:52
EST_setIdle
void EST_setIdle(EST_Handle handle)
Sets the estimator to idle.
EST_getMaxAccel_pu
_iq EST_getMaxAccel_pu(EST_Handle handle)
Gets the maximum acceleration value used in the estimator in per unit (pu), IQ24. ...
EST_getRsOnLineFilterParams
void EST_getRsOnLineFilterParams(EST_Handle handle, const EST_RsOnLineFilterType_e filterType, _iq *pFilter_0_b0, _iq *pFilter_0_a1, _iq *pFilter_0_y1, _iq *pFilter_1_b0, _iq *pFilter_1_a1, _iq *pFilter_1_y1)
Gets the online stator resistance filter parameters in per unit (pu), IQ24.
EST_get_pu_to_krpm_sf
_iq EST_get_pu_to_krpm_sf(EST_Handle handle)
Gets the pu to krpm scale factor in per unit (pu), IQ24.
EST_getFullScaleCurrent
float_t EST_getFullScaleCurrent(EST_Handle handle)
Gets the full scale current value used in the estimator in Amperes (A).
EST_getRr_qFmt
uint_least8_t EST_getRr_qFmt(EST_Handle handle)
Gets the rotor resistance Q format in 8 bit unsigned integer (uint_least8_t).
EST_setFullScaleFreq
void EST_setFullScaleFreq(EST_Handle handle, const float_t fullScaleFreq)
Sets the full scale frequency in the estimator in Hertz (Hz).
EST_setFullScaleResistance
void EST_setFullScaleResistance(EST_Handle handle, const float_t fullScaleResistance)
Sets the full scale resistance in the estimator in Ohms ( ).
EST_getRs_delta_pu
_iq EST_getRs_delta_pu(EST_Handle handle)
Gets the delta stator resistance value from the stator resistance estimator.
EST_setFreqBeta_lp_pu
void EST_setFreqBeta_lp_pu(EST_Handle handle, const _iq beta_lp_pu)
Sets the value used to set the low pass pole location in the frequency estimator in per unit (pu)...
_iq
long _iq
Definition: 32b/IQmathLib.h:223
EST_setRsOnLine_pu
void EST_setRsOnLine_pu(EST_Handle handle, const _iq Rs_pu)
Sets the stator resistance value in the online stator resistance estimator in per unit (pu)...
est_states.h
Contains the states for the estimator (EST) module routines.
EST_setLs_qFmt
void EST_setLs_qFmt(EST_Handle handle, const uint_least8_t Ls_qFmt)
Sets the stator inductance Q format in the estimator in 8 bit unsigned integer (uint_least8_t).
EST_setFlag_updateRs
void EST_setFlag_updateRs(EST_Handle handle, const bool state)
Sets the update stator resistance (Rs) flag in the estimator.
EST_getFullScaleVoltage
float_t EST_getFullScaleVoltage(EST_Handle handle)
Gets the full scale voltage value used in the estimator in Volts (V).
EST_computeDirection_qFmt
uint_least8_t EST_computeDirection_qFmt(EST_Handle handle, const float_t flux_max)
Computes the direction Q format for the estimator.
EST_getLs_max_pu
_iq EST_getLs_max_pu(EST_Handle handle)
Gets the maximum stator inductance value from the stator inductance estimator.
EST_getLs_d_pu
_iq EST_getLs_d_pu(EST_Handle handle)
Gets the direct stator inductance value in per unit (pu), IQ30.
EST_setDir_qFmt
void EST_setDir_qFmt(EST_Handle handle, const uint_least8_t dir_qFmt)
Sets the direction Q format in the estimator.
EST_getLs_dq_pu
void EST_getLs_dq_pu(EST_Handle handle, MATH_vec2 *pLs_dq_pu)
Gets the direct/quadrature stator inductance vector values from the estimator in per unit (pu)...
EST_getIdRated_ratedFlux_pu
_iq EST_getIdRated_ratedFlux_pu(EST_Handle handle)
Gets the Id current value used for flux estimation of induction motors in per unit (pu)...
EST_getFlag_enableRsOnLine
bool EST_getFlag_enableRsOnLine(EST_Handle handle)
Gets the value of the flag which enables online stator resistance (Rs) estimation.
EST_getLs_d_H
float_t EST_getLs_d_H(EST_Handle handle)
Gets the direct stator inductance value in Henries (H).
EST_setFlag_enableRsRecalc
void EST_setFlag_enableRsRecalc(EST_Handle handle, const bool state)
Sets the enable stator resistance (Rs) re-calculation flag in the estimator.
EST_getFe
float_t EST_getFe(EST_Handle handle)
Gets the electrical frequency of the motor in Hertz (Hz).
EST_getForceAngleStatus
bool EST_getForceAngleStatus(EST_Handle handle)
Gets the status of the force angle operation in the estimator.
EST_setDcBus_pu
void EST_setDcBus_pu(EST_Handle handle, const _iq dcBus_pu)
Sets the DC bus voltage in the estimator in per unit (pu), IQ24.
EST_State_e
EST_State_e
Enumeration for the estimator states.
Definition: est_states.h:51
EST_getErrorCode
EST_ErrorCode_e EST_getErrorCode(EST_Handle handle)
Gets the error code from the estimator.
EST_setFullScaleCurrent
void EST_setFullScaleCurrent(EST_Handle handle, const float_t fullScaleCurrent)
Sets the full scale current in the estimator in Amperes (A).
EST_resetCounter_ctrl
void EST_resetCounter_ctrl(EST_Handle handle)
Resets the control counter.
EST_setFullScaleFlux
void EST_setFullScaleFlux(EST_Handle handle, const float_t fullScaleFlux)
Gets the full scale flux value used in the estimator in Volts*seconds (V.s).
EST_doSpeedCtrl
bool EST_doSpeedCtrl(EST_Handle handle)
Determines if speed control should be performed during motor identification.
EST_setRsOnLine_qFmt
void EST_setRsOnLine_qFmt(EST_Handle handle, const uint_least8_t Rs_qFmt)
Sets the stator resistance Q format in the online stator resistance estimator in 8 bit unsigned integ...
EST_getDir_qFmt
uint_least8_t EST_getDir_qFmt(EST_Handle handle)
Gets the direction Q format from the estimator.
EST_getLs_qFmt
uint_least8_t EST_getLs_qFmt(EST_Handle handle)
Gets the stator inductance Q format in 8 bit unsigned integer (uint_least8_t).
EST_getFullScaleResistance
float_t EST_getFullScaleResistance(EST_Handle handle)
Gets the full scale resistance value used in the estimator in Ohms ( ).
EST_getOneOverDcBus_pu
_iq EST_getOneOverDcBus_pu(EST_Handle handle)
Gets the inverse of the DC bus voltage in per unit (pu), IQ24.
EST_getFlux_pu
_iq EST_getFlux_pu(EST_Handle handle)
Gets the flux value in per unit (pu), IQ24.
EST_getLs_q_H
float_t EST_getLs_q_H(EST_Handle handle)
Gets the stator inductance value in the quadrature coordinate direction in Henries (H)...
EST_getIdRated_indEst_pu
_iq EST_getIdRated_indEst_pu(EST_Handle handle)
Gets the Id current value used for inductance estimation of induction motors in per unit (pu)...
EST_setLs_delta_pu
void EST_setLs_delta_pu(EST_Handle handle, const _iq Ls_delta_pu)
Sets the delta stator inductance value during fine estimation.
math.h
Contains the public interface to the math (MATH) module routines.
EST_getFullScaleFlux
float_t EST_getFullScaleFlux(EST_Handle handle)
Gets the full scale flux value used in the estimator in Volts per Hertz (V/Hz).
EST_getState
EST_State_e EST_getState(EST_Handle handle)
Gets the state of the estimator.
EST_getLs_min_pu
_iq EST_getLs_min_pu(EST_Handle handle)
Gets the minimum stator inductance value from the stator inductance estimator.
EST_getIab_pu
void EST_getIab_pu(EST_Handle handle, MATH_vec2 *pIab)
Gets the Iab current vector in per unit (pu), IQ24.
EST_getFm_pu
_iq EST_getFm_pu(EST_Handle handle)
Gets the mechanical frequency of the motor in per unit (pu), IQ24.
EST_useZeroIq_ref
bool EST_useZeroIq_ref(EST_Handle handle)
Determines if a zero Iq current reference should be used in the controller.
EST_setFlag_estComplete
void EST_setFlag_estComplete(EST_Handle handle, const bool state)
Sets the estimation complete flag in the estimator.
EST_setMaxAccel_est_pu
void EST_setMaxAccel_est_pu(EST_Handle handle, const _iq maxAccel_pu)
Sets the maximum estimation acceleration value in the estimator in per unit (pu), IQ24...
EST_setFlag_enableRsOnLine
void EST_setFlag_enableRsOnLine(EST_Handle handle, const bool state)
Sets the enable Rs online flag in the estimator.
EST_setFullScaleVoltage
void EST_setFullScaleVoltage(EST_Handle handle, const float_t fullScaleVoltage)
Sets the full scale resistance in the estimator in Volts (V).
EST_getIdRated
float_t EST_getIdRated(EST_Handle handle)
Gets the Id rated current value from the estimator in Amperes (A).
EST_getFreqBeta_lp_pu
_iq EST_getFreqBeta_lp_pu(EST_Handle handle)
Gets the value used to set the pole location in the low-pass filter of the frequency estimator in per...
EST_getLs_q_pu
_iq EST_getLs_q_pu(EST_Handle handle)
Gets the stator inductance value in the quadrature coordinate direction in per unit (pu)...
EST_getFreqB0_lp_pu
_iq EST_getFreqB0_lp_pu(EST_Handle handle)
Gets the low pass filter numerator value in the frequency estimator in per unit (pu), IQ30.
EST_getFullScaleFreq
float_t EST_getFullScaleFreq(EST_Handle handle)
Gets the full scale frequency value used in the estimator in Hertz (Hz).
EST_genOutputLimits_Pid_Id
void EST_genOutputLimits_Pid_Id(EST_Handle handle, const _iq maxDutyCycle, _iq *outMin, _iq *outMax)
Generated the PID Id controller output limits.
EST_getRs_Ohm
float_t EST_getRs_Ohm(EST_Handle handle)
Gets the stator resistance value in Ohms ( ).
EST_setMaxCurrentSlope_epl_pu
void EST_setMaxCurrentSlope_epl_pu(EST_Handle handle, const _iq maxCurrentSlope_pu)
Sets the maximum EPL (Efficient Partial Load) current slope value used in the estimator in per unit (...
EST_doCurrentCtrl
bool EST_doCurrentCtrl(EST_Handle handle)
Determines if current control should be performed during motor identification.
EST_getLr_H
float_t EST_getLr_H(EST_Handle handle)
Gets the rotor inductance value in Henries (H).
EST_setLs_dq_pu
void EST_setLs_dq_pu(EST_Handle handle, const MATH_vec2 *pLs_dq_pu)
Sets the direct/quadrature stator inductance vector values in the estimator in per unit (pu)...
EST_getAngle_pu
_iq EST_getAngle_pu(EST_Handle handle)
Gets the angle value from the estimator in per unit (pu), IQ24.
EST_setRs_qFmt
void EST_setRs_qFmt(EST_Handle handle, uint_least8_t Rs_qFmt)
Sets the stator resistance Q format in the estimator in 8 bit unsigned integer (uint_least8_t).
EST_isMotorIdentified
bool EST_isMotorIdentified(EST_Handle handle)
Determines if the motor has been identified.
EST_setForceAngleDelta_pu
void EST_setForceAngleDelta_pu(EST_Handle handle, const _iq angleDelta_pu)
Sets the force angle delta value in the estimator in per unit (pu), IQ24.
EST_setRr_qFmt
void EST_setRr_qFmt(EST_Handle handle, uint_least8_t Rr_qFmt)
Sets the rotor resistance Q format in the estimator in 8 bit unsigned integer (uint_least8_t).
EST_RsOnLineFilterType_Current
Current Filter.
Definition: 32b/est.h:45
EST_isLockRotor
bool EST_isLockRotor(EST_Handle handle)
Determines if the estimator is waiting for the rotor to be locked.
EST_resetCounter_state
void EST_resetCounter_state(EST_Handle handle)
Resets the state counter.
EST_setAngle_pu
void EST_setAngle_pu(EST_Handle handle, const _iq angle_pu)
Sets the angle value in the estimator in per unit (pu), IQ24.
EST_getRsOnLine_qFmt
uint_least8_t EST_getRsOnLine_qFmt(EST_Handle handle)
Gets the online stator resistance Q format in 8 bit unsigned integer (uint_least8_t).
EST_setIdRated_pu
void EST_setIdRated_pu(EST_Handle handle, const _iq IdRated_pu)
Sets the Id rated current value in the estimator in per unit (pu), IQ24.
EST_setRs_pu
void EST_setRs_pu(EST_Handle handle, const _iq Rs_pu)
Sets the stator resistance value used in the estimator in per unit (pu), IQ30.
EST_setFullScaleInductance
void EST_setFullScaleInductance(EST_Handle handle, const float_t fullScaleInductance)
Sets the full scale inductance in the estimator in Henries (H).
EST_getMaxCurrentSlope_pu
_iq EST_getMaxCurrentSlope_pu(EST_Handle handle)
Gets the maximum current slope value used in the estimator in per unit (pu), IQ24.
EST_setLs_q_pu
void EST_setLs_q_pu(EST_Handle handle, const _iq Ls_q_pu)
Sets the quadrature stator inductance value in the estimator in per unit (pu), IQ30.
EST_getRs_qFmt
uint_least8_t EST_getRs_qFmt(EST_Handle handle)
Gets the stator resistance Q format in 8 bit unsigned integer (uint_least8_t).
EST_setFlag_enableFluxControl
void EST_setFlag_enableFluxControl(EST_Handle handle, const bool state)
Sets the enable flux control flag in the estimator.
EST_getFm
float_t EST_getFm(EST_Handle handle)
Gets the mechanical frequency of the motor in Hertz (Hz).
EST_get_krpm_to_pu_sf
_iq EST_get_krpm_to_pu_sf(EST_Handle handle)
Gets the krpm to pu scale factor in per unit (pu), IQ24.
EST_getFullScaleInductance
float_t EST_getFullScaleInductance(EST_Handle handle)
Gets the full scale inductance value used in the estimator in Henries (H).
EST_getRsOnLineId_pu
_iq EST_getRsOnLineId_pu(EST_Handle handle)
Gets the Id value used for online stator resistance estimation in per unit (pu), IQ24.
EST_isIdle
bool EST_isIdle(EST_Handle handle)
Determines if the estimator is idle.
EST_setFreqB0_lp_pu
void EST_setFreqB0_lp_pu(EST_Handle handle, const _iq b0_lp_pu)
Sets the low pass filter numerator value in the frequency estimator in per unit (pu), IQ30.
EST_getFslip_pu
_iq EST_getFslip_pu(EST_Handle handle)
Gets the slip frequency of the motor in per unit (pu), IQ24.
EST_computeLr_H
float_t EST_computeLr_H(EST_Handle handle, const _iq current)
Computes the rotor inductance in Henries (H)
EST_getForceAngleDelta_pu
_iq EST_getForceAngleDelta_pu(EST_Handle handle)
Gets the force angle delta value from the estimator in per unit (pu), IQ24.
EST_getLr_qFmt
uint_least8_t EST_getLr_qFmt(EST_Handle handle)
Gets the rotor inductance Q format in 8 bit unsigned integer (uint_least8_t).
EST_getTorque_Nm
_iq EST_getTorque_Nm(EST_Handle handle)
Gets the torque value in per unit (pu), IQ24.
EST_getRsOnLineId_mag_pu
_iq EST_getRsOnLineId_mag_pu(EST_Handle handle)
Gets the Id magnitude value used for online stator resistance estimation in per unit (pu)...
EST_setIdle_all
void EST_setIdle_all(EST_Handle handle)
Sets the estimator and all of the subordinate estimators to idle.
EST_RsOnLineFilterType_Voltage
Voltage Filter.
Definition: 32b/est.h:46
IQmathLib.h
EST_updateState
bool EST_updateState(EST_Handle handle, const _iq Id_target_pu)
Updates the estimator state.
EST_getRr_Ohm
float_t EST_getRr_Ohm(EST_Handle handle)
Gets the rotor resistance value in Ohms ( ).
EST_getLr_pu
_iq EST_getLr_pu(EST_Handle handle)
Gets the rotor inductance value in per unit (pu), IQ30.
EST_updateId_ref_pu
void EST_updateId_ref_pu(EST_Handle handle, _iq *pId_ref_pu)
Updates the Id reference value used for online stator resistance estimation in per unit (pu)...
EST_genOutputLimits_Pid_Iq
void EST_genOutputLimits_Pid_Iq(EST_Handle handle, const _iq maxDutyCycle, const _iq out_Id, _iq *outMin, _iq *outMax)
Generated the PID Id controller output limits.
EST_setRsOnLineId_pu
void EST_setRsOnLineId_pu(EST_Handle handle, const _iq Id_pu)
Sets the Id value in the online stator resistance estimator in per unit (pu), IQ24.
EST_setRsOnLineFilterParams
void EST_setRsOnLineFilterParams(EST_Handle handle, const EST_RsOnLineFilterType_e filterType, const _iq filter_0_b0, const _iq filter_0_a1, const _iq filter_0_y1, const _iq filter_1_b0, const _iq filter_1_a1, const _iq filter_1_y1)
Sets the online stator resistance filter parameters in per unit (pu), IQ24.
EST_getFslip
float_t EST_getFslip(EST_Handle handle)
Gets the slip frequency of the motor in Hertz (Hz).
EST_getDcBus_pu
_iq EST_getDcBus_pu(EST_Handle handle)
Gets the DC bus value from the estimator in per unit (pu), IQ24.
EST_getRr_pu
_iq EST_getRr_pu(EST_Handle handle)
Gets the rotor resistance value in per unit (pu), IQ30.
EST_getFlag_enableRsRecalc
bool EST_getFlag_enableRsRecalc(EST_Handle handle)
Gets the enable stator resistance re-calibrate flag value from the estimator.
EST_RsOnLineFilterType_e
EST_RsOnLineFilterType_e
Enumeration for the Rs online filter types.
Definition: 32b/est.h:43
EST_setLs_d_pu
void EST_setLs_d_pu(EST_Handle handle, const _iq Ls_d_pu)
Sets the direct stator inductance value in the estimator in per unit (pu), IQ30.
float_t
float float_t
Defines the portable data type for 32 bit, signed floating-point data.
Definition: types.h:121
EST_getLs_delta_pu
_iq EST_getLs_delta_pu(EST_Handle handle)
Gets the delta stator inductance value in the stator inductance estimator.
EST_run
void EST_run(EST_Handle handle, const MATH_vec2 *pIab_pu, const MATH_vec2 *pVab_pu, const _iq dcBus_pu, const _iq speed_ref_pu)
Runs the estimator.
EST_getSignOfDirection
int_least8_t EST_getSignOfDirection(EST_Handle handle)
Gets the sign of the direction value in 8 bit signed integer (int_least8_t).