article

Jason Lightfoot avatar image
2 Likes"
Jason Lightfoot posted Jason Lightfoot edited

Automatic Routing Through non-contiguous Conveyors by creating travel Maps


If you have a contiguous conveyor network you can just route items using Conveyor.sendItem() and FlexSim will guide the item to the destination, passing through inline and side transfers as required for the shortest path.
If between some conveyors you use exit and entry transfers, perhaps to easily add elevators and shuttles as transports between them - then you'll normally be faced with adding logic to figure out which exit transfer to go to and which port to take from that transfer - and in a large model that logic can be extensive and hard to maintain.

1738612147704.png


The attached model and library provides commands for automated routing through multiple conveyor sub-sections connected through exit/entry transfers, to conveyor points and to connected fixed resources. This means that you may no longer have to write sendTo code with case statements on each exitTransfer to determine which port an item should exit through – nor possibly need to have decision points with case logic to decide the destination for Conveyor.sendItem().

In the example model three sources create items with random destinations which are routed through the conveyor system, transfers and port automatically to arrive at the correct destinations – some of the ports having transport to perform the move.

To make this work in any model you should load the user library which will auto-install a set of user commands and a General Process Flow.

The first step is to run the user command ‘createAllTravelMaps()’ which will calculate all the reachable destinations (decision points, stations, pes, attached fixed resources and transfers) from all the conveyor points and entry/exit transfers) along with estimates of the conveytime (from the conveyor class). This information consolidated to create the shortest routes and is stored in a label ‘travelMap’ on each decision point, station, pe and transfer.

To make use of the travelMap data there are three additional user commands supplied that are intended to be used directly by the modeller:

  • getNextConveyPoint(thispoint, destination) – returns the next point to send an item to from this point in order to ultimately reach the destination.
  • getConveyExitPort(exitTransfer, destination) – returns the port through which an item should exit the exitTransfer in order to reach the destination.
  • getConveyItemsNextConveyPoint(item, destination) – returns the next point to which an item should travel to reach the destination from its current position on a conveyor.

The simple process flow in the example and library is set to listen to the Group members of EntryTransfers and ExitTransfers in order to lookup the ‘destination’ label and either sends the item to the next point or in the case of the exit transfers, overrides the sendTo port with the value from the map.

1738612238543.png

I’ve added some documentation to the user commands which you can access easily via the command helper: 1738612270022.png

ConveyorTravelMaps_0.3.fsl

ConveyorTravelMapExample.fsm

You may find createTravelMaps() takes a while which is why a progress bar has been added. You may not need all points to be evaluated exhaustively so the option to pass in a flag indicating to only start evaluation from Entry Transfers is given, which will create somewhat incomplete maps for intermediate points.

A future refinement would be to account for transport time from exit transfers either by recording the times or providing port list with the expected times.

Clearly if you make changes to your transfer positions or conveyor layout you should rerun createAllTravelMaps.


conveyorsroutingmapsexit transfers
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Article

Contributors

jason.lightfoot contributed to this article