question

Ander GMN avatar image
0 Likes"
Ander GMN asked Jeanette F edited

Output

Hi,

I am trying to configure a processor´s output "send to port" option without much success. Between two different possible destinations, I would like that the object went every time to the same one port, except for when this is occupied. It would be interesting too that it went to the nearest available port, taking into account the different port´s physical distance in the model.

I hope to have explained myself sufficiently good, thank you in advance,

Ander

FlexSim 21.1.1
flexsim 21.1.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.

1 Answer

·
Jeanette F avatar image
0 Likes"
Jeanette F answered Jeanette F edited

Hello @Ander GMN,

I would select the drop down option first available. You can set triggers on the queues to close and open their input port when it is occupied or unoccupied.

For the distance, I would start with the drop down option of shortest queue size. Open the code to edit it. Try and capture what was previously done for the shortest queue and rewrite for the shortest distance. The following code will be helpful to you. It finds the coordinates of the queue relative to the processor.

Vec 3 pos = current.outObjects[index].getLocation.project(model(), current);


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.