필터 지우기
필터 지우기

How can I solve enumerated value access error in Matlab ?

조회 수: 10 (최근 30일)
Geethika
Geethika 2022년 3월 14일
답변: Benjamin Thompson 2022년 3월 14일
Hi, I am trying to test a simulink model using customised test manager script, but facing the below error for few models :
"The action could not be completed due to the following error(s):
An error occurred during simulation of Model block 'xxx_Harness1/xxx_tst'.
'xxx_tst/Data Type Conversion' attempts to access enumerated value with underlying value 2047 from enumerated data
type '<enumtype>' but this data type does not have an enumerated value with this underlying value
The input signal(s) of 'xxx_tst/Data Type Conversion' are not being successfully converted from type 'double' to
'<enumtype>'
No data is logged for the model 'xxx_Harness1'."
I have observed that the inputs given is within the range and it doesnt contain a value 2047, also the required datatype conversion is done in the model, but still is throwing this error. Any feedback is appreciated.

답변 (1개)

Benjamin Thompson
Benjamin Thompson 2022년 3월 14일
If your enumerated type does not have a value for 2047, and you try to convert an input value of 2047 into the enumerated type, then there is a problem. Can you post an example model showing the error? What 2047 is the input, what should the output be?

카테고리

Help CenterFile Exchange에서 Outputs에 대해 자세히 알아보기

태그

제품


릴리스

R2017b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by