16ć9, 1 wordćtoćfile and – Rockwell Automation 1772-LP3 PLC - 2/30 Programmable Controller Programming and Operations Manual User Manual
Page 288

File Logic Instructions
Chapter 16
16Ć9
Figure 16.6
WORDĆTOĆFILE LOGIC Operations
Operation
AND, OR, XOR
1
2
3
4
5
6
File B
1
2
3
4
5
6
File R
In this diagram, a logic operation is being performed on the word
and step three of File B and the result stored in step three of File R.
3
6
Position
File Length
Data Table Word
This instruction performs an AND operation on the contents of a specified
word in the data table and a word from File B. It places the result of the
operation into the corresponding word of File R (Figure 16.6).
The logic operation AND compares each bit in the word to the
corresponding bit in the File B word. If the compared bits are both 1, a 1 is
stored in the corresponding bit and word in File R. If the bits are both other
than 1, a 0 is stored in the corresponding bit in File R (Table 16.D).
Table 16.D
Truth Table for Logical WORDĆTOĆFILE AND
Corresponding Bit In
Bit In Word
File B
File R
1
1
0
0
1
0
1
0
1
0
0
0
Instruction Overview:
Key sequence: [FILE] 15
Output
instruction
Requires 5 words of user program
16.2.1
WordĆtoĆFile AND