Hi there,
I am using NXP MC9S12ZVML64 mcu with with Automotive Math and Motor Control Library
I am using GFLIB_ControllerPIrAW_F16 library i.e GFLIB_ControllerPIrAW((tFrac16)lf16Error, (GFLIB_CONTROLLER_PIAW_R_T_F16 *) &PIPrms, F16);
for calculating Speed Pi output and current PI output and through switching mechanisim i am selecting one PI value among speed pi and current PI
i am feeding the selected PIoutput value to the MLIB_Mul((tFrac16)PIOut, (tFrac16)CONSTANT_VALUE,F16)) for calculating duty.
and this above sequence of code is working fine.
I want to use GFLIB_ControllerPIrAW_F32 library for above scenario only , can you please let me know that what are the changes required for using
GFLIB_ControllerPIrAW_F32 library instead of GFLIB_ControllerPIrAW_F16 library.
Is there any limitation for using GFLIB_ControllerPIrAW_F32 library with MC9S12ZVML64 mcu.
and also please let me know if i want to feed the same error which is in terms of (tFrac32)lf16Error as GFLIB_ControllerPIrAW_F32 input by only changing the typecasting to tFrac32 if this can be done directly or,i
is there any requirement of increasing the error value in terms of frac32 scale by left shifting the (tFrac32)lf16Error << 15 and then using the same scaled error value as input to GFLIB_ControllerPIrAW_F32 library, is this method is correct.
Please suggest the correct approach to shift to GFLIB_ControllerPIrAW_F32 library using the same GFLIB_ControllerPIrAW_F16 inputs for generating similar kind of results.