SLC 500 Instruction Set Reference Manual
Total Page:16
File Type:pdf, Size:1020Kb
SLC 500 Instruction Set Catalog Numbers 1747-L20x, 1747-L30x, 1747-L40x, 1747-L511, 1747-L514, 1747-L524, 1747-L531, 1747-L532, 1747-L533, 1747-L541, 1747-L542, 1747-L543, 1747-L551, 1747-L552, 1747-L553 Reference Manual Important User Information Solid state equipment has operational characteristics differing from those of electromechanical equipment. Safety Guidelines for the Application, Installation and Maintenance of Solid State Controls, publication SGI-1.1, available from your local Rockwell Automation sales office or online at http://www.literature.rockwellautomation.com), describes some important differences between solid state equipment and hard-wired electromechanical devices. Because of this difference, and also because of the wide variety of uses for solid state equipment, all persons responsible for applying this equipment must satisfy themselves that each intended application of this equipment is acceptable. In no event will Rockwell Automation, Inc. be responsible or liable for indirect or consequential damages resulting from the use or application of this equipment. The examples and diagrams in this manual are included solely for illustrative purposes. Because of the many variables and requirements associated with any particular installation, Rockwell Automation, Inc. cannot assume responsibility or liability for actual use based on the examples and diagrams. No patent liability is assumed by Rockwell Automation, Inc. with respect to use of information, circuits, equipment, or software described in this manual. Reproduction of the contents of this manual, in whole or in part, without written permission of Rockwell Automation, Inc., is prohibited. Throughout this manual, when necessary, we use notes to make you aware of safety considerations. Identifies information about practices or circumstances WARNING that can cause an explosion in a hazardous environment, which may lead to personal injury or death, property damage, or economic loss. IMPORTANT Identifies information that is critical for successful application and understanding of the product. ATTENTION Identifies information about practices or circumstances that can lead to personal injury or death, property damage, or economic loss. Attentions help you identify a hazard, avoid a hazard, and recognize the consequences. SHOCK HAZARD Labels may be located on or inside the equipment (for example, drive or motor) to alert people that dangerous voltage may be present. BURN HAZARD Labels may be located on or inside the equipment (for example, drive or motor) to alert people that surfaces may be dangerous temperatures. Publication 1747-RM001G-EN-P - November 2008 Summary of Changes The information below summarizes the changes to this manual since the last printing. To help you find new and updated information in this release of the manual, we have included change bars as shown next to this paragraph. The table below lists the sections that document new features and additional or updated information about existing features. For This Information See Page Addition of a powerup error to Table 16.1. 16-4 Revision of the company name from "Allen-Bradley" to "Rockwell Automation". G-1 1 Publication 1747-RM001G-EN-P - November 2008 2 Summary of Changes Notes: Publication 1747-RM001G-EN-P - November 2008 Table of Contents Preface Who Should Use This Manual. P-1 Purpose of This Manual. P-1 Related Documentation. P-2 Common Techniques Used in This Manual . P-2 Chapter 1 Processor Files File Structure . 1-1 Output and Input Data Files (Files O0: and I1:) . 1-2 Status File (File S2:) . 1-3 Bit Data File (B3:) . 1-3 Timer Data File (T4:). 1-4 Addressing Structure . 1-5 Counter Data File Elements (C5:). 1-6 Entering Parameters . 1-7 Addressing Structure . 1-7 Control Data File (R6:) . 1-8 Integer Data File (N7:) . 1-10 Float Data File (F8:). 1-11 Chapter 2 Basic Instructions About the Basic Instructions . 2-2 Bit Instructions Overview . 2-2 Examine if Closed (XIC) . 2-3 Examine if Open (XIO). 2-3 Output Energize (OTE) . 2-4 Output Latch (OTL) and Output Unlatch (OTU) . 2-4 Using OTL . 2-4 Using OTU. 2-5 One-shot Rising (OSR) . 2-5 Entering Parameters . 2-5 Timer Instructions Overview . 2-7 Entering Parameters . 2-7 Timer On-delay (TON) . 2-9 Using Status Bits . 2-9 Timer Off-delay (TOF) . 2-10 Using Status Bits . 2-10 Retentive Timer (RTO) . 2-11 Using Status Bits . 2-12 Counter Instructions Overview. 2-13 How Counters Work . 2-13 Count Up (CTU) . 2-13 Using Status Bits . 2-14 Count Down (CTD). 2-14 Using Status Bits . 2-15 High-speed Counter (HSC) . 2-15 High-speed Counter Data Elements. 2-16 i Publication 1747-RM001G-EN-P - November 2008 ii Table of Contents High-speed Counter Operation . 2-17 Reset (RES). 2-20 Chapter 3 Comparison Instructions About the Comparison Instructions . 3-1 Comparison Instructions Overview . 3-2 Using Indexed Word Addresses . 3-2 Using Indirect Word Addresses . 3-2 Equal (EQU) . 3-2 Not Equal (NEQ) . 3-2 Less Than (LES). 3-3 Less Than or Equal (LEQ) . 3-3 Greater Than (GRT) . 3-3 Greater Than or Equal (GEQ) . 3-4 Masked Comparison for Equal (MEQ). 3-4 Entering Parameters . 3-4 Limit Test (LIM) . 3-5 Entering Parameters . 3-5 Chapter 4 Math Instructions About the Math Instructions . 4-2 Math Instructions Overview . 4-2 Entering Parameters . 4-2 Using Indexed Word Addresses . 4-2 Using Indirect Word Addresses . 4-2 Updates to Arithmetic Status Bits. 4-3 Overflow Trap Bit, S:5/0 . 4-3 Updates to the Math Register, S:13 and S:14 . 4-3 Using Floating Point Data File (F8:). 4-4 Add (ADD). 4-5 Updates to Arithmetic Status Bits. 4-5 Subtract (SUB) . 4-5 Updates to Arithmetic Status Bits. 4-5 32-Bit Addition and Subtraction . 4-6 Math Overflow Selection Bit S:2/14. 4-6 Multiply (MUL) . 4-8 Updates to Arithmetic Status Bits. 4-8 Updates to the Math Register, S:13 and S:14 . 4-9 Divide (DIV) . 4-9 Updates to Arithmetic Status Bits. 4-9 Updates to the Math Registers, S:13 and S:14 . 4-10 Double Divide (DDV). 4-11 Updates to Arithmetic Status Bits. 4-11 Updates to the Math Registers, S:13 and S:14 . 4-11 Clear (CLR). 4-12 Publication 1747-RM001G-EN-P - November 2008 Table of Contents iii Updates to Arithmetic Status Bits. 4-12 Square Root (SQR). ..