Simulink® Coverage™ measures code coverage and indicates the untested elements of your design. You can collect coverage for the C/C++ code in supported model elements, MATLAB® Function blocks, or the code generated from models in software-in-the-loop (SIL) mode or processor-in-the-loop (PIL) mode. Simulink Coverage measures several types of code coverage analysis, such as statement, condition, decision, and modified condition/decision coverage.
This example model explains how Model Coverage relates to MATLAB code inside a MATLAB Function Block.
Record coverage for models with a combination of code blocks and other Simulink blocks.
Analyze model coverage for C/C++ S-Functions.
Configure code coverage for SIL and PIL simulations and review results.