How to Pause Tokens in Delay Activity Using Time Table in FlexSim?

How to Pause Tokens in Delay Activity Using Time Table in FlexSim?

timur_yeshimov
Explorer Explorer
79 Views
4 Replies
Message 1 of 5

How to Pause Tokens in Delay Activity Using Time Table in FlexSim?

timur_yeshimov
Explorer
Explorer

I’m working on a simulation where products are delayed in queues and processed by processors. I’ve implemented a time table to stop items from continuing through the model during certain time intervals.

 

This works as intended for queues placed before processors—the time table successfully prevents items from moving forward. However, for queues that contain delays, the tokens do not stop—they continue through the delays even when the time table is inactive.

 

I tried to implement the solution provided in this post:

Solved: How to Pause the delay token in process flow by using time table - Autodesk Community

 

However, the down function and the resume function suggested there do not work in my case.

 

I’m wondering how I can correctly apply the time table to also pause tokens that are inside Delay activities, and ensure they only resume processing when the time table allows it.

 

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

timur_yeshimov
Explorer
Explorer

@moehlmann_fe 
Could you please help me with this one?

0 Likes
Message 3 of 5

moehlmann_fe
Observer
Observer

You are using a General Process Flow, not an Object Process Flow. Thus, you are setting the "ActiveToken" label on the Process Flow itself, since that is what "current" refers to in that case. You need to use the "Destination" label instead which you use to refer to the queues.

Furthermore, there can be more than token per queue, so the label needs to be an array that contains all active tokens.

Message 4 of 5

timur_yeshimov
Explorer
Explorer

Thank you for your solution.
I noticed that when the processor's time table is disabled, the processor before the delays continues to send items into the delay subflow. These items pass through the delays without being stopped by the time table. Only the tokens that are already at the delay point are stopped.
I'm wondering how I can make it so that the tokens are still able to enter the delay subflow under these conditions?

0 Likes
Message 5 of 5

moehlmann_fe
Observer
Observer
Accepted solution

I guess you would need to add a check that looks up the queues state when an item enters the zone. If it's stopped, the token is also stopped immediately (after adding it to the active tokens array, so it gets resumed when the downtime ends).

An item being moved into the queue will update its actual state to "releasing", so I would just use a label to denote whether the queue is down or not.