Logix 5000 Controllers Function Block Diagram

Programming Manual

Important User Information

Read this document and the documents listed in the additional resources section about installation, configuration, and operation of this equipment before you install, configure, operate, or maintain this product. Users are required to familiarize themselves with installation and wiring instructions in addition to requirements of all applicable codes, laws, and standards. Activities including installation, adjustments, putting into service, use, assembly, disassembly, and maintenance are required to be carried out by suitably trained personnel in accordance with applicable code of practice.

If this equipment is used in a manner not specified by the manufacturer, the protection provided by the equipment may be impaired.

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.

⚠️ WARNING: Identifies information about practices or circumstances that can cause an explosion in a hazardous environment, which may lead to personal injury or death, property damage, or economic loss.

⚠️ 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 consequence.

ℹ️ IMPORTANT: Identifies information that is critical for successful application and understanding of the product. Labels may also be on or inside the equipment to provide specific precautions.

⚡ SHOCK HAZARD: Labels may be on or inside the equipment, for example, a drive or motor, to alert people that dangerous voltage may be present.

? BURN HAZARD: Labels may be on or inside the equipment, for example, a drive or motor, to alert people that surfaces may reach dangerous temperatures.

⚡ ARC FLASH HAZARD: Labels may be on or inside the equipment, for example, a motor control center, to alert people to potential Arc Flash. Arc Flash will cause severe injury or death. Wear proper Personal Protective Equipment (PPE). Follow ALL Regulatory requirements for safe work practices and for Personal Protective Equipment (PPE).

Summary of changes

This manual includes new and updated information. Use these reference tables to locate changed information. Grammatical and editorial style changes are not included in this summary.

Global changes

None in this release.

New or enhanced features

This table contains a list of topics changed in this version, the reason for the change, and a link to the topic that contains the changed information.

Change Topic
Updated Legal notices. Legal notices on page 8
Updated branding. Throughout

Preface

This manual shows how to program Logix 5000 controllers with the function block diagram (FBD) programming language. This manual is one of a set of related manuals that show common procedures for programming and operating Logix 5000 controllers.

For a complete list of common procedures manuals, refer to the Logix 5000 Controllers Common Procedures Programming Manual, publication 1756-PM001.

The term Logix 5000 controller refers to any controller based on the Logix 5000 operating system.

Studio 5000 environment

The Studio 5000 Automation Engineering & Design Environment® combines engineering and design elements into a common environment. The first element is the Studio 5000 Logix Designer® application. The Logix Designer application is the rebranding of RSLogix 5000® software and will continue to be the product to program Logix 5000™ controllers for discrete, process, batch, motion, safety, and drive-based solutions.

A diagram shows the Studio 5000 interface with options like 'Create', 'Open', and 'Explore', and recent projects.

The Studio 5000® environment is the foundation for the future of Rockwell Automation® engineering design tools and capabilities. The Studio 5000 environment is the one place for design engineers to develop all elements of their control system.

Additional resources

These documents contain additional information concerning related Rockwell Automation products.

Resource Description
Industrial Automation Wiring and Grounding Guidelines, publication 1770-4.1 Provides general guidelines for installing a Rockwell Automation industrial system.
Product Certifications webpage, available at http://ab.rockwellautomation.com Provides declarations of conformity, certificates, and other certification details.

Legal notices

View or download publications at http://www.rockwellautomation.com/literature. To order paper copies of technical documentation, contact the local Rockwell Automation distributor or sales representative.

Rockwell Automation publishes legal notices, such as privacy policies, license agreements, trademark disclosures, and other terms and conditions on the Legal Notices page of the Rockwell Automation website.

End User License Agreement (EULA)

You can view the Rockwell Automation End User License Agreement (EULA) by opening the license.rtf file located in your product's install folder on your hard drive. The default location of this file is: C:\Program Files (x86)\Common Files\Rockwell\license.rtf.

Open Source Software Licenses

The software included in this product contains copyrighted software that is licensed under one or more open source licenses. You can view a full list of all open source software used in this product and their corresponding licenses by opening the oss_license.txt file located your product's OPENSOURCE folder on your hard drive. This file is divided into these sections:

The default location of this file is: C:\Program Files (x86)\Common Files\Rockwell\Help\<product name>\Release Notes\OPENSOURCE\oss_licenses.txt.

You may obtain Corresponding Source code for open source packages included in this product from their respective project web site(s). Alternatively, you may obtain complete Corresponding Source code by contacting Rockwell Automation via the Contact form on the Rockwell Automation website: http://www.rockwellautomation.com/global/about-us/contact/contact.page. Please include "Open Source" as part of the request text.

Chapter 1: Program a Function Block Diagram

Introduction

To make it easier to navigate through a function block routine, divide the routine into a series of sheets.

