question

Skovdestudents avatar image
0 Likes"
Skovdestudents asked Skovdestudents commented

Get ProcessTime left from processor

Hello I have a problem im trying to simulate.

I have a queue that should send items to one of the connected queues depending on content and time left in processor. See image:1681384720150.png

Queue3 and Queue1 are very small and sometimes both are empty and Queue5 should send the item depending on how much process time that is left in one of the processor.

I.E Processor1 have 1 minute left and Processor2 have 3 minutes left but both Queue3 and Queue1 is empty, I want Queue5 to choose Queue3 connected to Processor1 because of amount of ProcessingTime left.

Any ideas how I can read any variable from the object to achieve this?


Kind regards

FlexSim 23.1.0
processtime
1681384720150.png (54.0 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 Skovdestudents commented

The only place you can find the finish time is the event list. You could loop through all model events until you find the correct one.

1681387167112.png

But I would instead suggest to write the finish time to a label in the code of the process time field.

1681387150855.png


1681387150855.png (40.9 KiB)
1681387167112.png (5.8 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.

Skovdestudents avatar image Skovdestudents commented ·

Works like a charm! Big thanks!

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.