Creating local tags, Create local tags – Rockwell Automation Logix5000 Controllers Add-on Instructions Programming Manual User Manual
Page 44

Chapter 2
Defining Add-On Instructions
Use the Add-On Instruction Definition Editor to create the local tags for your
instructions. Local tags contain data that will be used by your Add-On Instruction
but that you do not want exposed to the user of your instruction. Local tags do not
appear in the data structure for an Add-On Instruction because they are hidden
members.
Tip:
You can access local tag values from an HMI by specifying the name of the local tag as a member in an
Add-On Instruction type tag. For example, the Motor_Starter v1.0 instruction, shown in step 2, has a tag
called ‘CheckAuxContact’. This tag can be referenced by an HMI through ‘instancetag.CheckAuxContact’,
where instancetag is the tag used to call the instruction.
Follow these steps to define the local tags for your instruction.
1. In the Controller Organizer, right-click an instruction and select Open
Definition.
2. On the Local Tags tab, in the blank Name box field, type a name for a new
tag.
3. In the Data Type list, select a data type from the Select Data Type dialog
box.
You cannot use these data types for local tags - ALARM_ANALOG,
ALARM_DIGITAL, MESSAGE, MODULE, or any Motion data types,
for example Axis or MOTION_GROUP. To use these type of tags in your
Add-On Instruction, define an InOut Parameter. Local tags also are limited
to single dimension arrays, the same as User-Defined Data Types.
Tip:
Refer to th
data types supported for safety instructions.
4. In the Default list, set the default values.
Creating local tags
44
Rockwell Automation Publication 1756-PM010F-EN-P - October 2014