Recipe Trigger Tag

Triggers a Recipe Book to write the specified recipe to the PLC and to record it using the specified batch number and note. This tag must be a descendent of a Recipe Book tag. The trigger may be any of the following conditions:

  • A specified recipe is complete.
  • A specified recipe is complete and an external trigger occurs, such as a timed delay or another Recipe Trigger completes
  • An external trigger occurs.

You can use this tag to run multiple recipes in sequence. For example, after Recipe A is started, a trigger tag can say “If Recipe A is complete, then start Recipe B after a 5 second delay”. The delay must be provided as an expression.

If you are building your first recipe, start by reading Recipes and Batch Processing before creating recipe-related tags and widgets.

Expressions are a powerful tool for configuring tag parameters. But, their use requires some knowledge of basic programming. Refer to the Expressions chapter of the Scripting notes before attempting to use.

A Recipe Trigger tag can be used even if the PLC does not support Start or Done addresses.

No widgets are associated with this tag. It cannot be drawn on a page.

Recipe Trigger tag properties, Activation tab

If [Recipe] [Version] is complete

An optional trigger that signals activation upon completion of a selected version of a selected recipe within the parent Recipe Tag.

Leave both as --- Any --- if the trigger depends only on an external event.

And

  • If a recipe (and optionally a version) is specified, this is an additional condition that must be met before the trigger will occur.
    Timer expressions are common, but the condition could be a watch on another tag.
  • If a recipe (and optionally a version) is not specified, the "And" condition is the trigger.
  • If set to the default, 1, then there is no additional condition. The trigger will occur when the specified recipe is complete.

As an example, this might check the value of a selected tag, where any non-zero numeric value would be taken as "TRUE".

If your goal is to add a delay to the trigger, then use an expression, such as Timeout(1, 5) Note that the expression is not executed until the specified recipe is complete. This means that the Enable parameter of the Timeout function can be left as 1 if the And condition follows recipe completion.

 

Then Start [Recipe] [Version]

The recipe selection is required. Add the version if there is more than one to choose from.

This is the recipe to run when the trigger is activated.

Batch Number

Optional. A specified lot number to be assigned to a given batch run.

If set as a constant, the same number will be used each time. You can use Memory Tags to provide a way for operators to set a batch number. Advanced users could use an expression or write a script module if there is an automated way to define a batch number.

If an expression is used, it will not run until it is time to start the batch.

Note

Holds a single, predefined note that will be added to each run.

Recipe Trigger tag properties, Proportions tab

Proportions Tag

A list of every Recipe Proportions Tag in the recipe book. If empty, your recipe book is not using proportions.

Value

Set the value that should be used for each proportion in the batch run triggered by this tag.