In Simulink, how to include source and header files in the generated code (project)

4 views (last 30 days)
Hi!
I'm working on generating C code from Simulink modell for FreeRTOS. So, I generated some working code, but theese weren't built by Simulink Embedded coder, only generated. I built the codes in VisualStudio. The downloaded FreeRTOS folder contains a lot of source, header files and folders. There is a folder, in which there is a VS project, and it's for trying the codes in windows. If I put my generated code into this project, there wasn't any problem. But I want to speed up this method, so I would like if I have to push only the "Build" button, and as a result of it I would get the executable file. My problem is, that I can't link correctly the needed files and folders of FreeRTOS. In the first round I just want to get a totally Simulink generated VisualStudio project, which can produce a running program by building it. I tried adding folders on "Custom Code" pane of "Configuration Parameters" but it didn't work. As I see, I can include directories, which contain header and source files, but in the generated VS project only the header files appeared and there are a lot of errrors.(For example there are a lot of undeclared identifiers, which are normally defined by a file of FreeRTOS.) Because of the high number of source files, I don't want to type all the pathes of them. So my question is, how is it possible to simply generate a project by Simulink, which contains all the essential files and folders?! Thank you very much!

Answers (0)

Categories

Find more on Simulink Coder in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!