Mitsubishi Electronics FXCPU Video Game Controller User Manual


 
5 Basic Instruction
5.7 MPS, MRD, MPP
74
FXCPU Structured Programming Manual
[Basic & Applied Instruction]
Function and operation explanation
These instructions are convenient in programming branched multi-output circuits.
1. MPS, MRD, MPP (Stack push down, stack read and stack popup)
1) Use MPS instruction to store the intermediate result of operation, and then drive the output Y002.
2) Use MRD instruction to read the stored data, and then drive the output Y003.
MRD instruction can be programmed as many times as necessary.
3) In the final output circuit, use MPP instruction instead of MRD instruction.
MPP instruction reads the stored data described above, and then resets it.
Error
MPS instruction can be used two or more times. However, the difference between the number of MPS
instructions and the number of MPP instructions should be 11 or less, and should be 0 at the end.
Caution
When a circuit is programmed as shown on the left, it is compiled in fact as the program on the right that does
not use MPS, MRD or MPP instruction.
[ ST ]
Y002:= X005 AND MPS(X004);
Y003:= MRD(TRUE) AND X006;
Y004:= MRD(TRUE);
Y005:= MPP(TRUE) AND X007;
X004
X005
X006
X007
Y002
MPS
EN ENO
MRD
EN ENO
MRD
EN ENO
MPP
EN ENO
[Structured ladder/FBD]
MPP
MRD
MPS
MPP
Stack
1
2
3
10
11
4
Y003
Y004
Y005
X000 X001
X003
X002
Y000
Y001
Y002
X000 X001
X003
X002X000
X000
Y000
Y001
Y002
M256 X001
X003
X002M256
M256
X000
Y000
Y001
Y002
M256
Or
Program representing actual operation
(program in the PLC)
MPS
EN ENO
MRD
EN ENO
MPP
EN ENO