Components of an Add-On Instruction

Add-On Instructions are made up of the following parts.

General Information

The General tab contains the information you enter when you first create the instruction. You can use this tab to update that information. The description, revision, revision note, and vendor information is copied into the custom help for the instruction. The revision is not automatically managed by the software. You are responsible for defining how it is used and when it is updated.


Class information for safety controller projects appears on the General tab as well. The class can be standard or safety. Safety Add-On Instructions must meet requirements specific to safety applications.


Parameters

The parameters define the instruction interface; that is, how the instruction appears when used. The parameter order defines the order that the parameters appear on the instruction call.


Local Tags

The Local Tags tab defines tags that are used by the logic within the Add-On Instruction and are not visible outside the instruction. Other Add-On Instructions or programs in the project cannot access these tags.

The only way to make a local tag or one of its members accessible from outside the instruction is by defining an alias parameter.


Data Type

Parameters and local tags are used to define the data type that is used when executing the instruction. The software builds the associated data type. The software orders the members of the data type that correspond to the parameters in the order that the parameters are defined. Local tags are added as hidden members.

The data type for a Local Tag may not be a multi-dimensional array or an object type, which includes all Motion types, MSG, ALARM_ANALOG, and ALARM_DIGITAL.

The data type field is unavailable for members of a Local Tag.

Logic Routine

The logic routine of the Add-On Instruction defines the primary functionality of the instruction. It is the code that executes whenever the instruction is called. Shown below is the interface of an Add-On Instruction and its primary logic routine that defines what the instruction does.


Optional Scan Mode Routines

You can define additional routines for Scan mode behavior.


Instruction Signature

The instruction signature consists of an ID number that identifies the contents of the Add-On Instruction and a timestamp that identifies the specific date and time at which the instruction signature was generated or a signature history entry was made (whichever came last).


Once generated, the instruction signature seals the Add-On Instruction, preventing it from being edited while the signature is in place.

In addition, when a sealed safety Add-On Instruction is downloaded for the first time, a SIL 3 safety instruction signature is automatically generated. The safety instruction signature is an ID number that identifies the execution characteristics of the safety Add-On Instruction.

Signature History

The signature history provides a record of signatures for future reference. A signature history entry consists of the name of the user, the instruction signature, the timestamp value, and a user-defined description. Up to six history entries can be stored. If a seventh entry is made, the oldest entry is automatically deleted.

Change History

The Change History tab displays the creation and latest edit information that is tracked by the software. The By fields show who made the change based on the Windows user name at the time of the change.


Help

The name, revision, description, and parameter definitions are used to automatically build the Instruction Help. Use the Extended Description Text to provide additional Help documentation for the Add-On Instruction. This content reflects updates as Parameters or other attributes are changed in the definition.

The Instruction Help Preview shows how your instruction will appear in the various languages, based on parameters defined as required or visible.



0 comments :