Add-On Instruction Definition Editor Dialog - Scan Modes Tab Overview
The Scan Modes tab provides access to the scan mode routines.
When EnableIn is true, the Add-On-Instructions primary logic routine is executed. However, there are three other modes in which an instruction can execute:
- PrescanprescanThe function of the controller whereby the logic within a program is examined prior to execution. This allows for instruction and data initialization.
- Postscanpost-scanThe function of the controller whereby the logic within a program is examined before disabling it in order to reset instructions and data.
- EnableInFalseEnableInFalseWhen defined and enabled for an Add-On Instruction, the EnableInFalse routine executes when the rung condition is false or the EnableIn parameter of the Add-On Instruction is false (0). This is useful primarily for scan false logic when used as an output instruction in a Ladder routine.
This tab lets you create custom routines to further define the behavior of the Add-On-Instruction in each of these modes. The scan mode routines do not exist for an Add-On-Instruction unless you create them. If a scan mode routine is not defined, there is default behavior for that mode. Refer to Add-On Instructions Scan Modes for more information.
For each of the three modes, you have the option to define a custom routine that can be programmed specifically for that mode.
Attributes
Execute Prescan routine after the Logic routine is prescanned
Select this box to execute the prescan routine after the logic routine has prescanned.
Note that a mode routine can exist but not be in use if its execute check box is not selected.
Execute Postscan routine after the Logic routine is Postscanned
Select this box to execute the postscan routine after the logic routine has postscanned.
Note that a mode routine can exist but not be in use if its execute check box is not selected.
Execute EnableInFalse Routine
Select this box to execute the false routine when enable is false.
Note that a mode routine can exist but not be in use if its execute check box is not selected.
New
The scan mode routines do not exist by default. If a mode routine does not exist, the execute check box for it appears dimmed, and a New… button is available to open the New Scan Mode Routine Dialog Box. The mode indicates which scan mode is being created.
TIP:
If the Class of the instruction is Safety, the New button for Postscan is disabled.
When the scan mode routine is created, the execute box is enabled and selected.
Delete
If a scan mode routine exists, the Delete button replaces the New… button. Click the Delete button to delete the mode routine. When the scan mode routine is deleted, the execute box is deselected and appears dimmed.
Go To
If a mode routine exists, a Go To button is enabled, which, when clicked, opens the routine associated with the scan mode in the appropriate routine editor. The Go To button is disabled when the scan mode routine is undefined or the language it is implemented in is not activated.
Logic
Click to open the Logic routine. This Logic button is not visible if the Add-On Instruction is source-protected.
Data Type Size
Displays the size of the Add-On Instruction data type – this does include the size of any Local Tags (even though Local Tags are not visible when an instance tag of this data type is expanded in the Tag Editor or Data Monitor), but it does not include logic size. The size is automatically updated when you apply the instruction, not as you create the Parameters and Local Tags.
Copy all default values of parameters and local tags whose values were modified to all tags of this instruction type
Copies all the default values of the parameters/local tags, or members' default values, that you have changed, to all instance tags of this instruction type.
Provide Feedback