Publication 1763-RM001C-EN-P - October 2009
236
File Instructions
LFU - Last In, First Out
(LIFO) Unload
Instruction Type: output
On a false-to-true rung transition, the LFU instruction unloads words or
long words from a user-created file called a LIFO stack. The data is
unloaded using last-in, first-out order (the data in the stack is not cleared
after unloading). Instruction parameters have been programmed in the
LFL - LFU instruction pair shown below.
This instruction uses the following operands:
•
LIFO - The LIFO operand is the starting address of the stack.
•
Destination - The destination operand is a word or long word
address that stores the value which exits from the LIFO stack. The
LFU instruction unloads this value from the last location on the LIFO
stack and places it in the destination address. The address level of
the destination must match the LIFO stack. If LIFO is a word size
file, destination must be a word size file. If LIFO is a long word size
file, destination must be a long word size file.
EU
DN
EM
LFU
LIFO Unload
LIFO
#N7:0
Dest
N7:1
Control
R6:0
Length
1<
Position
0<
LFU
Execution Time for the LFU Instruction
Controller
Data Size
When Rung Is:
True
False
MicroLogix 1100
word
39.34
μ
s
37.06
μ
s
long word
39.97
μ
s
37.09
μ
s
(DN)
(EN)
(DN)
(EM)
LFL
LIFO LOAD
Source
N7:10
LIFO
#N7:12
Control
R6:0
Length
34
Position
9
(EU)
(EM)
LIFO UNLOAD
LIFO
#N7:12
Dest
N7:11
Control
R6:0
Length
34
Position
9
LFU
Destination
Position
N7:11
N7:12
0
N7:13
1
LFU instruction
unloads data from
stack #N7:12 at
position 0, N7:12
N7:14
2
3
4
5
34 words are allocated
for FIFO stack starting
at N7:12, ending at
N7:45
6
7
Source
8
N7:10
9
LFL instruction loads
data into stack
#N7:12 at the next
available position, 9
in this case.
N7:45
33
Loading and Unloading of Stack #N7:12
LFL and LFU Instruction Pair
efesotomasyon.com - Allen Bradley,Rockwell,plc,servo,drive