hit counter script

Mitsubishi Electric FX3G SERIES Programming Manual page 315

Programmable controllers
Hide thumbs Also See for FX3G SERIES:
Table of Contents

Advertisement

FX
/FX
/FX
Series Programmable Controllers
3G
3U
3UC
Programming Manual - Basic & Applied Instruction Edition
Program example
1. Example of first-in first-out control
In the example below, the shift write (SFWR) and shift read (SFRD) instructions are used.
1)
Contents of operation
- In this circuit example, a product number to be taken out now is output according to "first-in first-out" rule while
products which were put into a warehouse with their product numbers registered are taken out of the warehouse.
- The product number is hexadecimal, and up to 4 digits. Up to 99 products can be stored in the warehouse.
2)
Program
Button for request to put a
product into warehouse
X020
Button for request to take a
product out of warehouse
X021
M8000
RUN
monitor
Digital switch 0000 to FFFF
1
2
X017 to X000
6
1
0320
2
0232
3
0462
4
0539
5
0142
6
1234
7
0
99
0
100
0
FNC 12
K4X000
D256
MOVP
FNC 38
D256
D257
SFWRP
FNC 39
D257
D357
SFRDP
FNC 12
D357
K4Y000
MOV
Request to
Request to
3
4
put a
take a
product into
product out
warehouse
of warehouse
X20
Command
+1
D257
D258
0320
D259
0232
D260
0462
MOV instruction
D261
0539
D262
0142
D256
1234
D263
D355
SFWRP instruction
D356
is executed.
11 Rotation and Shift Operation – FNC 30 to FNC 39
11.9 FNC 38 – SFWR / Shift Write [FIFO/FILO Control]
→ For a program example of FILO, refer to Section 27.3.
The product number is input from X000 to X017, and
transferred to D256.
Pointer
D257: Data register for storing the product number
K100
D258 to D356 (99 points)
The product number of a product put into first is output
to D357 in response to the request to put a product out
K100
of the warehouse.
The product number to be taken out is output to Y000
to Y017 in a four-digit hexadecimal number.
Seven-segment display unit
X21
Y017 to Y000
Command
MOV instruction
−1
5
D357
0320
0232
0462
0539
0142
0
0
0
SFRDP instruction
0
is executed.
Shift
4
0
0
0
0
0
11
12
13
14
15
16
17
18
19
20
313

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fx3u seriesFx3uc series

Table of Contents