question

Nouf avatar image
0 Likes"
Nouf asked Joerg Vogel commented

queue send to port if label is met or after 10 minutes.

Hello,

I need your assistance with this project. I am currently facing an issue with the "South_Gate1" queue, as you see in the picture. What I am trying to do, is to make the operator only takes the bags if two conditions are met, the first one is if "pid" the label on the queue reaches 25, or if it's been ten minutes, in case if the "pid" didn't reach 25.

Note: "pid" represents the number of a different group of bags.

pic.jpeg


Can you help me?

SLHS_Level7_Updated_Ver2_autosave.fsm

FlexSim 20.2.3
queueoperatorset labeltimerqueue items
· 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 @Nouf , was Joerg Vogel's answer helpful? If so, please click the red "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 unaccept and comment back to reopen your question.

0 Likes 0 ·

1 Answer

Joerg Vogel avatar image
0 Likes"
Joerg Vogel answered Joerg Vogel commented

you have two conditions. The timed event will be fulfilled if the other does not happen before. This means you must create an event that happens always in the future wether it is valid or not. You can send a delayed message and evaluate this message if the condition is still active to get fulfilled. Other events are an user event, a delayed process flow. You can test this timed event if it is valid by checking if a label value is still unchanged, an item is still not be moved from an object, then this timed event will do this conditional action. The other condition can happen if a content of “South_Gate1” queue reaches on an entry event the value of 25. You can evaluate the statistical content or the subnodes length of this object. If this happens you change the test label value, which will prove later that this conditional content event has not happened before.
subnodes length:

https://docs.flexsim.com/en/20.2/Reference/CodingInFlexSim/FlexScriptAPIReference/Tree/treenode.html#Property-subnodes

· 4
5 |100000

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

Nouf avatar image Nouf commented ·

Thank you for your answer! But I am sorry, I didn't get what are you trying to say. Can you please explain visually?

0 Likes 0 ·
Joerg Vogel avatar image Joerg Vogel Nouf commented ·

sure:react-on-time-or-on-content-change.png

0 Likes 0 ·
Matheus A5 avatar image Matheus A5 Joerg Vogel commented ·
Can you send this logic in a Custom code reference?
-1 Like -1 ·
Show more comments