Download MicroLogix 1200 Programming Manual

Transcript
File Instructions
261
LFL - Last In, First Out
(LIFO) Load
Instruction Type: output
LFLLFL
LIFO Load
Source
LIFO
Control
Length
Position
EN
N7:0
#N7:1
R6:0
1<
0<
DN
Execution Time for the LFL Instruction
EM
Controller
Data Size
MicroLogix 1200
word
long word
word
long word
MicroLogix 1500
When Rung Is:
True
25.5 μs
31.6 μs
22.2 μs
27.4 μs
False
10.4 μs
10.4 μs
9.7 μs
9.7 μs
On a false-to-true rung transition, the LFL instruction loads words or long
words into a user-created file called a LIFO stack. This instruction’s
counterpart, LIFO unload (LFU), is paired with a given LFL instruction to
remove elements from the LIFO stack. Instruction parameters have been
programmed in the LFL - LFU instruction pair shown below.
LFL
LIFO LOAD
Source
LIFO
Control
Length
Position
N7:10
#N7:12
R6:0
34
9
LFU
LIFO UNLOAD
LIFO
Dest
Control
Length
Position
#N7:12
N7:11
R6:0
34
9
(EN)
(DN)
(EM)
(EU)
(DN)
(EM)
LFL and LFU Instruction Pair
Destination
N7:11
LFU instruction
unloads data from
stack #N7:12 at
position 0, N7:12
Position
0
1
2
3
4
5
34 words are allocated
for FIFO stack starting
6
at N7:12, ending at
7
N7:45
8
9
N7:12
N7:13
N7:14
Source
N7:10
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
This instruction uses the following operands:
Publication 1762-RM001F-EN-P - October 2009