Cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with waituntil

Valued Contributor
Valued Contributor

I have some problem with waituntil. What I try to do is too control when i Unit is allowed to enter the next step and that is only allowed if the conditions are meet. Every thing works when the first unit passes but when unit 2 triggers the metod one of the condition is not true and insted of waiting until it is true it crashes. What have i done wrong? I have also noticed that when the condition been diffrent that the unit never was moved and the metod was triggerd a secondtime.

 

 

waituntil Process.NUMMU + B3.NUMMU < Limit and (Process.entranceFree and Process.entranceOpen) prio 1;
 if @ /= void then
  @.move();
 else
 end;

3 REPLIES

Re: Problem with waituntil

Siemens Phenom Siemens Phenom
Siemens Phenom

Hi Jfinnberg,

 

the problem is that the attribute 'EntranceFree' is not watchable.

 

You can see this when you open the 'Show Attributes and Methods' dialog for the object Process:

EF.png

 

You can see that the * in the column Watchable is missing.

 

The first time this doesn't cause a problem since the waituntil doesn't have to wait since the condition evaluates to true.

 

Regards,

Ralf

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: Problem with waituntil

Valued Contributor
Valued Contributor
Hello
Thanks so if I have a shift calendar that triggers a closing of this process before the rest of the processes I will need to use for example a variable of Boolean type that waituntil statement consider?



Jfinnberg

Re: Problem with waituntil

Siemens Phenom Siemens Phenom
Siemens Phenom

Yes, this would be a viable solution.

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.