MATLAB: How to provide absolute path of include directories in code generation

code generationcustom codeEmbedded Coderinclude pathMATLABsimulinksimulink coder

I want to include some files which is not in the current working directory. Is it possible to provide absolute path in include directory in Custom Code in Code Generation pane. Please mention the syntax to provide the absolute path.

Best Answer

It is possible to include files using a relative or absolute paths. The syntax for relative paths is shown in the following link Relative Custom Code Include Path
To include a absolute path for include files with embedded coder you can simply goto Configuration Parameters -> Code Generation -> Custom Code -> Include Directories and then type in your folder paths i.e. C:\My_Folder\