Structure Definition for Code Generation - MATLAB & Simulink (original) (raw)

Main Content

To generate efficient standalone code for structures, you must define and use structures differently than you normally would when running your code in the MATLAB® environment:

What's Different More Information
Use a restricted set of operations. Structure Operations Allowed for Code Generation
Observe restrictions on properties and values of scalar structures. Define Scalar Structures for Code Generation
Make structures uniform in arrays. Define Arrays of Structures for Code Generation
Reference structure fields individually during indexing. Index Substructures and Fields
Avoid type mismatch when assigning values to structures and fields. Assign Values to Structures and Fields

MathWorks - Domain Selector

Select a Web Site

Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .

You can also select a web site from the following list

How to Get Best Site Performance

Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.

Americas

Europe

Asia Pacific

Contact your local office