3.9.4 mcUtils_PiIntegralUpdate

C


/* Updates the integral part of the floating point PI control  */
void mcUtils_PiIntegralUpdate( const float32_t value, tmcUtils_PiControl_s  * const pControl )

/* Updates the integral part of the fixed point PI control  */
void mcUtils_PiIntegralUpdate(const int16_t value, tmcUtils_PiControl_s * const pControl)
	

Summary

Updates the integral part of the PI control.

Description

This function updates the integral term of the PI control with the specified value.

Precondition

None.

Parameters

ParamDescription
valueIntegral value to be updated. Please refer the generated header for the exact data type.
pControlPointer to the PI control structure to be updated.

Returns

None

Example

/ Define the PI control module data structure
tmcUtils_PiControl_s piControl;

// Define the parameters for floating point PI control 
float32_t Ki_value = 1.0f;

// Define the parameters for fixed point PI control 
int16_t Ki_value = 1;

mcUtils_PiControlInit(Ki_value, &piControl);
    

Remarks

Refer the generated header file for the exact function signature.