Page 1 of 1

Human Resource on Server which uses Batch Rules

Posted: Tuesday 04 December, 2018 - 16:43
by masterflolo
Hello,

I have a Server Atom with the Batch Rule B in, B out and the Batch is 20. When i call a Human Resource to work with the Server, he is unable to finish the job and is stucked "busy". Is this a bug? I use Enterprise Dynamics 10.2.

Re: Human Resource on Server which uses Batch Rules

Posted: Wednesday 05 December, 2018 - 08:52
by HarryBunnik
Hello Masterflolo,

Can you send me the model or an example? I would like to see what is exactly happening.

Because what can happen is that, due to the batching, the function "HumanResourceTeam_FreeResources" is called several times. So you have to be sure that it is called with the correct product (most often referred to as "i" as the second parameter) to free the resource again. In the case of a batch which is created in a server this would be the first product leaving the server again.

I hope this helps you a bit further,

Regards,

Harry

Re: Human Resource on Server which uses Batch Rules

Posted: Wednesday 05 December, 2018 - 12:32
by masterflolo
Thanks for the reply.
I have uploaded the model. Server27 should get 5 Products as a Batch and release them altogether after Max(0,Normal(180,0.5)). But the Human Resource is always busy.

Re: Human Resource on Server which uses Batch Rules

Posted: Wednesday 05 December, 2018 - 12:59
by HarryBunnik
Hello Masterflolo,

There are a few points here.

First, since you want to collect 5 products, you're currently calling for each of these 5 products a Human Resource. Here you need to call a Human Resource only for the first product of each batch (I would use a modulus here (Mod)).

Secondly, I see that you call the Human Resource, but where do you release it again? I would think that you want to do that when the products exit the Server? So I think that on the OnExit trigger a call to the function "HumanResourceTeam_FreeResources" should be made. And also here you have to give that order only once and it needs to be related to the product that you called the human resource for in the first place. So I would set a label on the product and when it leaves the server, also release the Human Resource.

I think that should already solve some of your problems.

I hope it helps you further,

Regards,

Harry