question

Kshitij Dhake avatar image
0 Likes"
Kshitij Dhake asked Kshitij Dhake commented

Send flow item to processors with preference in a conveyor

I want to send the flow item to the processors. Processor 3 gets the preference and the I am using the decision points as a waiting area for flow items.
How can this be done using a basic approach ? The code which I have is not working Sample Conveyor.fsm

FlexSim 22.0.16
conveyance
sample-conveyor.fsm (45.5 KiB)
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

Felix Möhlmann avatar image
0 Likes"
Felix Möhlmann answered Kshitij Dhake commented

My preferred option is almost always to use Process Flow. The big advanted you have in this case, is that you can simply keep the item stopped until a processor can be acquired and then later release the processor once the item has finished processing.

sample-conveyor_1.fsm

Your approach can also work though. It just needs some way to identify which processor is available. For example by using labels on the processors that can be checked in the On Continue code of the DP.

sample-conveyor_2.fsm


· 9
5 |100000

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

Kshitij Dhake avatar image Kshitij Dhake commented ·

Thank you. Once the token is acquired by the resource why are we using send item on the conveyor ? and what is processor.inObject[1]?1727705640666.png

0 Likes 0 ·
1727705640666.png (5.2 KiB)
Felix Möhlmann avatar image Felix Möhlmann Kshitij Dhake commented ·
Once we know which processor the item should go to it needs to be routed to the respective exit transfer. This is done by sending the item to it. The exit transfer is referred by the expression "token.processor.inObjects[1]" (the object connected to the first input port of "token.processor").
0 Likes 0 ·
Kshitij Dhake avatar image Kshitij Dhake commented ·
I am using this process flow , however in my model, the item is alternating between 2 processors. Do you know why that might be happening ? The item should always go to the processor on the right
0 Likes 0 ·
Felix Möhlmann avatar image Felix Möhlmann Kshitij Dhake commented ·
In your original question you wrote that Processor3 is the "preference". That is what is implemented in the Process Flow. If both processors are available, the item will go to processor3. If another item arrives before the first one finished, it will be routed to the other processor.
0 Likes 0 ·
Kshitij Dhake avatar image Kshitij Dhake commented ·

Is that implemented by the ORDERBY. For some reason, That is not how my model is working

0 Likes 0 ·
Felix Möhlmann avatar image Felix Möhlmann Kshitij Dhake commented ·
Yes. The query statement orders the processors by value of their "Priority" label. I guess you might have missed to add those labels?
0 Likes 0 ·
Kshitij Dhake avatar image Kshitij Dhake Felix Möhlmann commented ·
yes. I have not added labels ? How do I add them ? In your case why is priority 5 and 10 ?
0 Likes 0 ·
Show more comments
Kshitij Dhake avatar image Kshitij Dhake commented ·
Thank you so much @Felix Möhlmann. The model is working now
0 Likes 0 ·