MATLAB: M-file programme to embed in DSP

dspf28335m-fileMATLABsimulink

I try to programme the TMS28335 DSP with simulink blocks (ADC,SCI transmit, receive)using the serial cable communications. I have m-file programmes and I need to convert and embed to DSP. ıs there any block for using the m-file codes in DSP? I tried the embedded matlab function block, but it gives a lot of problems for my programme. Please help about my study. Thank you.

Best Answer

If you have MATLAB code that you need to use in a Simulink model that you intend to generate code from, the correct way is indeed to use an (Embedded) MATLAB Function block. However, only a subset of the MATLAB language is eligible for code-generation. Please be sure that you conform to these requirements - if you run into specific error, please post them with your code and the exact error message(s).
Related Question