question

Stephanie Lombard avatar image
2 Likes"
Stephanie Lombard asked Stephanie Lombard commented

Even-Triggered source fires on "Resume Function" of a Time Table that is empty

Hi all,

I am currently building a model to test different scheduling options for operators. Even though there are specific shift times, I must be able to control when operators stop working. They should not just be "scheduled down", but must work until all items received on that day are processed. To do this, I use Time Tables to trigger processflow on "Down Function" and on "Resume Function" with Event-Triggered Sources. I can then control how.when operators are actually scheduled down with the stopobject and resumeobject functions. However, I have come across a problem. If I do not want to use an operator and leave the entire Time Table empty, after a while, the Event-Triggered Source fires on "Resume Function" for that operator even though the time table is completely empty and should not resume.

I have attached a small model ("Test") to demonstrate this. In the model Operator 2 is connected to the Op2 Time Table which is empty. Operator1 is connected to Op1 Time Table which shows operational times between 08:00 and 12:00. I have commented out all code in the "Down Function" and "Resume Function" of the Time Tables so the Time Tables only trigger the processflow. The "Down" Event-Triggered Source fires on "Down Function" while the "Resume" Event-Triggered Source fires on "Resume Function" of each Time Table. I assign a label to each token created called "downobject". I use this label to reference the operator that I later have to schedule down or resume. I put delays between the Event-Triggered Sources and the "Custom Code" activities where I use the stopobject and resumeobject functions to schedule down and resume the operators. I have done this to show that the Event-Triggered Source fires on "Resume Function" for Operator 2 after a while even though the table is empty. I also put the delays to represent activities that the operator has to complete before it is scheduled down or resumed in the model.

You will see I have specified a "Stop Time" (237660) seconds, after which the "Resume" source fires for Operator2 as shown in the highlighted picture below. This is a big problem for me as operators that should not work are resumed. Any ideas as to why this is happening?

All your help is greatly appreciated!

Thank you in advance.

test.fsm

FlexSim 18.2.0
event-triggered sourcetime tables
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

·
Sam Stubbs avatar image
0 Likes"
Sam Stubbs answered

If you switch Op2 table from weekly to "None" you can see that the Weekly table "resets" momentarily after an amount of time which equals a week. This causes the Objects on the Table to instantly reset, but because of this it will fire that ResumeFuncion trigger.

However, if you aren't using the time tables for their actual intended purpose, and you're interfacing with Process Flow anyway, why don't you just use a Scheduled Source to handle you're logic, instead of trying to use Time Table triggers?

· 2
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Stephanie Lombard avatar image Stephanie Lombard commented ·

Hi @Sam Stubbs. Thank you for the explanation and alternative. I understand now. I will look into the idea of using a Scheduled source instead.

Have a great week!

0 Likes 0 ·
Sam Stubbs avatar image Sam Stubbs ♦ Stephanie Lombard commented ·

Okay, let us know if you need help implementing them.

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.