Hi everyone,
I am getting a strange behavior in my current model. After a while, I get this message:
This is the part of the network where the error occurs:
I checked the AGV network and it is correctly designed. I also tried with the cpdistance command and it works. Considering that the network has some orientation rules, I checked also that the path is feasible, and it is.
I discovered a strange behavior: the AGV cannot resolve the route only after a specific simulation event/time.
In fact, if I launch this script at the beginning of the simulation run or before the specific event/time, the AGV can resolve the route.
Object agv = Model.find("AGV 4"); Object cp = Model.find("ControlPoint4439");//AGV(agv).currentCP; Object cpDest = Model.find("ControlPoint4779"); // Set preemption of the previous task sequence to 0 TaskSequence ts = agv.as(TaskExecuter).activeTaskSequence; if(ts) ts.preempt = 0; // Override the previous ts with a new one TaskSequence newts = TaskSequence.create(agv, 0, PREEMPT_AND_ABORT_ACTIVE, 0) newts.addTask(TASKTYPE_TRAVEL, cp, NULL, 0); newts.addTask(TASKTYPE_TRAVEL, cpDest, NULL, 0); newts.dispatch();
The script stops working just when the agv, during one if its previous missions, travels towards another control point and it passes over the “problematic” ControlPoint4439.
Since then, the script doesn’t work and if I continue running the simulation, I encounter the problem.
What could be the cause of this error?
Also, I noticed that the model “stops” (freezes) for several seconds every time I edit/refresh the network and press reset and run. This behavior happens only at the first reset performed after the change of the network: If I don’t change the network again, it will not occur.
This behavior happens also in other models that work fine. The stop time increases with the complexity of the network.
What could be the cause of this behavior?
Thank You
Stefano