Dear community members,
I'm using as setup method "after n parts - after lat part".
I do not want the first setup (before one entity is processed) and I followed the steps of a similar post:
Thus I created a init method with the following code
seat_4_1.setuptime:=0; seat_4_1.setupfor(.mus.customer); seat_2_1.setuptime:=0; seat_2_1.setupfor(.mus.customer); seat_6_1.setuptime:=0; seat_6_1.setupfor(.mus.customer)
But the station still sets-up before the first unit is processed. Indeed, the "Set-up for" in setup tab, after the init method, is still "-".
Solved! Go to Solution.
I inserted 1 second and it works, but it gives now another problem: the setup starts as soon as the 3th entity (I setted "After 3 parts - after last part") enters the singleproc.
For this reason, i tried with a singleproc exit control. the method counts 3 entities and, when the third entity exits the process, it calls the setup. I used this code
if ?.statnumout = ?.cleaning then -- cleaning is equal to 3 at the beginning (I tested it and it's not the issue) ?.importeractive:=true; -- used to do a manual setup ?.setupfor(.mus.customer); ?.cleaning:=?.cleaning+3;
the MU is of the same class of the previous MU. IT DOES NOT WORK, i.e. when the condition is met, there is no setup.
If you want the setup to happen each time 3 parts are finished then you want the setup for the 4th part.
Now the thing of activating and deactivating the importer seems a bit unnecesary you can set the importer to only attend setups. Thus an exporter will react only to this calls.
Maybe if you share what you are trying to accomplish help may be easier to give.
I would like to suggest a somewhat different apporach. If you have time for it, of course...
Make a Frame for each "table". When a customer enters the frame, the entrance should be locked, afterwards it should be unlocked. Represent each part of the cycle with a SingleProc, Assembly (serving food!) or Dismantle station. Apply service requirements (Importer tab) where needed. The last SingleProc (payment and guest leaving) can have "Set-up after 1 parts" and "After last part" in the set-up tab.
It is a bit more work, but more flexible.
thanks for your answer.
I did as you suggested, but I still get an issue:
the setup is done without the worker. I activate the importer as soon as the entity enters the last process, but when it exits and another entity gets in, the setup starts without the worker.
Can it be an importer issue?
I use "Common Resources" in thr tab "importer".
If you can have a look to the model, you can find it attached.
I have no idea why you would switch the importer on/off. Now you will never ask for a worker, since the importer is off as soon as the customer leaves, hence cleaning the table does not request a worker.
De-activiate Common resources. Then use the radio buttons to toggle between the services for Set-up and those for Processing. Clear the Services for Processing table, so that no worker is requested for that part (or set the imp-attribute to false and setupimp to true by SimTalk). Finally, don't mess with the switching on and off, just keep it on.