Getting error while setting state under MTBF MTTR function?

Getting error while setting state under MTBF MTTR function?

rajankur6494
Collaborator Collaborator
153 Views
4 Replies
Message 1 of 5

Getting error while setting state under MTBF MTTR function?

rajankur6494
Collaborator
Collaborator

[ FlexSim 23.1.0 ]

Hi Team,

I have made some changes in the regular logic. Here, ports of objects are closed instead using stop function. I am trying to set state of object in this case. I don't know if we can do it. I am getting error as below:

1689680637102.png

Can you help me in this?

Thank you!

0 Likes
Accepted solutions (1)
154 Views
4 Replies
Replies (4)
Message 2 of 5

moehlmann_fe
Enthusiast
Enthusiast
Accepted solution

You are trying to a set a state on the MTBF/MTTR. current generally refers to the object in whose attribute tree the code you are editing is situated (ownerobject(c) -> c is the code's node -> current is the 'owner' of that node).

The object that the down time is applied to is downobject.

0 Likes
Message 3 of 5

rajankur6494
Collaborator
Collaborator
Ok @Felix Möhlmann!

Makes sense.

0 Likes
Message 4 of 5

rajankur6494
Collaborator
Collaborator
Hi @Felix Möhlmann;

One quick question, since we are setting it manually how we can ensure that it will come in the previous state once resumed.

Do I need to write code or will it happen automatically?

Thank you!

0 Likes
Message 5 of 5

jason_lightfootVL7B4
Autodesk
Autodesk
You'd have to set it yourself. But use the resume since then it will do it for you - use the code to release the item from the other post.
0 Likes