Creating MATLAB C ++ Code

So, I am working on a design flow for my DSP, where first the filtering algorithm is first modeled in MATLAB and then converted to C / C ++ for real DSP equipment using the MATLAB encoder. Pretty I thought.

So, my plan was to write my own main C function, which receives input from ADC registers, etc., and then just calls the generated filter function in my main function. Then I included filter.c and filter.h in the source files for my project in TI CodeComposerStudio.

I tested the design flow with the simple MATLAB function, which simply takes two numbers and multiplies them together. Now the result of running codegen on this function is crazy. About 20 files were created there. So when I add the source files to my CCS project, I really need to add each library, right? It seems to me that this code cannot be effective?

Did I miss something that would allow MATLAB to simply create a simple implementation of a single source with a single source? Is the generated code really efficient? Has anyone really had experience using MATLAB Coder to work in real-time DSP?

Thank.


EDIT: The only files I add to my CCS project are .c and its associated .h files created by MATLAB. Shouldn't there be a fairly simple binding process? Is there anyway I can create a makefile via MATLAB that will help in this process?

+5
source share
1 answer

MATLAB , . , . MATLAB . , Matlab, TI CCS, , , .

CCS, . MATLAB , DSP - , MATLAB. , . - CCS matlab .

+3

All Articles