anylogic

Pausing A Bridge Crane's Movement


I am simulating a system where a bridge crane picks items from a number of containers to fulfil a customer order. When a container becomes empty, it has to be restocked manually. For restocking to happen, the bridge crane must pause/stop moving for a fixed delay (even if it was in the process of transporting an item when the restocking process was triggered).

I tried to use a downtime block, but these blocks require a information for fixed repeating schedules or triggers. However, in my system the "downtime" for restocking can't be predicted because it depends only on a container becoming empty. Therefore, it can't also be described as a fixed repeating schedule or triggers.

I am looking for ideas or simple code that will help me pause the bridge crane's movement on the runway for a fixed time when a manual restocking process needs to happen.


Solution

  • This can be defined by the fail and repair functions, according to the documentation for OverheadCrane

    It is important to notice that you must fail an individual bridge in the crane (as stated in the documentation), so you probably need something similar to overheadCrane.getBridge(0).fail().

    You can manually decide then how you will fail(stop) and repair(resume) the crane.