Main Content

Code Interface Definitions

Create data, function, and memory section code generation definitions for standardization and software architecture conformance

In a large organization, you can help multiple people generate code that conforms to a general software architecture. Create code generation definitions that those people can use to control the appearance of model data (signals, parameters, and states) and functions in the code.

Classes

coder.DictionaryConfigure Embedded Coder Dictionary
coder.dictionary.SectionConfigure Embedded Coder Dictionary section
coder.dictionary.EntryConfigure Embedded Coder Dictionary definition

Functions

coder.dictionary.createCreate Embedded Coder Dictionary and coder.Dictionary object
coder.dictionary.openOpen Embedded Coder Dictionary object
coder.dictionary.copyCopy code generation definitions between models and data dictionaries
coder.dictionary.moveMigrate code generation definitions between models and data dictionaries
coder.dictionary.removeRemove Embedded Coder Dictionary from model or Simulink data dictionary
coder.dictionary.existDetermine whether Embedded Coder Dictionary exists in model or data dictionary

Tools

Embedded Coder DictionaryCreate code definitions, which control code generation for model data and functions

Topics

Separation of Code Definitions from Model-Specific Data and Function Configurations

Package software architecture definitions used by the code generator to produce code for a model separately from model design.

Define Storage Classes, Memory Sections, and Function Templates for Software Architecture

Create code generation definitions that you and others can use to control the generated code.

Flexible Storage Class for Different Model Hierarchy Contexts

Define and apply a storage class that uses different code generation settings for single-instance data and multi-instance data.

Create Code Definitions Programmatically

Configure Embedded Coder Dictionary programmatically.

Deploy Code Generation Definitions

Make code generation definitions, such as storage classes and function templates, available to people who need them.

Manage an Embedded Coder Dictionary

Update code definitions and manage the use of Embedded Coder Dictionaries.

Conform to Software Architecture by Sharing and Copying Default Code Generation Settings Between Models

For new and existing models, standardize the generated code across an organization by sharing and copying default code generation settings.

Access Data Through Functions by Using Storage Classes in Embedded Coder Dictionary

Use storage classes and Coder Dictionary Defaults to integrate the generated code with legacy code that uses specialized functions to read from and write to data.

Access Data Through Functions with Storage Class GetSet

Use the storage class GetSet to integrate the generated code with legacy code that uses specialized functions to read from and write to data.

Create Storage Classes by Using the Custom Storage Class Designer

For additional control of data representation in the generated code, create storage classes.