Example

A diagram shows a function block routine divided into four sheets, labeled 'Sheet 1 of 4 motor 1' through 'Sheet 4 of 4 motor 4'.

Choose the function block elements

Use these elements to control a device:

A diagram illustrates the basic elements used to control a device: an Input Reference (IREF), a Function Block, an Output Reference (OREF), an Input Wire Connector (ICON), and an Output Wire Connector (OCON).

Guidelines to choose the function block elements:

To: Use this element:
Supply a value from an input device or tag Input reference (IREF)
Send a value to an output device or tag Output reference (OREF)
Perform an operation on an input value or values and produce an output value or values Function block or function
Transfer data between function blocks when they are:
• Far apart on the same sheet.
• On different sheets within the same routine.
Output wire connector (OCON) and an input wire connector (ICON)
Disperse data to several points in the routine Single output wire connector (OCON) and multiple input wire connectors (ICON)

Choose a tag name for an element

Each function block uses a tag to store configuration and status information about the instruction.

For a:

Tag Specify:
Bit number of a larger data type tag_name.bit_number
Member of a structure tag_name.member_name
Element of a one dimension array tag_name[x]
Element of a two dimension array tag_name[x,y]
Element of a three dimension array tag_name[x,y,z]
Element of an array within a structure tag_name.member_name[x]
Member of an element of an array tag_name[x,y,z].member_name

Where: x is the location of the element in the first dimension. y is the location of the element in the second dimension. z is the location of the element in the third dimension. For a structure within a structure, add an additional member_name.

Define the order of execution

Define execution order (flow of data) by wiring elements together and indicating any input (feedback) wires, if necessary. The location of a block does not affect the order in which the blocks execute.

A diagram shows data flow from output pins to input pins, with wire symbols for SINT, INT, DINT, or REAL values, and for BOOL values (0 or 1).

Data latching

When an IREF specifies input data for a function block instruction, the data in that IREF is latched for the scan of the function block routine. The IREF latches data from program-scoped and controller-scoped tags. The controller updates all IREF data at the beginning of each scan.

A diagram illustrates data latching where an IREF stores the value of tagA for the scan of the function block routine. The stored value is used when Block_01 executes, and the same stored value is also used when Block_02 executes. If the value of tagA changes during execution of the routine, the stored value of tagA in the IREF does not change until the next execution of the routine.

Another diagram shows a similar example where tagA is stored only once at the beginning of the routine's execution and used throughout. With version 11 and later, the same tag can be used in multiple IREFs and an OREF. Because IREFs latch data every scan, all IREFs use the same value even if an OREF obtains a different tag value during execution. For instance, if tagA is 25.4 at the start of a scan, and Block_01 changes it to 50.9, the second IREF wired into Block_02 still uses 25.4 for that scan.

Order of execution

The Logix Designer application automatically determines the order of execution for function blocks in a routine when verifying a routine, verifying a project, or downloading a project.

Define the order of execution by wiring function blocks together and indicating data flow of any feedback wires. If function blocks are not wired together, execution order does not matter as there is no data flow between them.

If blocks are wired sequentially, execution order moves from input to output. A block's inputs must have data available before the controller can execute it. For example, block 2 must execute before block 3 if block 2's outputs feed block 3's inputs.

The order of execution is relative only to blocks that are wired together. Diagrams show groups of blocks that are not wired together, and groups of blocks wired sequentially, illustrating how execution order is determined within these contexts.

Resolve a loop

To create a feedback loop, wire an output pin of a block to an input pin of the same block. For a single-block loop, execution order does not matter.

If a group of blocks are in a loop, the controller may not determine which block to execute first. To identify the execution order, mark the feedback wire with the Assume Data Available indicator. This indicator defines the data flow within the loop, with an arrow showing input to the first block.

A diagram shows a loop with multiple blocks where the controller cannot determine execution order. Another diagram illustrates marking the feedback wire with the Assume Data Available indicator, showing that block 1 uses output from block 3 from the previous scan.

Important Note: Do not mark all wires of a loop with the Assume Data Available indicator.

A diagram shows an example where the Assume Data Available indicator is used correctly (OK), and another where it is not used correctly (Not OK), leading to the controller being unable to resolve the loop.

Resolve data flow between two blocks

When using multiple wires to connect two blocks, use the same data flow indicators for all wires between them.

Diagrams illustrate correct usage (neither wire uses the indicator, or both wires use the indicator) and incorrect usage (only one wire uses the indicator).

Create a one scan delay

Use the Assume Data Available indicator to create a one-scan delay between blocks. Block 1 executes first, using the output from block 2 produced in the previous scan.

A diagram shows block 2 feeding into block 1 with an 'Assume data available' indicator, creating a one-scan delay.

