Simulink Verification and Validation
This example shows how to use the dialog box for coverage settings to enable coverage for a Simulink® model and adjust the type of information that is reported.
sldemo_clutch example model model that ships with Simulink provides a good introduction to model coverage. This model contains several blocks that have intrinsic decisions, places where control flow can take more than one path.
To open the Coverage Settings dialog box, from the Simulink Editor, select Analysis > Coverage > Settings.
To enable coverage reporting, select Coverage for this model. This setting enables the other options in the Coverage Settings dialog box.
The Coverage metrics group controls the types of coverage information that is collected during simulation. Selecting all coverage metrics provides the most coverage information. For this example, select Decision, Condition, MCDC, Signal Range, and Lookup Table.
Click OK to apply your selected settings and close the Coverage Settings dialog box.
Once you enable coverage collection for your model, coverage information is automatically recorded when you simulate the model. At the end of the simulation, the model coverage tool produces an HTML report of coverage information that displays within the built-in MATLAB® web browser.