| Author |
Message |
hbaocr
Joined: 13 May 2007 Posts: 236 Helped: 15 Location: Hochiminh City university of technology (VietNam)
|
28 Nov 2007 13:34 Help me to generate C code from matlab. |
|
|
|
Hello,all
I'm a final year student . And I have some problem in my project.
That is how can I generate C code from matlab code to use It in my Keil ARM project!
I'm analysing Spectrum of Voice signal using my PC by matlab.I my problem is : how can i generate it to C code or header file *.h and use this code to write my program in KEIL ARM to let my uC LPC 2148 recognize Voice to control other devices .That Make my project can operate without depending on PC.
|
|
| Back to top |
|
 |
ehsanica
Joined: 15 Nov 2005 Posts: 81 Helped: 10
|
28 Nov 2007 17:26 Re: Help me to generate C code from matlab. |
|
|
|
did you chek mex?
try it and you can obtain good results.
|
|
| Back to top |
|
 |
hbaocr
Joined: 13 May 2007 Posts: 236 Helped: 15 Location: Hochiminh City university of technology (VietNam)
|
28 Nov 2007 17:32 Re: Help me to generate C code from matlab. |
|
|
|
thank
I Have already used mcc -l mfile.m to generrate file *.c and *.h but I don't know how to use that file in my project KEIL ARM to write C code for ARM LPC2148
|
|
| Back to top |
|
 |
red5000
Joined: 06 Nov 2006 Posts: 61 Helped: 4
|
19 Dec 2007 14:06 Help me to generate C code from matlab. |
|
|
|
| this site can help you : www.developpez.com
|
|
| Back to top |
|
 |
rag_perfect
Joined: 01 Sep 2005 Posts: 150 Helped: 7 Location: India
|
20 Dec 2007 11:18 Re: Help me to generate C code from matlab. |
|
|
|
check out this paper...
here is the link...
http://web.bsu.edu/tti/5_1/5_1f/5_1f.htm
simply copy n paste C code in keil IDE....
 
|
|
| Back to top |
|
 |
samuraign
Joined: 18 May 2006 Posts: 116 Helped: 6
|
21 Dec 2007 13:40 Re: Help me to generate C code from matlab. |
|
|
|
hi hbaocr ,
could you share some more info.
Have u used Real Time Workshop with embeded c-coder for the above.
|
|
| Back to top |
|
 |
amrstaha
Joined: 29 Aug 2005 Posts: 142 Helped: 6 Location: Egypt
|
23 Dec 2007 13:12 Re: Help me to generate C code from matlab. |
|
|
|
Look at the new Embedded MATLAB. It is extremely simple and works seamlessly with Real-time wrokshop to generate C/C++ code from M-Files and Simulink Models. I think you will find it in MATLAB R2007a and later.
There are also thrid-party tools that take M-Files and generate C Code such as Catalytic MCS and ACCelDSP.
See this:
http://www.embedded.com/columns/technicalinsights/204802710?_requestid=527393
I hope this helps.
Good luck.
|
|
| Back to top |
|
 |
dvtruongson
Joined: 03 Oct 2006 Posts: 84 Helped: 19
|
20 Feb 2008 4:18 Help me to generate C code from matlab. |
|
|
|
| Does anybody follow up on this topic? I read the embedded site, but it seems commercial product. Do we have any freeware or open source?
|
|
| Back to top |
|
 |
kiprono
Joined: 18 Nov 2005 Posts: 236 Helped: 15 Location: Nairobi
|
04 Mar 2008 23:08 Re: Help me to generate C code from matlab. |
|
|
|
| It is possible to generate directly from Matlab using mex function. But the generated code usually looks weird and not easy to follow. Just code your own program in C and only call the specific Matlab functions from Visual Studio. You will get an independent executable code.
|
|
| Back to top |
|
 |
Asif2008
Joined: 07 Mar 2008 Posts: 24 Helped: 1
|
07 Mar 2008 21:08 Re: Help me to generate C code from matlab. |
|
|
|
| i will tell u tomorrow
|
|
| Back to top |
|
 |