Hi Team,
This is surprising for me to see that closeinput() command is not working on model reset trigger while it is working on object reset trigger.
Could you help me to resolve it?
Closeinput while model reset.fsm
Thank you!
Hi Team,
This is surprising for me to see that closeinput() command is not working on model reset trigger while it is working on object reset trigger.
Could you help me to resolve it?
Closeinput while model reset.fsm
Thank you!
Hi @Ankur A3, was Regan Blackett's answer helpful? If so, please click the "Accept" button at the bottom of their answer. Or if you still have questions, add a comment and we'll continue the conversation.
If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always comment back to reopen your question.
Jorg is correct. One of the things that Objects do upon resetting the model is to open their own ports. It's why an input port connection turns from red to green when you reset the model.
The Model Reset trigger appears to happen before Objects open their own ports. If you put in a break point at the call to closeinput() and step through the code, you will see that the port gets closed properly, but when the trigger ends to the ports are reopened when the objects open their ports as part of their reset.
If you want to close ports on reset, you should either use the individual object On Reset trigger or you can use the statement
await Delay.seconds(0);
to put a zero seconds delay before the closeinput() call so that it executes after the other events that happen on reset.
11 People are following this question.
FlexSim can help you understand and improve any system or process. Transform your existing data into accurate predictions.
FlexSim is a fully 3D simulation software environment. FlexSim can be used to simulate any process in any industry.
FlexSim®, FlexSim Healthcare™, Problem Solved.®, the FlexSim logo, the FlexSim X-mark, and the FlexSim Healthcare logo with stylized Caduceus mark are trademarks of FlexSim Software Products, Inc. All rights reserved.
Privacy | Do not sell or share my personal information | Cookie preferences | Report noncompliance | Terms of use | Legal | © Autodesk Inc. All rights reserved