Summary

A function block routine executes in this order.

Identify any connectors

Connectors transfer data from output pins to input pins. Use connectors when:

A diagram shows how connectors (OCON and ICON) transfer data between elements, particularly across sheets or to multiple points.

Rules for using connectors: Each OCON requires a unique name. Each OCON must have at least one corresponding ICON. Multiple ICONs can reference the same OCON, allowing data dispersal.

Define program/operator control

These instructions support the concept of Program/Operator control, allowing simultaneous control from the user program and an operator interface device.

Supported instructions include: Enhanced Select (ESEL), Totalizer (TOT), Enhanced PID (PIDE), Ramp/Soak (RMPS), Discrete 2-State Device (D2SD), and Discrete 3-State Device (D3SD).

Control is determined by inputs like .ProgProgReq (program request to Program control), .ProgOperReq (program request to Operator control), .OperProgReq (operator request to Program control), and .OperOperReq (operator request to Operator control).

The ProgOper output bit indicates the current control mode. Operator control takes precedence over Program control if both request bits are set. Program request inputs take precedence over Operator request inputs, allowing instructions to be locked into a desired control.

Examples are provided showing how to use these inputs to manage control modes, such as locking a Totalizer instruction into Operator control or using ProgProgReq for automatic startup sequences.

A diagram of a Totalizer instruction shows inputs for Program/Operator control. Another diagram illustrates a PIDE (Enhanced PID) controller with numerous input parameters for program and operator control.

Operator request inputs are cleared by the instruction when it executes. Program request inputs are normally not cleared, but can be cleared using the ProgValueReset input.

Add a sheet

To add a sheet to a function block routine:

  1. On the Sheet toolbar, click Add Sheet.
  2. In the Description box, type a description of the sheet, following the IEC-1131 naming standard (max 50 characters).

Add a function block element

Use the Language Element toolbar to add a function block element to a routine.

Steps include clicking the element on the toolbar and dragging it to the desired location on the function block diagram.

Use functions

Use Function Block functions to carry out mathematical, comparison, and logical operations. Functions are similar to instructions but require less memory and may execute faster.

Tip: Function Block functions are available only on CompactLogix 5380, CompactLogix 5480, ControlLogix 5580, Compact GuardLogix 5380, and GuardLogix 5580 controllers.

The FBD Element toolbar provides various functions categorized as:

Create a text box

Create a text box to add notes that clarify the function of an FBD element. Text boxes are stored in the offline project file and not downloaded into controller memory.

Steps involve clicking 'Text Box' on the Language Element toolbar, dragging it to the desired location, double-clicking to enter text, and pressing Ctrl+Enter. Text boxes can be attached to specific elements by clicking a pin symbol.

Language switching

Versions 17 and later of the Logix Designer application support displaying project documentation in multiple localized languages within a single project file. Users can dynamically switch between languages.

Project documentation supporting multiple translations includes component descriptions, equipment phases, trends, controllers, alarm messages, tasks, property descriptions, and rung comments/text boxes.

Connect elements

Show or hide a pin

Function Block instructions have default parameters with hidden pins. Pins can be shown or hidden via the Parameters tab in the Properties dialog box.

Steps involve clicking 'Properties', then selecting or deselecting the 'Vis' (Visible) checkbox for a pin in the Parameters tab, and clicking OK.

Wire elements together

Wire (connect) two elements by clicking the output pin of the first element and the input pin of the other. A green dot indicates a valid connection point.

A diagram shows the process of wiring, identifying the output pin of the first element and the input pin of the second element.

Mark a wire with the Assume Data Available indicator

When blocks are in a loop, the Assume Data Available indicator identifies the feedback wire that determines execution order. To apply it, right-click the wire and select 'Assume Data Available'.

A diagram shows an input wire with an arrow indicating data flow to the first block in a loop, marked with the Assume Data Available indicator.

Assign a tag

Create and assign a new tag

Create a new tag for a connector or assign an existing tag. Steps include double-clicking an operand area, typing a tag name, right-clicking to create a new tag, and selecting usage and data type in the 'New Parameter or Tag' dialog.

A diagram shows the 'New Parameter or Tag' dialog with fields for Name, Description, Usage, Type, Data Type, Scope, and Access. Another diagram shows the 'Select Data Type' dialog and the Tag Browser.

Assign an existing tag

To assign an existing tag, double-click the operand area, select the tag from the dropdown, and use the Tag Browser to select the tag or bit.

Assign an immediate value (constant)

A constant value can be assigned instead of a tag value to an input parameter. This can be done by using an IREF or by entering a value directly in the tag of a block.

Use an IREF

To assign a value to an IREF, add the IREF to the routine, wire it to the input pin, double-click the operand area, and type the value.

Enter a value in the tag of a block

