How can I create code for an embedded Linux target with Simulink hosted on Windows?
18 views (last 30 days)
I want to be able to create code a multitasking embedded Linux target from Simulink hosted on Windows. The Windows machine does not have access to the Linux compiler tools and so all I want is to be able to copy the generated code manually to Eclipse on a different Linux machine and build it there.
I am basically trying to following the method in this post but with the Linux tools being hosted on a different machine: http://www.mathworks.co.uk/matlabcentral/answers/95176-from-my-windows-platform-how-do-i-build-a-model-with-concurrently-executing-sample-times-and-which
I have set the System target file to 'idelink_ert.tlc' and then on the Code target tab set the Build Format to 'makefile' and the Build action to 'create_makefile'. However, when I try to build the model the process fails when it seems to try and run the makefile to build the target and can't find the target tools. I want 'create_makefile' to do just that and no more; in fact I don't even need a makefile, I just want the .c and .h files.
Is there a way to stop the build from 'running' the make file?
Kaustubha Govind on 29 Aug 2014
You can select the Generate Code Only checkbox on the Code Generation pane of the Configuration Parameters Window to prevent build. I would also recommend selecting the "Package code and artifacts" checkbox on the same pane (on releases older than R2012b, you can manually use the packNGo utility to do the same). This will ensure that any additional artifacts (other than the .c and .h in the _rtw folder) are also packaged for relocation.