Rockwell Automation 1336T PLC Comm. Adapter, Series B, FRN 2.xx-3.xx User Manual

Page 248

Advertising
background image

9–6

Publication 1336 FORCE–5.13 –– September, 1998

Note: For ease of programming, the value of Operand Y is
displayed in the same units as Operand X. For example, if Operand
X is linked to Velocity Feedback, then the value of Operand Y is
displayed in rpms.

AND, NAND, OR, and NOR

The AND, NAND, OR, and NOR logic operators are special in that
they are not defined as you might expect. In addition, if you are
using these logic operators, you will generally set either Operand X
or Operand Y to a constant value.

Important: If you set either Operand X or Operand Y to 0, the

trigger condition will never be true because the PLC
Communications Adapter Board will not know which
bits you want to monitor.

The following examples are provided to help you better understand
how the PLC Communications Adapter Board interprets these logic
operators. The following examples use an x when the PLC
Communications Adapter Board does not care whether that
particular bit is set. The examples also assume that Operand X is
linked to a 16–bit parameter.

If you use the AND operator and set Operand Y to a mask value of
0000 0100 0001 0011, the trigger condition is only true when
Operand X has a value of xxxx x1xx xxx1 xx11.

If you use the NAND operator and set Operand Y to a mask value of
0000 0100 0001 0011, the trigger condition is only true when
Operand X has a value of xxxx x0xx xxx0 xx00.

If you use the OR operator and set Operand Y to a mask value of
0000 0001 0100 0000, the trigger condition is only true when
Operand X has a value of:

xxxx xxx1 x0xx xxxx
xxxx xxx1 x1xx xxxx
xxxx xxx0 x1xx xxxx.

If you use the NOR operator and set Operand Y to a mask value of
0000 0001 0100 0000, the trigger condition is only true when
Operand X has a value of:

xxxx xxx1 x0xx xxxx
xxxx xxx0 x0xx xxxx
xxxx xxx0 x1xx xxxx.

"

Advertising