Mitsubishi Electric MELDAS C6 Programming Manual page 236

Hide thumbs Also See for MELDAS C6:
Table of Contents

Advertisement

Cautions
When returning from CALL or CALLP command (that is, when executing RET command), the
operation results obtained immediately before will be retained.
Thus, make sure not to program a command following to CALL or CALLP as it may cause an illegal
operation. The example is shown below.
SM3
P252
0
7
X0
8
P10
12
SM32
13
P20
17
18
(1) The program of P10 label is always called.
(2) The operation results when returning from P10 is determined by the results of "LD X0".
(3) "OUT Y0" will be executed after returning from P10. In this time, the X0 state will affect the P10
results.
(4) In the same manner as (3), the X0 state will affect the P20 results.
Correct the above program as shown below.
SM3
P252
0
SM3
4
SM3
9
X0
10
P10
14
SM32
P20
15
19
20
8. Function Commands
CALL, CALLP, RET
- 227 -
Get other manuals https://www.bkmanuals.com
CALL P10
Y0
CALL P20
FEND
INC D0
RET
INC D1
RET
END
CALL P10
Y0
CALL P20
FEND
INC D0
RET
INC D1
RET
END

Advertisement

Table of Contents
loading

This manual is also suitable for:

Meldas c64

Table of Contents