Reports for Code Generation - MATLAB & Simulink (original) (raw)

Main Content

The code generator software produces an HTML code generation report so that you can view and analyze the generated code. When you build your model, the code generation process produces an HTML file that is displayed in an HTML browser or in the Model Explorer. For an example, see Generate Code Generation Report.

If you have Simulink® Report Generator™, you can document your code generation project in multiple formats, including HTML, PDF, RTF, Microsoft® Word, and XML. For an example of how to create a Microsoft Word report, see Document Generated Code with Simulink Report Generator.

HTML Code Generation Report Content

The code generation report includes:

HTML Code Generation Report Location

The default location for the code generation report files is in the html subfolder of the build folder,_`model`__ _`target`__rtw/html/._`target`_ is the name of theSystem target file specified on the pane. The default name for the top-level HTML report file isindex.html. For more information on the location of the build folder, see Manage Build Process Folders.

HTML Code Generation Report for Referenced Models

To generate a code generation report for a top model and code generation reports for each referenced model, you need to specify the Create code generation report on the > pane for the top model and each referenced model. You can open the code generation report of a referenced model in one of two ways:

For more information, see Generate Code for Model Reference Hierarchy.

HTML Code Generation Report Extensions

If you have Embedded Coder®, the code generator enhances the HTML code generation report. Configure your model to include these sections in the report:

On the Contents pane, in the Generated Files section, you can click the names of source code files generated from your model to view their contents in a MATLAB® web browser window. In the displayed source code:

Note

To view the contents of your generated code and navigate between model and code, you can also use the Code view in the Code perspective. In the perspective, click the Code tab in the bottom-right corner.

See Also

Topics