question

Joey A avatar image
0 Likes"
Joey A asked Jason Lightfoot commented

Why is conditional decide not working

Hi,

I'm trying to control an AGV with a decide instead of the list that comes with the template (this can be a long story but please roll with it :) ). I believe I've set up my "Loading_Work_Exists" decide in the main control loop correctly. However, the tokens are passing the test when clearly the conditions aren't being met.

Do you know why this is happening?

thank you!

AGT Simulation 7 create tokens.fsm

FlexSim 23.0.5
listsconditional decidelist statistics
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

Jason Lightfoot avatar image
0 Likes"
Jason Lightfoot answered Jason Lightfoot commented

First of all the condition can't have the word AND in it - you should use && instead.

Then you're using List("IB Staging to AGV Queue") but that creates a reference to a global list - while the one in your process flow is local.

I would instead try to pull from the list with a timeout so that if there are no entries the token does your loop and if there are entries - you have another decison that checks if token.cp.name=="ControlPoint1".

Now whether you should be doing any of this is another discussion - but in relation to the decison activity that will probably be the easiest way to implement what you seem to be trying.

agt-simulation-7-create-tokens_jl.fsm


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