10 - 32 10 - 32
MELSEC-Q
10 DEVICES
(c) Function registers (FD)
• Function registers are used to designate data transfers between the sub-
routine CALL source and the sub-routine program.
• The function register I/O condition is automatically determined by the High
Performance model QCPU. If the sub-routine program data is the source
data, the data is designated as sub-routine input data.
If the sub-routine program data is the destination data, the data is
designated as sub-routine output data.
• 1 point occupies 4 words.
The number of words used depends on an instruction in a sub-routine
program.
A one-word instruction requires 1 word.
CALLP P0 D0
MOV R0 FD0
P0
The data is stored in one point (D0).
A two-words instruction requires 2 words.
DMOV R0 FD0
CALLP P0 D0
P0
The data is stored in two points (D0 and D1).
The destination of 32-bit multiplication/division operation requires 4 words.
CALLP P0 D0
D R0 R10 FD0
P0
The data is stored in four points (D0 to D3).
• Valid devices cannot be used in a sub-routine program that contains
arguments. If devices assigned for function registers are used, values of the
function registers will not correctly be returned to a calling program.
CALLP P0 D0
P0
MOV K0 D3
Since the points (D0 to D3) are used
for FD0, D3 can not be used for the
sub-routine program.
D R0 R10 FD0
• High Performance model QCPU's word data devices can be used.
REMARK
1) For a procedure for using function devices, refer to the QCPU (Q mode)/QnACPU
Programming Manual (Common Instructions).
Содержание QCPU (Q Mode)
Страница 111: ...5 19 5 19 MELSEC Q 5 ASSIGNMENT OF I O NUMBERS MEMO ...
Страница 450: ...App 59 App 59 MELSEC Q APPENDICES MEMO ...