Cancel
Showing results for 
Search instead for 
Did you mean: 

Detecting shift change

Solution Partner Legend Solution Partner Legend
Solution Partner Legend

Hello, I am modeling a 3-shift system (21 shifts a week, production 24/7) where the production of parts in the production plan is quantified in amount of shifts (not an amount of products).

 

For example:

 

Week 1
Production line 1: Product A produced for 15 shifts, then Product B produced for 6 shifts
Production line 2: Product C produced for 5 shifts, then Product D produced for 15 shifts
Production line 3: Product E produced for 21 shifts

Week 2
Production line 1: Prod...


etc.

First I am wondering what the best way of modeling this production plan would be, using Sources (Production line 1 = Source 1, Production line 2 = Source 2 etc.) for producing the parts in question according to the schedule above. Since the amount of parts is not specified, I need to rely on counting the amount of shifts that have been "consumed" in order to control a setup for the next product in line.

 

Since the production functions on a 24/7 basis, the day of the week does not matter much, however the current shift matters (or rather how many shifts have been "consumed" for that specific production line in the production plan).

 

So in addition to my first question, I am wondering if there is some way to detect a shift change? There does not seem to be a good attribute in the observer list for the shift calendar to look at. The only way I can think of right now is to increase the number of shifts consumed every 8 hours, but this is not flexible if the system were to change to a 2-shift system with different start/end times.

 

Thank you.

6 REPLIES

Re: Detecting shift change

Builder
Builder

maybe with F12 on the shift calendar, the unplanned control can be a good way to count the number of shifts with a method within...  (or pauses)

Re: Detecting shift change

Valued Contributor
Valued Contributor

you could use a generator with an interval of 8 hours. In the method you can "count" the calls (shifts) and switch the created MUs (source.path) of the (non blocking) sources.

 

It is true, it is not easy to detect the shift change. getCurrShift is a method (not observable). so you could write the return value of getCurrShift into a global variable periodically (e.g. úsing a generator). Then you can use an observer in the variable (value) to react to a shift change.

Re: Detecting shift change

Legend
Legend

If you have access to the Trigger object you could use that as well. Then you can observe when a shift changes between the shifts. Especially useful if your weekends are divided into shift times that are different from the ones on the week. 

 

Setting up the Trigger table you start with the first shift of the week, for example a sunday evening, and then set it to repeat every 7 days.

 

Under Values you set trigger type to Input and start naming your shifts starting from the first one and then setting a time when there's a shift change until you have filled in one week. Under Actions you set the Methods to be activated when a shift changes. The method will have two parameters, the old shift value and the new shift value. In this way you can differentiate them.

Re: Detecting shift change

Solution Partner Legend Solution Partner Legend
Solution Partner Legend
Thank you for the good replies. I think it would be good if Plant Simulation had a pulse-flag of sorts which could be monitored when a shift change occurs instead of having to rely on generators and triggers.

Re: Detecting shift change

Siemens Phenom Siemens Phenom
Siemens Phenom

Hello 7SEG,

 

we will add an observable attribute 'CurrentShift' to the next release of Plant Simulation.

 

Then you can add an observer to detect shift changes.

Regards,

Ralf
------------------------------------------------------------------------------------------------------
Did you like the answer? Then click the Thumbs Up button.
Did the answer solve your problem? Then accept the answer as solution.

Re: Detecting shift change

Siemens Phenom Siemens Phenom
Siemens Phenom

After having a deeper look we think there is no need to add a new attrbute.

 

It's possible to watch the attribute 'Unplanned'. Whenever a shift changes the value of this attribute changes as well. The you can use the method 'getCurrShift' to get the name of the current shift.

Regards,

Ralf
------------------------------------------------------------------------------------------------------
Did you like the answer? Then click the Thumbs Up button.
Did the answer solve your problem? Then accept the answer as solution.