3 DETAILS OF FUNCTION
3.2 MELSEC iQ-R Series Data Link Functions
105
3
mdrTypeRead
This function reads the model code of a CPU module.
■ Format
short mdrTypeRead (long lPath, short sRoute, long lNetNo, long lIoNo, long lStNo, short sCPU, short* psCode)
■ Argument
■ Description
This function reads the model code of the CPU module with the station number specified to the station number (lStNo).
For CPU modules other than the following, the model code is undefined.
Argument Name Description IN/OUT
lPath Path of channel Specify the path of the opened channel. IN
sRoute Access route Specify the access route to target module.
• 0: CC-Link IE Controller Network
• 1: CC-Link IE Field Network
•2: MELSECNET/H
• 3: CC-Link
• 4: Bus interface
IN
lNetNo Network number Specify the network number of target module.
Page 14 Argument specification
IN
lIoNo Start I/O number Specify the start I/O number divided by 16 of the target module.
Page 14 Argument specification
IN
lStNo Station number Specify the station number of target module.
Page 14 Argument specification
IN
sCPU CPU number Specify the target CPU number.
• 0: Control CPU specification
• 1 to 4: Multiple CPU specification
IN
psCode Model code Specify the storage destination (address) of the model code.
(Stores the read model code.)
OUT
Model code (hexadecimal) CPU module
0041H Q02CPU, Q02HCPU
0042H Q06HCPU
0043H Q12HCPU
0044H Q25HCPU
0049H Q12PHCPU
004AH Q25PHCPU
004BH Q12PRHCPU
004CH Q25PRHCPU
004DH Q02PHCPU
004EH Q06PHCPU
0250H Q00JCPU
0251H Q00CPU
0252H Q01CPU
0260H Q00UJCPU
0261H Q00UCPU
0262H Q01UCPU
0263H Q02UCPU
0266H Q10UDHCPU
0267H Q20UDHCPU
0268H Q03UDCPU
0269H Q04UDHCPU
026AH Q06UDHCPU
026BH Q13UDHCPU
026CH Q26UDHCPU
02E6H Q10UDEHCPU
02E7H Q20UDEHCPU