Mitsubishi Q00JCPU User Manual page 920

Hide thumbs Also See for Q00JCPU:
Table of Contents

Advertisement

APPENDICES
<Before transition>
Main routine
program
END
App
- 131
Appendix 5 Method of replacing High Performance model QCPU with Universal model QCPU
(c) Program after replacement
In the sequence program after replacement, three programs are required as
shown below.
A sample program can be downloaded from the MELFANSweb.
<After transition>
Main routine
program
P1
Subroutine
program
I31
Interrupt
program
Figure App.7 Program execution
1) Main routine program
• Replace the PR instruction with the CALL instruction so that a subroutine
program is called.
• Output string storage device ( "D0" in the program below) cannot be
specified directly with the CALL instruction.
• Use the ADRSET instruction to acquire the indirect address for the CALL
instruction.
• Y device ( "Y100" in the program before replacement shown in (b)) cannot
be specified directly as output Y number with the CALL instruction. Specify
the output Y number in integer.
• An interrupt program is used to output character codes via the output
module. Enable the execution of interrupt program using the
EI instruction.
Figure App.8 Sample program
Output strings and output string storage address are set.
FEND
Initial processing
RET
The strings stored in D0 are output.
IRET
END
The strings stored in D0 or later
are output to Y100 to Y108.
An execution of interrupt program is
enabled.

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents