wait for an event by condition

wait for an event by condition

myriam_srdg
Not applicable
18 Views
7 Replies
Message 1 of 8

wait for an event by condition

myriam_srdg
Not applicable

[ FlexSim 22.1.0 ]

Hello,

I've created an object process flow, that triggers when a box covers a PE. Based on some conditions, the box stops or sinks. The box resumes when a model variable reaches a threshold. I've managed to resume the object after a time, but I'm don't know how to write a variable-based condition.


1648741561674.png

Thank you,

0 Likes
Accepted solutions (1)
19 Views
7 Replies
Replies (7)
Message 2 of 8

marcello_rosadini
Not applicable

Hi Myriam,

probably the easiest way is by using a label on the item.

Hope this model can help

support mondragon.fsm

0 Likes
Message 3 of 8

Jeanette_Fullmer
Community Manager
Community Manager
Accepted solution

Hello @Myriam Srdg

I wrote two examples of a decide conditionally examining a variable. One is a global variable. The other is a tracked variable.

Varaible_Based_Condition_JF.fsm

0 Likes
Message 4 of 8

myriam_srdg
Not applicable

Thank you both for the examples. I think I didn't express myself correctly or I'm not able to interpret them right. I achieved to make a decision based on a variable. What I'm struggling with if with resuming the item once the condition that made it stop changes. In the example that I upload, what I want to stop the object in the first PE and only resume it when the number of items between the PEs is less that 2.

varaible-based-condition-jf-ms.fsm

Thank you

0 Likes
Message 5 of 8

Jeanette_Fullmer
Community Manager
Community Manager

Hello @Myriam Srdg,

This will work if you use a tracked variable instead of a global variable. The tracked variables can be referenced in a wait for event.

1648849210983.png

varaible-based-condition-jf-ms_1.fsm

Message 6 of 8

myriam_srdg
Not applicable
Thank you very much! Discovering tracked variables was awesome ))


0 Likes
Message 7 of 8

myriam_srdg
Not applicable

Hello @Jeanette F,

Is there a way to wait until an event (as in the example) but with 2 tracked conditions? I have to decides and I want to resume when one or the other condition is met.

1648978355582.png


Thank you!

Myriam

0 Likes
Message 8 of 8

Jeanette_Fullmer
Community Manager
Community Manager

Hello @Myriam Srdg,

You would need a wait for event for each variable. In the model provided you can see how I implemented this.

varaible-based-condition-jf-ms-2.fsm

0 Likes