coder.mapping.api.get
Syntax
Description
returns the active code mappings for the specified model as object
myCodeMappingObj
= coder.mapping.api.get(model
)myCodeMappingObj
. Code mappings associate model data elements with configurations for code generation. If a
model has multiple code mappings, the active code mappings are the mappings associated with
the active system target file.
If code mappings do not exist, Simulink® returns an error. Simulink creates a code mappings object when you open a model in a coder app. If you
have not opened a model in a coder app, you can create a code mappings object with a call to
coder.mapping.util.create
.
returns the active code mappings for the specified dictionary as object
myCodeMappingObj
= coder.mapping.api.get(dictionary
)myCodeMappingObj
. Code mappings associate data elements in the data dictionary with configurations
for code generation.
If code mappings do not exist, Simulink returns an error. Simulink creates a code mappings object when you open a model in a coder app. If you
have not opened a model in a coder app, you can create a code mappings object with a call to
coder.mapping.util.create
.
returns the code mappings for your model that correspond to the specified code mapping type
as object myCodeMappingObj
= coder.mapping.api.get(model
,codeMappingType
)myCodeMappingObj
. Code mappings enable you to associate a model
with code generation configurations for C rapid prototyping (Simulink
Coder™ and C language) and C production (Embedded Coder® and C language) platforms. The code mappings type specifies your platform of
interest. If a code mapping of the specified type does not exist, Simulink returns an error.
Examples
Input Arguments
Output Arguments
Version History
Introduced in R2020b
See Also
coder.mapping.api.CodeMapping
| coder.mapping.utils.create
| coder.mapping.api.CoderDictionary
| coder.mapping.api.CodeMappingCPP
(Embedded Coder)