To assign a value to a parameter when a wire connects to its pin, click 'Properties' in the block, enter the value in the 'Value' box on the Parameters tab, and click OK.

Connect blocks with an OCON and ICON

Use an output wire connector (OCON) or input wire connector (ICON) to transfer data between sheets or in complex wiring situations.

Add an OCON

Add an OCON near the output pin supplying the value and wire it to the pin. Double-click the operand area to type a name that identifies the connector.

Add an ICON

Add an ICON near the input pin that receives data from the corresponding OCON and wire it to the pin. Double-click the operand area, click the dropdown, and select the name of the OCON.

Rename a wire connector

Edit the name of an input or output wire connector by right-clicking its operand area and selecting 'Rename Element', then typing the new name.

Rename a connector group

Wire connectors sharing the same name can be renamed. Right-click the desired ICON or OCON operand area, select 'Rename Connector Group', and enter the new name. All instances in the group are updated.

Verify the routine

Periodically verify your routine by clicking the Verify icon on the Standard toolbar. Errors are listed in the Output window. Use F4 to navigate to errors, correct them, and repeat until all errors are resolved. Press Alt+1 to close the Output window.

Index

Rockwell Automation Support

Use these resources to access support information.

Resource Information Link
Technical Support Center Find help with how-to videos, FAQs, chat, user forums, and product notification updates. rok.auto/support
Knowledgebase Access Knowledgebase articles. rok.auto/knowledgebase
Local Technical Support Phone Numbers Locate the telephone number for your country. rok.auto/phonesupport
Literature Library Find installation instructions, manuals, brochures, and technical data publications. rok.auto/literature
Product Compatibility and Download Center (PCDC) Get help determining how products interact, check features and capabilities, and find associated firmware. rok.auto/pcdc

Documentation feedback

Your comments help us serve your documentation needs better. If you have any suggestions on how to improve our content, complete the form at rok.auto/docfeedback.

Waste Electrical and Electronic Equipment (WEEE)

At the end of life, this equipment should be collected separately from any unsorted municipal waste. Rockwell Automation maintains current product environmental information on its website at rok.auto/pec.

Trademarks mentioned include Allen-Bradley, Logix, Rockwell Automation, Rockwell Software, and EtherNet/IP.

Contact information for Rockwell Automation offices in Americas, Europe/Middle East/Africa, and Asia Pacific is provided.

PDF preview unavailable. Download the PDF instead.

1756-pm009 -en-p Rockwell Automation Adobe PDF Library 15.0

Related Documents

Preview Logix 5000 Controllers Produced and Consumed Tags Programming Manual
A comprehensive guide from Rockwell Automation on producing and consuming tags within Logix 5000 controllers. Learn essential techniques for data exchange, configuration, and optimization in industrial automation systems.
Preview Logix 5000 Controllers: Tasks, Programs, and Routines - Rockwell Automation
A comprehensive guide to managing tasks, programs, and routines within the Logix 5000 controller environment. This manual covers essential procedures for programming and operating Logix 5000 controllers, including task prioritization, event handling, and system configuration.
Preview Studio 5000 Smart Object Configurator Quick Start Guide
A quick start guide for Rockwell Automation's Studio 5000 Smart Object Configurator, detailing how to gather and deliver specific data metrics to higher-level systems. Covers installation, configuration, creating models and nodes, managing data types, and exporting/importing configuration values for industrial automation applications.
Preview Logix 5000 Advanced Process Control and Drives Instructions
Comprehensive instructions for Logix 5000 Advanced Process Control and Drives, covering installation, configuration, and operation of Rockwell Automation products.
Preview Logix 5000 Controllers General Instructions Manual
Comprehensive guide for Logix 5000 controllers, covering general instructions, installation, configuration, and operation. Includes detailed information on various instructions and their applications.
Preview Rockwell Automation Logix Hot Backup Solutions for Reduced Downtime
Explore Rockwell Automation's Logix Hot Backup Solutions, featuring ControlLogix and CompactLogix controllers, to enhance system reliability and reduce unplanned downtime in industrial operations.
Preview Rockwell Automation Studio 5000 Automation Engineering & Design Environment
Explore Rockwell Automation's Studio 5000 suite, a comprehensive Automation Engineering & Design Environment designed to enhance productivity, streamline development, and simplify system management for industrial automation. Learn about Architect, Logix Designer, View Designer, Application Code Manager, Logix Emulate, and Simulation Interface.
Preview EtherNet/IP Socket Interface Application Technique
Guide to using the EtherNet/IP Socket Interface with Rockwell Automation's Logix 5000 controllers. This document details communication with non-EtherNet/IP Ethernet devices using MSG instructions, TCP/IP, and UDP protocols, covering programming and troubleshooting.