MATLAB: Simulink code generation error !!!

simulink code generationsimulink rtw

Hi everybody !
I have some problems with code generation. my generated code looks like okay. But if I make some implementation with this code to another main C-Script, the variables don't suit together :/ I see this error:
incompatible types when assigning to type ‘real_T’
can anybody tell me please where is the problem ? what should I chance to have the right variable type
thanks in advance
Best Regards Onur

Best Answer

You should include the generated header file for the model, it should contain all necessary includes.
Titus