Hi liuqimin,
Relate with your original post:
Is there any way to handle this situation?
You should be able to generate the code from Simulink for the original model - even if it is represented in continuous time domain (1/s). Not sure what error are you getting. If there is an error about data types i think you can use data type conversion between subsystems. You will probably lose some precision between double->single but it should work.
The S32K MCU has a FPU unit on 32bit hence it should deal with such algorithms pretty well. It will not be optimal but it should work.
An addition step that you can do to improve the execution on S32K MCU, is to convert your original model from s-domain to z-domain and implement it into single data type.
In regards with your second post:
However, it is not correct to use the GFLIB_IntegratorTR_FLT module in the S32K toolkit instead.Perhaps the parameter fltC1 is incorrect.Is this parameter the same as the parameter in the discrete integral module as the gain coefficient?If not, how to determine this parameter?
Please have a look into the S32K14xMCLUB.pdf manual $5.48 page 567. It shows how to compute the paramter C1f depending on the type of integrator you may want to use.
Basically for the floating point implementation it should be: fltC1 = Ts/2
Best regards,
Daniel