question

Adrian M avatar image
0 Likes"
Adrian M asked Jeanette F commented

Task Sequence Example

Hello, I have a model running with multiple shifts with multiple objects being processed at one time on the processor. All of my processors are connected to a dispatcher with a center port which I referenced within the Operator field; however, when I ramp up production (increase inputs) I will eventually need to add more shifts for specific operators like assemblers, testers, inspectors, and so forth.


I'd like to understand what the difference is between reference the center port connected to a dispatcher (current.centerObjects[1]) vs. a Task Sequence Example? Also, does the Task Sequence Example still reference the dispatcher I have connected with a center port on that certain processor; therefore, allowing the dispatcher to still handle which tasks should be handed out depending on which shift is active?


Another thing to add, when I kept my Operator reference to current.centerObjects[1] I experienced something similar to this post where my processor seems like it is stuck when I know I have a sufficient amount of operators implemented in the model.

Processor Waiting for Operator but Operator is Stuck - FlexSim Community

Machine waiting operator already utilized - FlexSim Community


I did receive some assistance in Machine waiting operator already utilized - FlexSim Community, but an error occurred (please see below). I suspect it's because I have objects finishing at the same time on the processor, so if I can have the updated code for this issue, then that would be great.

What I was provided:

1716396123290.png

The error after implementing:

1716396174904.png


I have version 23.0.2.


5/22/2024 11:56am ---


After running the model with the Task Sequence Example referenced in the Operator field, the operator that looks like is assigned to the processor to process the item now has a state of travel empty instead of utilize. Is there a way to fix this?

1716404127322.png


Thank you,

FlexSim 23.0.15
process flowdispatchertask sequence example
1716396123290.png (150.1 KiB)
1716396174904.png (39.2 KiB)
1716404127322.png (12.1 KiB)
· 1
5 |100000

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

Jeanette F avatar image Jeanette F ♦♦ commented ·

Hi @Adrian M, was Felix Möhlmann'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.

0 Likes 0 ·

1 Answer

·
Felix Möhlmann avatar image
0 Likes"
Felix Möhlmann answered

The error is probably caused by line 38. The code assumes that the dispatcher object is the operator working on the item in that line. Though that line is not actually needed and you should just be able to remove it.

I tried to fix the issue with items finishing at the same time in the attached file. I search the event list for the event time of the next item on the processor. If the time is equal to the current model time, no new task sequence is created.

Be aware that this code was mostly build under the assumption that the dispatcher is a single, fixed operator. It should still work with an actual dispatcher connected to multiple operators. Though depending on the dispatcher settings the operator working at the processor might change when an item finishes processing without the processor stopping until the new operator has arrived.

Overall, using Process Flow to dispatch an operator to the processor might be easier at that point.

workaround-sametimefinish-fm-23-0.fsm

As the description of the "Task Sequence Example" option states, it does the same that normally happens when you simply reference a task executer. It is meant as for learning and as a starting point for customizing the logic to suit ones needs.

"This example shows the code that is required to create the exact same tasksequence
that is normally created automatically and dispatched to the object referenced by this field."


5 |100000

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

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.