Set new Kp function
-
void uz_SpeedControl_set_Kp(uz_SpeedControl_t *self, float new_Kp)
Function to change the Kp-value of the PI-Controller during runtime.
- Parameters:
self – pointer to uz_SpeedControl_t object
new_Kp – value for Kp. Must be greater or equal than 0.0f
Example
1int main(void) {
2float new_Kp = 14.5f;
3 uz_SpeedControl_set_Kp(SC_instance, new_Kp);
4}
Description
Updates the proportional gain of the PI-Controller inside the SpeedControl during runtime. Asserts that the new value is greater or equal than 0.0f.