L9_ADD: Addition
(Original Document)
Naming
Name in LL984 Editor
Function Block Name
name of legacy 984 instruction
name in other tools and editors like:
  • Type Library Browser
  • Data Editor
  • Animation Tables
  • Search Results
Function Description
The L9_ADD procedure adds unsigned VALUE1 to unsigned VALUE2, then posts the result of the addition into a variable tied to SUM.
The addition operation begins when the input to the ENABLE pin is turned ON. If the OVERFL output turns ON, an overflow in the SUM is indicated. An overflow results when the addition produces a SUM greater than 9,999.
Formula
SUM = VALUE1 + VALUE2
Representation
Parameters
Input Pin
Name
Data Type
Address Range
Meaning
Top
ENABLE
OFF to ON initiates the operation.
Node
Node Type
Name
Data Type
Address Range
Meaning
Top
IN
VALUE1
%IW, %MW
The first value to be added. Can be displayed as an integer constant, or can be stored in a variable located in a %IW input word, a %MW memory word or an unlocated word. Valid range: 0 to 65,535.
Middle
IN
VALUE2
UINT
%IW, %MW
The second value to be added. Can be displayed as an integer constant, or can be stored in a variable located in a %IW input word, a %MW memory word or an unlocated word. Valid range: 0 to 65,535.
Bottom
IN/OUT
SUM
UINT
%MW
The sum of addition. The variable tied to this node can be located in a %MW memory word or an unlocated UINT word.
Output Pin
Name
Data Type
Address Range
Meaning
Top
OVERFL
BOOL
ON indicates a sum overflow: SUM > 9,999. SUM will display an accurate overflowed value up to 19,998 (9,999 + 9,999).