article

Paul Toone avatar image
1 Like"
Paul Toone posted

Linking Process Flows to 3D Models   

Process flows can run independently from a simulation model if needed. But process flows are probably most useful when they are linked to simulation model. Process flows can help you build complex logic into your model, replacing the need for complicated code. Process flows will also make it easier for you to troubleshoot your model logic if needed. With that in mind, this topic covers how to integrate process flows with a standard simulation model.

There are two different ways to link your model to a process flow:

  1. Events - You can use process flow activities that will listen for a certain event in the simulation model. When that event occurs, the activity can then initiate a process flow (by creating a token) or trigger another activity in a process flow.
  2. Picklists - Some properties on fixed resources and task executers have menu options that can initiate a sub flow.

The following sections will give an overview of each method and will provide links for more information.

Events

Events are the most common way to link to a process flow from a simulation model. For example, you can set an activity in your process flow to listen for an item to enter a processor. Every time an item enters the processor, it would then kick off a series of activities that perform custom logic, perhaps to dynamically determine the processing time for that type of item. If you were not using a process flow to do this, you'd need to manually write code for the OnEntry trigger of the processor instead.

The two activities that can listen for events are:

  • Event-Triggered Source - This activity will listen for a specific event to occur in the simulation model. When that event occurs, it will create one or more new tokens and send the tokens to the next activity in the process flow. You should use an event-triggered source if you want the triggering event to initiate the process flow. See Event-Triggered Source for more information about this activity.
  • Wait for Event - After this activity receives a token, it will hold the token while it listens for a specific event to occur in the simulation model (or in the process flow). When that event occurs, it will release the token to the next activity in the process flow. If needed, you can also make the Wait for Event act like a Decide activity. In other words, the Wait for Event activity could possibly send the token to different activities next based on certain conditions in the simulation model. See Wait for Event for more information about this activity.

See Key Concepts About Event Listening for more detailed information about events.

Picklists

Some properties on fixed resources have menu options (picklists) that can initiate a task sequence sub flow. A task sequence is a series of actions (tasks) in a sub flow that can be assigned to a task executer (such as an Operator or Transporter). (See Task Sequences for more information.)

For example, you can change a Processor's settings so that it will use a task executer during its setup time or processing time. A Processor can also use a task executer to transport flowitems to another downstream object when the item is finished being processed. If you need a task executer to complete a more complex series of tasks during setup, processing, or transportation, you could create a task sequence on a process flow. Then, you could use the ProcessFlow: Use Task Sequence Sub Flow picklist on the Processor's setup, processing, or transportation properties to reference that task sequence.

See Sub Process Flows and Task Sequences for more information. Also, Tutorial 2 - Linking to Simulation Models and Tutorial 3 - Task Sequences can give you some hands-on experience with these concepts.

flexsim users manualuser manuals
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

paul.t contributed to this article

Navigation

FlexSim 2016.1