User`s manual
Local Logic Language Syntax
GFK-1742A Chapter 12 Local Logic Language Syntax 12-13
12
Local Logic Bitwise Logical Operators
All logical operations are performed on a bit-by-bit basis, for example the result of a BWAND
operation is composed of 32
and
operations between each of the corresponding bits of the
operands. The logic operators are prefixed with ‘BW’ to highlight the fact that they are not
Boolean operators.
Table 12-4. Bitwise Logical Operators
Operator Meaning
BWAND Bitwise Logical AND
BWOR Bitwise Logical OR
BWXOR Bitwise Logical Exclusive OR
BWNOT Bitwise Logical NOT (one’s-complement)
Expressions using bitwise logical operators may be used in assignment or conditional statements.
Only one bitwise logical operator may be used per expression.
Operator BWAND
Performs a bitwise and of source1 and source2.
Syntax 1
destination := source1 BWAND source2;
Syntax 2
IF source1 BWAND source2 THEN
The BWAND operator syntax has these parts:
Part Description
Destination Any writeable local logic variable except Dxx registers.
source1 Any readable local logic variable/constant except Dxx registers.
source2 Any readable local logic variable/constant except Dxx registers.
Remarks
Syntax 1 is used for assignment, syntax 2 is used in a conditional evaluation.