question

Håkon L avatar image
0 Likes"
Håkon L asked Felix Möhlmann commented

Combiner - Input, output and processing challenge

Hi, I've posted several posts about this or similar problems already, and I have since last week been trying to use the different suggestions and solutions provided by several of you in my model, without prevail.

My challenge is the combiner (M57) in my simulation. The challenge is:
*Differentiate between components who shall only be prossesed, and those that are supposed to be joined.
*Input of the components who are to be joined.
*Output to the right Queues based on the component ID.
*Different processing times.

Several of the above challenges I have been able to solve in other "example-simulations",for instance output by case, output and processing times by globaltable lookup... However, when I try to do the same thing in this (included in post)simulation, I get errors all day long.

Can somebody please take a look at my simulation and kindly adresswhere the problem lies - and why?

In advance - many thanks!

JobShopRoute V0.81.fsm

FlexSim 22.2.2
combineroutput portprocessing times
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

·
Felix Möhlmann avatar image
1 Like"
Felix Möhlmann answered Felix Möhlmann commented

- A combiner can't pull from a list, because the input port rank is important. So BUFFER_039940 pushing its items onto list does not make them available to the combiner. (Even if it could pull from a list, you can't mix sources. Either all items come from a list or all items are pulled through port connections).

- The best approach would probably be to use the "Update Combiner Component List" option in the On Entry trigger and edit it down to what you need: Set the quantity to 1 if the item is of type 005657 and 0 otherwise.

if (port == 1)
{
    int qty = 0;
    if(item.Type == "005657")
    {
        qty = 1;
    }
   
    Table thelist = getvarnode(current, "componentlist");
    treenode thesum = getvarnode(current, "targetcomponentsum");

    thelist[1][1] = qty;
    thesum.value = qty;
}

- Furthermore, your "Type" label values are assigned as numbers. As such, FlexSim is trying to read row number 5657 (or even higher numbers) when trying to determine the processing time and output port. In order to use the row header to refer to the correct row, you have to use string (text) values.

1669726249319.png

- And your column numbers are wrong. The table has two columns, you are trying to read from column 2 and 3.

jobshoproute-v081_1.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.

Håkon L avatar image Håkon L commented ·
OMG - Thank you Felix! Thank you for the thorough explanation and fixes!

I've read your post, made some notes, and am now in the process of correcting similar errors that you have fixed, based on the knowledge you gave me. The only thing I don't seem to understand entirely is the code-snippet for M57, but I will take a closer look at that a little later.

I cannot thank you enough! Now the work I'm responsible for completing actually seems within reach! I wish you the most wonderful day, mr.! :)

0 Likes 0 ·
Felix Möhlmann avatar image Felix Möhlmann Håkon L commented ·

The code snippet sets the values of the nodes responsible for controlling how many items the combiner will accept through port 2 (and higher if more connections are present). I've marked them in the combiner's attribute tree below.

1669791503112.png

The "componentlist" is cast as table, so that the "From Input Port 2" node is accessible as the first row and the nodes inside that as the columns of a table. Hence "thelist[1][1] = qty".

0 Likes 0 ·
1669791503112.png (8.4 KiB)

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.