Here is the list of motor transformation function APIs
Here is the list of SVGEN_CURRENT function APIs
Sub Modules | |
| APIs for Phase Voltage Calculation (VOLREC) | |
Files | |
| file | clarke.h |
| Contains abc to alpha/beta/0 transform implementation. | |
| file | park.h |
| Contains alpha/beta/0 to d/q/0 transform implementation. | |
| file | ipark.h |
| Contains d/q/0 to alpha/beta/0 transform implementation. | |
| file | svgen.h |
| Contains svpwm generation implementation. | |
| file | svgen_current.h |
| Contains space vector generation current (SVGENCURRENT) functions implementation. | |
Data Structures | |
| struct | SVGENCURRENT_Obj |
| Defines the Svgen Current object. More... | |
Functions | |
| static void | CLARKE_run_threeInput (const float32_t inIa, const float32_t inIb, const float32_t inIc, float32_t *pIalpha, float32_t *pIbeta) |
| Runs the Clarke transform module for three inputs. More... | |
| static void | CLARKE_run_twoInput (const float32_t inIa, const float32_t inIb, float32_t *pIalpha, float32_t *pIbeta) |
| Runs the Clarke transform module for two inputs. More... | |
| static void | PARK_run (const float32_t sinTh, const float32_t cosTh, const float32_t inIalpha, const float32_t inIbeta, float32_t *pId, float32_t *pIq) |
| Runs the Park transform module. More... | |
| static void | IPARK_run (const float32_t sinTh, const float32_t cosTh, const float32_t inVd, const float32_t inVq, float32_t *pValpha, float32_t *pVbeta) |
| Runs the inverse Park transform module. More... | |
| static void | SVGEN_runCom (const float32_t oneOverDcBus_invV, const float32_t inValpha, const float32_t inVbeta, float32_t *pVa, float32_t *pVb, float32_t *pVc) |
| Implements a SVM that subtracts common-mode term to achieve SV modulation. More... | |
| static void | SVGEN_runMax (const float32_t oneOverDcBus_invV, const float32_t inValpha, const float32_t inVbeta, float32_t *pVa, float32_t *pVb, float32_t *pVc) |
| Implements a DPWM that uses maximum modulation. More... | |
| static void | SVGEN_runMin (const float32_t oneOverDcBus_invV, const float32_t inValpha, const float32_t inVbeta, float32_t *pVa, float32_t *pVb, float32_t *pVc) |
| Implements a DPWM that uses minimum modulation. More... | |
| static void | SVGEN_clamp (const float32_t Umax, const float32_t Umin, float32_t *pVa, float32_t *pVb, float32_t *pVc) |
| Saturates the SVM variable base on modulation limits. More... | |
| SVGENCURRENT_Handle | SVGENCURRENT_init (void *pMemory, const size_t numBytes) |
| Initializes the svgen current object. More... | |
| void | SVGENCURRENT_setup (SVGENCURRENT_Handle handle, const float32_t minWidth_usec, const float32_t pwmFreq_kHz, const float32_t systemFreq_MHz) |
| Sets up the PWM minimum width. More... | |
| static void | SVGENCURRENT_setMinWidth (SVGENCURRENT_Handle handle, const int16_t minwidth) |
| Sets the minimum Duty Cycle width that the lower switch can be on before. More... | |
| static void | SVGENCURRENT_setIgnoreShunt (SVGENCURRENT_Handle handle, const SVGENCURRENT_IgnoreShunt_e ignoreShunt) |
| Sets the ignore shunt value. More... | |
| static void | SVGENCURRENT_setMode (SVGENCURRENT_Handle handle, const SVGENCURRENT_MeasureShunt_e compMode) |
| Sets the compensation mode. More... | |
| static void | SVGENCURRENT_setVlimit (SVGENCURRENT_Handle handle, const float32_t Vlimit) |
| Sets the output voltage limit value for gurrantee a current sampling. More... | |
| static SVGENCURRENT_IgnoreShunt_e | SVGENCURRENT_getIgnoreShunt (SVGENCURRENT_Handle handle) |
| Gets the ignore shunt value. More... | |
| static int16_t | SVGENCURRENT_getMinWidth (SVGENCURRENT_Handle handle) |
| Gets the minimum Duty Cycle width that the lower switch can be on before. More... | |
| static float32_t | SVGENCURRENT_getVlimit (SVGENCURRENT_Handle handle) |
| Gets the Voltage(Duty) Limit value. More... | |
| static SVGENCURRENT_MeasureShunt_e | SVGENCURRENT_getMode (SVGENCURRENT_Handle handle) |
| Gets the current reconstruction mode. More... | |
| static SVGENCURRENT_VmidShunt_e | SVGENCURRENT_getVmid (SVGENCURRENT_Handle handle) |
| Gets the middle amplitude voltage. More... | |
| static void | SVGENCURRENT_RunIgnoreShunt (SVGENCURRENT_Handle handle, uint16_t cmp1, uint16_t cmp2, uint16_t cmp3, uint16_t cmpM1, uint16_t cmpM2, uint16_t cmpM3) |
| Gets the svgen current module ignore shunt. More... | |
| static void | SVGENCURRENT_RunRegenCurrent (SVGENCURRENT_Handle handle, MATH_Vec3 *pADCData, MATH_Vec3 *pADCDataPrev) |
| Reconstructs the missed measured currents due to a small sampling window. More... | |
| static void | SVGENCURRENT_compPWMData (SVGENCURRENT_Handle handle, MATH_Vec3 *pPWMData, MATH_Vec3 *pPWMData_prev) |
| output voltage reconsturction to guarantee min duty in two phase at least More... | |
Typedefs | |
| typedef float | float32_t |
| typedef double | float64_t |
| typedef float | float32_t |
| typedef double | float64_t |
| typedef float | float32_t |
| typedef double | float64_t |
| typedef float | float32_t |
| typedef double | float64_t |
| typedef struct _SVGENCURRENT_Obj_ * | SVGENCURRENT_Handle |
| Defines the Svgen Current handle. More... | |
Macros | |
| #define | IEEE754_TYPES |
| #define | ONE_OVER_THREE 0.33333333333333f |
| #define | ONE_OVER_SQRT_THREE 0.57735026918963f |
| #define | IEEE754_TYPES |
| #define | IEEE754_TYPES |
| #define | IEEE754_TYPES |
| #define | SQRT_THREE_OVER_TWO 0.8660254037844f |
| #define | TWO_OVER_SQRT_THREE 1.15470053837926f |
| #define IEEE754_TYPES |
| #define ONE_OVER_THREE 0.33333333333333f |
| #define ONE_OVER_SQRT_THREE 0.57735026918963f |
| #define IEEE754_TYPES |
| #define IEEE754_TYPES |
| #define IEEE754_TYPES |
| #define SQRT_THREE_OVER_TWO 0.8660254037844f |
| #define TWO_OVER_SQRT_THREE 1.15470053837926f |
| typedef float float32_t |
| typedef double float64_t |
| typedef float float32_t |
| typedef double float64_t |
| typedef float float32_t |
| typedef double float64_t |
| typedef float float32_t |
| typedef double float64_t |
| typedef struct _SVGENCURRENT_Obj_* SVGENCURRENT_Handle |
Defines the Svgen Current handle.
|
static |
Runs the Clarke transform module for three inputs.
| [in] | inIa | Input current value in a-axis |
| [in] | inIb | Input current value in b-axis |
| [in] | inIc | Input current value in c-axis |
| [in] | pIalpha | Output pointer to current value in alpha-axis |
| [in] | pIbeta | Output pointer to current value in beta-axis |
|
static |
Runs the Clarke transform module for two inputs.
| [in] | inIa | Input current value in a-axis |
| [in] | inIb | Input current value in b-axis |
| [in] | pIalpha | Output pointer to current value in alpha-axis |
| [in] | pIbeta | Output pointer to current value in beta-axis |
|
static |
Runs the Park transform module.
| [in] | sinTh | Sine value in radians |
| [in] | cosTh | Cosine value in radians |
| [in] | inIalpha | Input current value in alpha-axis |
| [in] | inIbeta | Input current value in beta-axis |
| [in] | pId | Output pointer to voltage value in d-axis |
| [in] | pIq | Output pointer to voltage value in q-axis |
|
static |
Runs the inverse Park transform module.
| [in] | sinTh | Sine value in radian |
| [in] | cosTh | Cosine value in radian |
| [in] | inVd | Input voltage value in d-axis |
| [in] | inVq | Input voltage value in q-axis |
| [in] | pValpha | Output pointer to voltage value in alpha-axis |
| [in] | pVbeta | Output pointer to voltage value in beta-axis |
|
static |
Implements a SVM that subtracts common-mode term to achieve SV modulation.
| [in] | oneOverDcBus_invV | The inverse dc bus voltage scale factor, used to convert inputs to pu, use 1 if units are already in pu. |
| [in] | inValpha | Input voltage value in alpha-axis, V or pu |
| [in] | inVbeta | Input voltage value in beta-axis, V or pu |
| [in] | pVa | Output pointer to voltage value in a-axis, pu |
| [in] | pVb | Output pointer to voltage value in b-axis, pu |
| [in] | pVc | Output pointer to voltage value in c-axis, pu |
|
static |
Implements a DPWM that uses maximum modulation.
| [in] | oneOverDcBus_invV | The inverse dc bus voltage scale factor, used to convert inputs to pu, use 1 if units are already in pu. |
| [in] | inValpha | Input voltage value in alpha-axis, V or pu |
| [in] | inVbeta | Input voltage value in beta-axis, V or pu |
| [in] | pVa | Output pointer to voltage value in a-axis, pu |
| [in] | pVb | Output pointer to voltage value in b-axis, pu |
| [in] | pVc | Output pointer to voltage value in c-axis, pu |
|
static |
Implements a DPWM that uses minimum modulation.
| [in] | oneOverDcBus_invV | The inverse dc bus voltage scale factor, used to convert inputs to pu, use 1 if units are already in pu. |
| [in] | inValpha | Input voltage value in alpha-axis, V or pu |
| [in] | inVbeta | Input voltage value in beta-axis, V or pu |
| [in] | pVa | Output pointer to voltage value in a-axis, pu |
| [in] | pVb | Output pointer to voltage value in b-axis, pu |
| [in] | pVc | Output pointer to voltage value in c-axis, pu |
|
static |
Saturates the SVM variable base on modulation limits.
| [in] | Umax | Maximum modulation limit |
| [in] | Umin | Minimum modulation limit |
| [in] | pVa | pointer to voltage value in a-axis |
| [in] | pVb | pointer to voltage value in b-axis |
| [in] | pVc | pointer to voltage value in c-axis |
| SVGENCURRENT_Handle SVGENCURRENT_init | ( | void * | pMemory, |
| const size_t | numBytes | ||
| ) |
Initializes the svgen current object.
| [in] | *pMemory | Pointer in to the svgen current object |
| [in] | numBytes | Size of the object |
| void SVGENCURRENT_setup | ( | SVGENCURRENT_Handle | handle, |
| const float32_t | minWidth_usec, | ||
| const float32_t | pwmFreq_kHz, | ||
| const float32_t | systemFreq_MHz | ||
| ) |
Sets up the PWM minimum width.
| [in] | handle | The svgen current (SVGEN) handle |
| [in] | minWidth_usec | The minimum pwm width |
| [in] | pwmFreq_kHz | The PWM frequency, in MHz |
| [in] | systemFreq_MHz | The system SoC frequency, in MHz |
|
inlinestatic |
Sets the minimum Duty Cycle width that the lower switch can be on before.
the current data is invalid.
| [in] | handle | The Svgen Current handle |
| [in] | minwidth | Integer value of the minimum number of pwm counts |
|
inlinestatic |
Sets the ignore shunt value.
| [in] | handle | The Svgen Current handle |
| [in] | ignoreShunt | The ignore shunt value |
|
inlinestatic |
Sets the compensation mode.
| [in] | handle | The Svgen Current handle |
| [in] | compMode | The compensation mode |
|
inlinestatic |
Sets the output voltage limit value for gurrantee a current sampling.
| [in] | handle | The Svgen Current handle |
| [in] | Vlimit | The output voltage limit |
|
inlinestatic |
Gets the ignore shunt value.
| [in] | handle | The Svgen Current handle |
|
inlinestatic |
Gets the minimum Duty Cycle width that the lower switch can be on before.
the current data is invalid.
| [in] | handle | The Svgen Current handle |
|
inlinestatic |
Gets the Voltage(Duty) Limit value.
| [in] | handle | The Svgen Current handle |
|
inlinestatic |
Gets the current reconstruction mode.
| [in] | handle | The Svgen Current handle |
|
inlinestatic |
Gets the middle amplitude voltage.
| [in] | handle | The Svgen Current handle |
|
static |
Gets the svgen current module ignore shunt.
In the pwm structure, the value variable is the on-time of the low fet.
A low value is a small on-time for the low switch of the bridge and thus a short current window.
| [in] | handle | The Svgen Current handle |
| [in] | cmp1 | compare value 1 |
| [in] | cmp2 | compare value 2 |
| [in] | cmp3 | compare value 3 |
| [in] | cmpM1 | active compare value 1, from mirror register |
| [in] | cmpM2 | active compare value 2, from mirror register |
| [in] | cmpM3 | active compare value 3, from mirror register |
|
static |
Reconstructs the missed measured currents due to a small sampling window.
| [in] | handle | The svgen current handle |
| [in] | pADCData | Pointer to the shunt currents |
| [in] | pADCDataPrev | Pointer to the previous shunt currents |
|
static |
output voltage reconsturction to guarantee min duty in two phase at least
| [in] | handle | The svgen current handle |
| [in] | pPWMData | The pointer of the PWM data |
| [in] | pPWMData_prev | The pointer of old PWM data |