Check the number of function calls in MATLAB Function blocks
JMAAB v5.1 na_0017: Number of function levels
JMAAB v6.0 mp_0025: How to call functions
Checks whether number of function calls in MATLAB® Function blocks is less than the set threshold. By default, the limit is set to three.
This check requires a Simulink® Check™ license.
This Model Advisor check is not applicable for JMAAB modeling guidelines.
This check does not include sub-checks
For reference, the MAB guideline sub ID(s) that are recommended for use by the NA-MAAB and JMAAB modeling standards organizations are:
NA-MAAB — a
JMAAB — a
You can customize the function call levels threshold by using the input parameter Function Call Level from the Model Advisor Configuration Editor.
Open the Model Configuration Editor and search for check ID
Enter the desired function call level to set in the Function Call Level field.
By default, this parameter is set to 3.
Click Apply and save the configuration.
Results and Recommended Actions
|Number of function calls in MATLAB Function blocks is greater than the set threshold. By default, the set threshold is three. The set threshold can be modified by using the input parameter Function Call Level in the configuration editor.||Reduce the number of function calls from MATLAB Function blocks to be less than the set threshold.|
Capabilities and Limitations
This check also implements the JMAAB v6.0 guideline: mp_0025
Recursive function calls are only counted once.
Inline class methods are not analyzed.
Runs on library models.
Allows exclusions of blocks and charts.
Analyzes content in masked subsystems. By default, the input parameter Look under masks is set to
Analyzes content of library-linked blocks. By default, the input parameter Follow links is set to
JMAABv6.0 guideline mp_0025