Using sub-models for sequential stations

Using sub-models for sequential stations

clairekruppGhafari
Collaborator Collaborator
301 Views
1 Reply
Message 1 of 2

Using sub-models for sequential stations

clairekruppGhafari
Collaborator
Collaborator

I am playing around with the new sub-models feature to see how I would use it. One possibility I am looking at is a model that uses robots to move car body panels from station to station in an assembly line. I wondered how I would set up each station-and-robot cell as a sub-model to enable a modular approach to developing the line.

I started by copying Jacob White’s sub-model demo from the FlexSim Summit last month (Mar 2026), so now I have a container with one station, an inbound queue with a load robot and an outbound queue with an unload robot.

clairekruppGhafari_0-1775767309080.png

 

I set it up as a sub-model export as shown. (Side-note: I did not create the AGV Network – it appeared when I created the sub-model. Can you tell me why it is there?)

 

So then I created the Main model and imported two sub-models:

clairekruppGhafari_1-1775767309091.png

 

I also added the next step, which is a rack loading station feeding a conveyor, for which I plan to use a 3D combiner.

 

The first problem is that in Jacob's model the sub-model stations don't need to interact with each-other, but in my model these container cells need to be sequential, so the outbound queue from one cell is the same physical object as the inbound queue from the next cell. I can A-connect the two queues and change the Output choice to “First Available”, and then if I place both queues in the same place it looks like a single staging location. So that’s a little bit clunky but it works.

But in reality, there are no staging locations between stations, so I want the robot to move the item directly to the next station. How do I tell the robot to move to a location that is outside the container of the current sub-model? Perhaps I can use another Label on the Container? Then each sub-model would only need to have one robot and one queue?

 

Then at the end of the line, I want the robot to move the item to the combiner, but the combiner has to control the sequence in the Input logic, so maybe that robot cannot be in a sub-model? I set it up with a standalone robot which is controlled by a little bit of Process Flow, but I’m not sure what will happen at the combiner if there is no rack in place before the robot tries to unload the item.

 

I am coming to the conclusion that this is not a great example of using sub-models, since it would be just as easy to set up the stations and the robots directly, but I do think that there will be many cases where sequential flow from sub-model to sub-model is needed, so I welcome any discussion on this subject.

 

Thanks!

 

Here are the two models, though I can’t guarantee that the Main model is going to always work at the combiner!

0 Likes
Accepted solutions (1)
302 Views
1 Reply
Reply (1)
Message 2 of 2

clairekruppGhafari
Collaborator
Collaborator
Accepted solution

Update: I have continued to improve on my sub-model and answered my own questions!

 

In order to move items from one sub-model to the next without using queues I copied Jacob's idea and set up a label called "OutLoc" on the container in the sub-model:

 

clairekruppGhafari_0-1776179473752.png

(The "CTrow" label is for use in the cycle-time table, so that each station/cell can read a different row.)

 

Then in the main model I can update the label on each station/cell and use it to control where the item goes next. If you are using Process Flow for control, then you can set a label on your token that gets its value from the label on the container and then use that for your routing control. And If I want to give this to a beginner modeler who does not know any Process Flow, I can use it in the Output control for the Station:

clairekruppGhafari_1-1776179748911.png

 

However, that is not enough to make the item move - you have to ALSO A-Connect each Station/cell to the next one. In fact, I then discovered that it does not matter if you forget to set up the Output control as above, the ONLY thing you need to do is A-Connect the sub-model containers and the item is transported by the robot to the next cell, exactly as I wanted. So it's actually much easier than I expected!

 

The other aspect that was a problem was the CT Table. You have to set it up as a Global Table in the sub-model and then include it in the dependencies so that it shows up in the Main model, but if you then add rows in the Main model so that each station has a different CT, you will get an error next time to want to "Update Instances from Source" after editing the sub-model. You can only overwrite the table, and then you would have to recreate the new rows. To get around this I found a solution in this Question on this Forum: 

 

https://forums.autodesk.com/t5/flexsim-forum/integrating-a-sub-model-for-patient-arrivals/m-p/140512...

 

The solution is to use the Parameter Table (in the sub-model) to hold the name of the Global Table (use Type: Expression),

 

clairekruppGhafari_3-1776181834211.png

 

and then you can create a second table in the Main model and just change the value in the Parameter Table to read the correct one.

 

So then the Cycle time for the Station uses "Model.parameters.CT_Table" for the name of the Global Lookup Table:

 

clairekruppGhafari_2-1776181117346.png

 

The last little wrinkle was how the Combiner would work if the Output from the last station was pushing to it. I discovered that all I have to do is A-Connect the last cell to the combiner and the combiner controls whether it gets a rack or a part by opening and closing its ports, so that was very easy too. That means I no longer need the Process Flow "LoadMainLine" and so I disabled it.

 

So now I have a nice way to build up a sequence of cells with robot MH very quickly. (I also included a 3D trigger that moves the robot arm back to the load location when it has finished unloading so that it is more efficient.)

 

clairekruppGhafari_0-1776183707540.png

 

Feel free to download and copy as needed. If you are not using robots, you can just substitute an operator instead, I think it will work just fine.

0 Likes