Rockwell Automation 1775-KA PLC-3 Communication Adapter Module User Manual User Manual

Page 71

Advertising
background image

Addressing Rules and Examples

Chapter 4

4Ć15

Number Systems

Within an expression, direct values are always interpreted as decimal
(base 10) numbers unless you indicate that they are octal (base 8). You
can specify an octal value by starting the number with a leading zero. For
example, 17 in an expression is interpreted as decimal 17, but 017 is
interpreted as octal 17 (or decimal 15).

Operators

This section describes the operators listed in Table 4.B.

Bit Operator

The bit operator allows you to address a specific bit of a value stored
under a user symbol. For example, the statement

$I12:24/7=US_3/4

puts the value (0 or 1) of bit number 4 of user symbol US_3 into input file
12, word 24, bit 7.

The bit address itself can also be a user symbol or an expression. For
example, in the statement

$I12:24/7=US_3/(4+US_1)

the expression (4+US_1) specifies a particular bit within user symbol
US_3.

Note that the value appearing after the bit operator must be within the
range of values allowed for bit addresses. Since user symbols are 32–bit
values, a bit address for a user symbol must be in the range of 0 to 31
(decimal). Bit addresses for data table words must fall in the range of 0 to
15 (decimal).

Logical Operators

The logical operations are complement, AND, and OR. These operations
are used to construct logically true or false conditions. They are generally
used in decision statements such as the IF command (see section titled IF
Command, chapter 6).

Advertising