question

gust-flex avatar image
0 Likes"
gust-flex asked Jeanette F commented

Limit the items on a gravity flow rack

I want to limit the items in my gravity flow rack. I only want to items per slot in my rack. I tried to customize the code of "Slot Assignment Strategy" but it didn't work:

1712327425506.pngCan someone help me?

FlexSim 23.1.2
itemsracking
1712327425506.png (72.4 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 @gust-flex, 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 Felix Möhlmann commented

Did you add the "items" label to the slot. Because that's not a default expression. Other than that the code looks like you are trying to count the amount of items of a specific type in the slot. But due to the matching labels condition items with a different type can't be in the slot in the first place, no?

You can check how many items are assigned to a slot through the slotItems property of the slot class. So to limit the total quantity per slot you would just add "slot.slotItems.length < 2" to the condition.

1712333053111.png


1712333053111.png (8.3 KiB)
· 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.

gust-flex avatar image gust-flex commented ·

If I add the "slot.slotItems.length <2" it still doesn't work.. here is my testfile.

test-simulation-flowrack-fm.fsm

0 Likes 0 ·
Felix Möhlmann avatar image Felix Möhlmann gust-flex commented ·

The slot is assigned in Process Flow, so that's where you have to add the condition.

1712336125689.png

0 Likes 0 ·
1712336125689.png (16.8 KiB)