Cancel
Showing results for 
Search instead for 
Did you mean: 

Pull MU's from a Buffer

Hello,

 

I have a buffer which has 1000 A Parts and I need to pull only 100 A parts / day.

 

I wanto pull these parts based on my daily demand (at drain). How do I execute this?

 

Please help. Thanks in advance.

 

Regards,

Sharad

5 REPLIES

Re: Pull MU's from a Buffer

Siemens Valued Contributor Siemens Valued Contributor
Siemens Valued Contributor

Hi Sharad, 

 

you could introduce a method as a exit control for your buffer that limits your work in process to 100 in between your buffer and drain.

 

Example of how the method could look like:

 

var CurrWiP, LimitWiP : integer

LimitWiP := 100

CurrWiP := buffer.statnumout - drain.statnumout

 

if CurrWiP < LimitWiP

    @.move

else

    Waituntil CurrWiP < LimitWiP prio 1

    @.move

end

 

 

Regards Johan

Re: Pull MU's from a Buffer

Thank you for your inputs Johan.

Re: Pull MU's from a Buffer

Experimenter
Experimenter

Hi Johan,

 

I tried to use the code that was outlined and I got an error "expression not watchable."  I attached a sample model with my issue.

 

THANKS in advance!

 

Ryan

Re: Pull MU's from a Buffer

Gears Esteemed Contributor Gears Esteemed Contributor
Gears Esteemed Contributor
just write all the values to be watched into the waituntil command:

waituntil (InBuffer.StatNumOut-OutBuffer.StatNumIn)<LimitWIP
Steffen Bangsow
freelance simulation specialist  
web: www.bangsow.eu
mail: steffen@bangsow.net

Re: Pull MU's from a Buffer

Experimenter
Experimenter
Perfect! Thanks!