EasyManua.ls Logo

Siemens SIMATIC S7-200 - Example of First-In-First-Out Instruction for Simatic LAD, STL, and FBD

Siemens SIMATIC S7-200
606 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
SIMATIC Instructions
9-111
S7-200 Programmable Controller System Manual
A5E00066097-02
First-In-First-Out
The First-In-First-Out instruction removes the first entry
in the table (TBL), and moves the value to location DATA.
All other entries of the table are shifted up one location.
The entry count in the table is decremented for each
instruction execution.
Error conditions that set ENO = 0: SM1.5 (empty table),
SM4.3 (run-time), 0006 (indirect address), 0091 (operand
out of range)
This instruction affects the following Special Memory bits:
SM1.5 is set to 1 if you try to remove an entry from an
empty table.
Inputs/Outputs Operands Data Types
TABLE VW, IW, QW, MW, SW, SMW, LW, T, C, *VD, *AC, *LD INT
DATA VW, IW, QW, MW, SW, SMW, LW, AC, AQW, T, C, *VD, *AC, *LD WORD
First-In-First-Out Example
LAD STL
Application
LD I4.1
FIFO VW200, VW400
I4.1
FIFO
EN
DATA VW400VW200 TBL
5431
VW400
After execution of FIFO
Before execution of FIFO
0006
0003
5431
8942
1234
xxxx
xxxx
xxxx
VW200
VW202
VW204
VW206
VW208
VW210
VW212
VW214
TL (max. no. of entries)
EC (entry count)
d0 (data 0)
d1 (data 1)
TL (max. no. of entries)
EC (entry count)
d0 (data 0)
d2 (data 2)
0006
0002
8942
1234
xxxx
xxxx
xxxx
xxxx
VW200
VW202
VW204
VW206
VW208
VW210
VW212
VW214
d1 (data 1)
FBD
FIFO
EN
DATA VW400VW200 TBL
I4.1
ENO
ENO
Figure 9-34 Example of First-In-First-Out Instruction for SIMATIC LAD, STL, and FBD
L
A
D
S
T
L
OUT
FIFO
EN
TBL DATA
FIFO TABLE, DATA
F
B
D
ENO
222 224
✓✓
221 226

Table of Contents

Other manuals for Siemens SIMATIC S7-200

Related product manuals