Shared code placement
Description
Specify the location for generating utility functions, exported data type definitions, and declarations of exported data with custom storage class.
Category: Code Generation > Interface
Settings
Default:
Auto
Auto
The code generator places utility code within the
codeGenFolder
/slprj/
(ortarget
/_sharedutilscodeGenFolder
/
targetSpecific
/_shared
) folder for a model that contains Existing Shared Code (Embedded Coder) or at least one of the following blocks:Model blocks
Simulink Function blocks
Function Caller blocks
Calls to Simulink Functions from Stateflow or MATLAB Function blocks
Stateflow graphical functions when you select the Export Chart Level Functions parameter
If a model does not contain one of the above blocks or Existing Shared Code (Embedded Coder), the code generator places utility code in the build folder (generally, the folder that contains
ormodel
.c
).model
.cppShared location
Directs code for utilities to be placed within the
codeGenFolder
/slprj/
(ortarget
/_sharedutilscodeGenFolder
/
targetSpecific
/_shared
) folder.
Command-Line Information
Parameter:
UtilityFuncGeneration |
Type: character vector |
Value:
'Auto' | 'Shared location' |
Default:
'Auto'
|
Recommended Settings
Application | Setting |
---|---|
Debugging | Shared location
(GRT)No impact (ERT) |
Traceability | Shared location
(GRT)No impact (ERT) |
Efficiency | No impact
(execution, RAM)Shared
location (ROM) |
Safety precaution | No impact |