Mitsubishi Electronics QSERIES Smoker User Manual


  Open as PDF
of 1204
 
7-401
ZPUSH(P),ZPOP(P)
1
2
3
4
6
6
7
8
7.18 Other instructions
7.18.8 Batch save or recovery of index register (ZPUSH(P),ZPOP(P))
When using a High Performance model QCPU/Process CPU/Redundant CPU
When Universal model QCPU is used
ZPOP
(1) Recovers the contents saved in the area starting from the device designated by to the
index register. (When the saved content is read out to the index register, + 0 (the number
of saves made) is decreased by 1.)
Operation Error
(1) In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and
an error code is stored into SD0.
The range for the number of points to be used at and later by the ZPUSH(P) instruction
exceeds the corresponding device range. (Error code: 4101)
The contents of + 0 (number of saves made) is 0 in the ZPOP(P) instruction.
(Error code: 4100)
Program Example
(1) The following program saves the contents of the index register to the fields following D0
before calling the subroutine following P0 that uses the index register.
[Ladder Mode] [List Mode]
Z0
Z1
Number of saves
Z15
Reserved by the
system (2 words)
Z0
+0
+1
+2
+16
+17
+18
+19
+20
Z1
1st nesting
(18 words for the 1st nesting)
2nd nesting
D
Z0
Z1
Number of saves
Z19
Reserved by the
system (2 words)
Z0
+0
+1
+2
+20
+21
+22
+23
+24
Z1
1st nesting
(22 words for the 1st nesting)
2nd nesting
D
D
D
D
D
Step Instruction Device