ATTENTIONThis FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices. |
flexsim.com |
#1
|
|||
|
|||
"Stacking" Flowitems
Hello everybody,
I'm starting off with a new simulation of a complete production process. We're talking about the processing of metal bars (simplyfied) which pass through 6 different process steps. Every single bar is processed on it's own through all the processes, but the parts are moved and handled batchwise through the plant. There is a rack, which contains 10 baskets (which are stacked on top of each other) and each basket contains 16 metal bars (laying next to each other in the basket). I don't want to go deeper in the automized handling process, because I want to simplify this in the simulation. But how would you realize this stacking process? Because I would like to have the single metal bars as the main flowitems (to get information about the machine in- and outputs, etc)? I hope the description of my problem is understandable. Thank you already in advance! Jens P.S. I'm working with Flexsim v4.32 Last edited by Jens Mühlheimer; 12-09-2010 at 07:50 AM. |
#2
|
|||
|
|||
This post might help, if the bars are moved into 'static' baskets within the rack.
|
#3
|
|||
|
|||
Hi Jason,
thank you for the quick reply. I'm sorry, I used a missleading phrase. With rack, I didn't mean the Flexsim object but an actual "rack" in the production. I already prepared a simple model of it: This rack is designed to hold 10 baskets, which have the right dimensions to fit in this rack and are stacked on top of each other. Each basket holding 16 metal bars. My problem now is that I basically want to have the single metal bars as flow items through all the processes, but between the processes I want to handle the material with these racks (each holding a total of 160 metal bars). Thank you again! Greetings from (cold) Germany! Jens! |
#4
|
|||
|
|||
Aha! Sorry Jens.
In the past I've used a Flexsim Queue which I've then asked an operator to pick up and move to the next process. Then when it's empty I've asked the operator to move it back to an upstream process. Is that what you need? I did that by creating task sequences - I think one was onEntry to detect when a batch had accumulated and another on exit to detect when it would be empty and could be returned. I controlled the flow out of the queue just by closing and reopening the port. When the operator moves the queue back to the model (ie drops it back on the floor) you need to set the correct location - this can be done using a TASKTYPE_NODEFUNCTION which then fires the 'code' node of a usercommand you create (and then find in the /Tools/UserCommands part of the tree). It's been pretty cold here too. I just noticed your location- I used to work in an office in Klein KönigStraße and stayed in Weilimdorf. Fond memories. |
#5
|
|||
|
|||
Hello Jens,
This might be an idea to get you started: Use a visual tool with 10 queues to model your 'racks'. The max content of each queue is 10. Connect the first queue to the second ... to the last queue. This way your rack will be filled layer by layer. If you connect, open and close the input port of the first queue and the output port of the last queue via messaging. You can model the filling up and emptying of your rack. Hope this helps you. Esther |
#6
|
||||
|
||||
I´m even thinking about setting your rack as a new flowitem which you can fill up at a combiner!? This way you can transport the whole rack without using Tasksequences. And using the separator whenever transport is done.
But probably I misunderstood your question.
__________________
Hemmi |
#7
|
|||
|
|||
I agree with Sebastian in that I think we need a clearer definition of what you need. I thought the idea was that these 'racks' were used to handle the material - ie. transport - and that they needed statistics to reflect the bars that flowed through them.
|
#8
|
|||
|
|||
@ Esther: Very interesting idea. I will play around with this.
@ Sebastian / Jason: Also a good idea. Would simplify the model a lot. Which probalby is a good thing, because there will be a lot of meta bar flow items in the model all the time. The rack (from which I showed you the picture) is indeed used as a container more or less between the processes. These racks are moved with electrical pallet jacks from one material handling system of the previous process into the material handling system from the following process. Inside of the process, the metal bars are all processes piece by piece. This is why i would like to use them as the primary flowitems -> like this I think I can get the real data and key figures quite easily. Thank you already in advance! Jens We're having an absolute snow chaos at the moment here ... the complete region around Stuttgart is more or less frozen. Production might stop today because we won't get materials, etc. ... Crazy |
#9
|
|||
|
|||
Hi,
I like the idea of using a rack as a flowitem! When you create a rack with a max content of 160 and set the place in bay and place in level to first available with a max of 16, the rack will fill up nicely as well. Using the combiner and seperator will help you pack and unpack the rack. I made a model (in 4.52 I don't have 4.32) that shows the principle. Esther |
The Following User Says Thank You to Esther Bennett For This Useful Post: | ||
Jens Mühlheimer (12-10-2010) |
#10
|
|||
|
|||
From the rack cell stacking model (linked above) here is the restackrackcell() user command code. I strongly urge you to use version 5 by the way - for the interactive debugger alone it is well worth it to test and verify your code and will likely save you lots of time. There are many other improvements, plus it will help us better support you here.
How to implement: Rack OnEntry and OnExit: senddelayedmessage(current,0,item,rackgetbayofitem (current,item),rackgetlevelofitem(current,item)); Rack OnMessage: restackrackcell(current,msgparam(1),msgparam(2)); User command: restackrackcell Parameters: (obj rack,int bayno,int levelno) Code: /**StackLogic*/ treenode rack = parnode(1); int bayno= parval(2); int levelno= parval(3); int numin=rackgetcellcontent(rack,bayno,levelno); if (numin>0){ treenode item=rackgetitembybaylevel(rack,bayno,levelno,1); double bayloc=rackgetbayloc(rack,bayno); double levelloc=rackgetlevelloc(rack,bayno,levelno); double width=rackgetbaysize(rack,bayno); double depth=get(spatialsy(rack)); double height=rackgetlevelsize(rack,bayno,levelno); int nb=width/xsize(item); int nd=depth/ysize(item); int nh=height/zsize(item); double frontloc=-ysize(rack)+ysize(item); double outside=0; for (int itemidx=numin;itemidx>0;itemidx--){ item=rackgetitembybaylevel(rack,bayno,levelno,item idx); int xpos=fmod(itemidx-1,nb); int zpos=(itemidx-1)/(nb*nd); zpos=fmod(zpos,nh); int row=(itemidx-1)/nb; int ypos=fmod(row,nd); int full=(itemidx-1)/(nd*nb*nh); double outside=0; if (full) outside=full*ysize(rack); setloc(item,bayloc+xsize(item)*xpos,frontloc+ysize (item)*ypos+outside,levelloc+zsize(item)*zpos); if (full) colorarray(item,full); } } |
The Following User Says Thank You to Jason Lightfoot For This Useful Post: | ||
Jens Mühlheimer (12-10-2010) |
#11
|
|||
|
|||
Thank you already for the great replies!
What I also did was to play around with the combiner and separator (look my testfile). I think it's quite similar to Ester's rack model -> Thanks again. I'll probably can combine these two ideas and will have a quite simple way to even include the detail of putting the metal bars in different layers! I got some new information today, that maybe I have to change the size and capacity of the carrier rack over the developtment of the project. With the method mentioned above I think this also could be realized quite quickly because it's really flexible. What do you think? About Flexsim 5 .. I'd love to, but my company only has a license for 4.32 |
#13
|
|||
|
|||
Actually, this is what I had in mind rather than using a fixed resource as a flowitem.
|
The Following User Says Thank You to Jason Lightfoot For This Useful Post: | ||
Jens Mühlheimer (12-13-2010) |
#14
|
|||
|
|||
Jason. I think there may be an error in your model in the User Commands for moving the queues, the node function task gives me an error and the output of the queue does not open up once its moved?
|
#15
|
|||
|
|||
Hi Anthony, if you're using version 5, you'll need to edit the getusercommandnode function (also found in user commands). Comment the line after "Version 4" and un-comment the one for version 5. That should solve it.
Edit: You'll probably want to change the second processor's pull rule to use the port that has "the longest waiting" - that way it will behave more sensibly. Last edited by Jason Lightfoot; 12-10-2010 at 11:57 AM. |
The Following User Says Thank You to Jason Lightfoot For This Useful Post: | ||
Anthony Timmiss (12-15-2010) |
#16
|
|||
|
|||
Quote:
I will also give it a try, if I can realize this like this. I'm not a big expert so far, when I comes to scripting. |
#17
|
|||
|
|||
Quote:
Thanks again for the tip. Another question. How did you create the new flowitem "Rack1" in your model in a way that I still can modify all the object properties? |
#18
|
|||
|
|||
Hello Jens,
I copied a rack via copying tree nodes. First added a rack to an empty model, copied the node from the tree and pasted it into a new flowitem (right click on the new flowitem and select 'explore tree' ). Esther |
The Following 2 Users Say Thank You to Esther Bennett For This Useful Post: | ||
Sebastian Hemmann (12-15-2010) |
#19
|
|||
|
|||
Worked. Great! Thanks!
|
#20
|
||||
|
||||
I haven't been keeping up with this entire thread, but I think you guys got a lot more complicated that you needed to.
You can create copies of the Pallet flowitem in the FlowItem Bin by clicking on it and then hitting New Item. You can edit the 3d shapes of your new pallets to look like your rack and your basket and then use combiners to put all the items together and separators to take them apart. You can also change the processing times and the graphics on the combiners and separators so that they don't look like actual machines. Attached is a simple sample model that shows how this can be done without any code or trickery. |
The Following 3 Users Say Thank You to Phil BoBo For This Useful Post: | ||
Sebastian Hemmann (12-16-2010) |
Tags |
stack flowitems rack |
Thread | Thread Starter | Forum | Replies | Last Post |
Is it possible one object comprised of the function of "combiner" and "separetor"? | Vic Li | Q&A | 1 | 08-19-2008 04:41 AM |
about "no select" and "show parameter window from side bar" | qin tian | Gripes and Goodies | 3 | 03-21-2008 08:10 AM |
Which variable stores "Properties -> General ->Flags -> Protected" information? | KelvinHo | Q&A | 1 | 03-06-2008 06:18 AM |
"Getting Started" and "Tutorial" models for v4.01 | Cliff King | Product Announcements | 0 | 12-10-2007 07:34 PM |
Fluid "Pallet" Flowitems | Maurits Brandt | Q&A | 4 | 11-12-2007 12:37 PM |