MATLAB Answers

2

Why the Model Advisor does not flag Switch Case blocks that do not use integer data types or enumeration values for inputs?

Asked by Xiaojie Qiu on 5 Dec 2018
Latest activity Answered by Jerry George on 18 Jun 2019
Hi everyone,
I am using the Model Advisor to check my model in order that it complies with functional safty standards (e.g. ISO26262).
The figure below shows a simple overview on the model. As you can see, the data type of the input is single.
According to the Rule hisl_0011 described below (click the hyperlink for more details about the rule), the input signal to a Switch Case block must be an integer or an enumeration value (see Description C). It means that the data type of the input signal in my model is NOT compliant with this rule. Therefore, in my opinion, the error in my model should be displayed after running the check (By Task > Modeling Standards for ISO 26262 > High-Integrity Systems > Simulink > Check usage of Ports and Subsystems Blocks)
However, after checking the model against this rule, I got the result as shown below reporting that the check passed.
The reason is that the Model Advisor DO NOT check whether the input data type is an integer or an enumeration value. Only when I click the button Help, I get the information saying that the check does not flag Switch Case blocks that do not use integer data types or enumeration values for inputs.
So my questions are now:
1) Why does the Model Advisor not flag this error?
2) Can I draw a conclusion that all check results reported by the Model Advisor are not reliable, although we get Passed?
3) Is it possible to add this informaiton to the Model Advisor dialog window and to the modeling guidelines in order to remind users of issues that the Model Advisor is not able to check?
Thank you!
qxj

  1 Comment

+1. Good question. Please forward this to the Mathworks tech support or submit an improvement request.

Sign in to comment.

Products


Release

R2018a

1 Answer

Answer by Jerry George on 18 Jun 2019
 Accepted Answer

This issue has been fixed in MATLAB R2018b.

  0 Comments

Sign in to comment.