How do I set include paths for accelerated referenced sub-models?

3 visualizaciones (últimos 30 días)
I am using 2014b Matlab and Simulink.
I have a referenced sub-model with an EML block that references C code defined in a header file. In Normal mode, I can include the header file in the configuration parameters dialog in Simulation Target->Custom Code panel under Source file and Header file, and set up the include path there as well. This appears to be completely ignored in accelerated mode. I blindly tried setting the equivalent paths in the Code Generation area, but that did nothing as well.
I get a little closer by using coder.cinclude('custom_code.h') in the EML block, so it attempts to include the proper header file, but the building of the C files for the accelerated model still does not have a defined include path, so I get a build error on not being able to open the include file.
Two questions: 1) why doesn't building in accelerated mode use exactly the same simulation target parameters as normal and 2) given that that is broken (or, more likely, I am not seeing the "big picture,") how can I get an include path to the build of the accelerated mode referenced sub-model?

Respuestas (0)

Categorías

Más información sobre Simulation en Help Center y File Exchange.

Productos

Community Treasure Hunt

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

Start Hunting!

Translated by