question

Jimmy G2 avatar image
0 Likes"
Jimmy G2 asked Jimmy G2 commented

Round Robin Labels

I'm trying to distribute "type" labels to tokens via round robin to distribute work to operators who will then pull these objects from a Queue. I have it working now with a 50-50 by percentage distribution but it'd be ideal if the tokens alternated between Queue locations. I tried using the custom code that's been posted in the past, but I can't get it to work.. I've attached my example piece, both with the custom code and with the percentage distribution. Thanks in advance

rr-ball-example.fsm

FlexSim 18.2.3
assign labels
rr-ball-example.fsm (26.6 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

·
Sam Stubbs avatar image
1 Like"
Sam Stubbs answered Jimmy G2 commented

The code you put in works well for a 3D object, but for a Process Flow activity you should use "activity" instead of "current." The code has been updated as well to utilize dot syntax. The new round robin assignment code could looks something like this:

((activity.as(Object).stats.input.value-1)%2)+1

rr-ball-example-1.fsm


· 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.

Jimmy G2 avatar image Jimmy G2 commented ·

Thank you!

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.