Page 60

Petruzella_ProgrammableLogicControllers__5e

With text-based Logix systems you can use the name of the tag to document your ladder code and organize your data to mirror your application. For the programmed motor start/stop control circuit three tags, Motor_Start, Motor_Stop, and Motor_Run, are created. Figure 15 33 illustrates how the Motor_Start tag is created in the New Tag window. This window can be accessed by right clicking the ? mark above the XIC instruction in the ladder logic program. Since this tag represents a value from an input field device, a link through the module to the field device must be created. When Local:1:I.Data is selected a dialog box for all of the terminal numbers on the input module appears. The tag name (Motor_Start) used in the program is then linked to input terminal number 3 where the field device represented by the tag name is connected. Figure 15-34 shows what the ladder logic program would look like after all three tags have been created. Users have the ability to reference data via multiple names using Aliases. This allows the flexibility to name data differently depending on their use. The tag description provides for a more meaningful description of the tag name. Tag names are downloaded and stored in the controller New Tag Name: Motor_Start Alias Start button for Local:1:I.Data motor Description: Name Local:1:C Local:1:I Local:1:I.Fault Local:1:I.Data Data Type AB:1756_DO:C:0 AB:1756_DO:I:0 DINT + – 0 8 16 24 1 9 17 25 2 10 18 26 3 11 19 27 5 13 21 29 6 14 22 30 7 15 23 31 4 12 20 28 Figure 15-33  Creating the Motor_Start tag. Source: Image Courtesy of Rockwell Automation, Inc. but the description is not, as it is part of the documentation of the project. Figure 15-35 shows the state of the tags created for the motor start/stop program as seen in the program and Motor contactor coil Motor_Run <Local:2:O.Data.4> Start button for motor Motor_Start <Local:1:I.Data.3> Motor contactor coil Motor_Run <Local:2:O.Data.4> Stop button for motor Motor_Stop <Local:1:I.Data.4> Description Tag Name Alias Figure 15-34  Ladder logic program after all tags have been created. Inputs Ladder logic program Output L1 L2 Motor contactor coil Motor_Run <Local:2:O.Data.4> Start button for motor Motor_Start <Local:1:I.Data.3> Motor contactor coil Motor_Run <Local:2:O.Data.4> Stop button for motor Motor_Stop <Local:1:I.Data.4> Stop Motor_Stop Motor_Start Start Monitor Tags Window Tag Name Value Style Data Type Motor_Start 0 Decimal BOOL Description Start button for motor Motor_Stop 1 Decimal BOOL Stop button for motor Motor_Run 1 Decimal BOOL Motor contactor coil Figure 15-35  Ladder logic program and Monitor Tags window with motor operating. M Motor_Run Contactor Bit-Level Programming  Part 2 349


Petruzella_ProgrammableLogicControllers__5e
To see the actual publication please follow the link above