5
Categories and Use of Basic Application Instructions
DVP-PM Application Manual
5-85
API
Mnemonic Operands
Function
100
MODRD
Read Modbus Data
Controllers
20PM
10PM
Bit Devices
Word Devices
Program Steps
Type
OP
X Y M S K H
KnX KnY KnM KnS T
C
D
V
Z
S
1
*
*
*
S
2
*
*
*
n
*
*
*
MODRD: 7 steps
Operands:
S
1
: Device address
S
2
: Data address
n
: Data length
Explanations:
1. Range
of
S
1
: K0 ~ K254
2. Range
of
n
: K1
≦
n
≦
K6.
3. MODRD is an instruction exclusively for peripheral communication equipment in MODBUS ASCII/RTU mode.
The built-in RS-485 communication ports in Delta VFD drives (except for VFD-A series) are all compatible with
MODBUS communication format. MODRD can be used for communication (read data) of Delta drives.
4. If the address of
S
2
is illegal for the designated communication device, the device will respond with an error, PLC
will record the error code in D1130 and M1141 will be ON.
5. The feedback (returned) data from the peripheral equipment will be stored in D1070 ~ D1085. After data
receiving is completed, PLC will check the validity of the data automatically. If there is an error, M1140 will be
ON.
6. The feedback data are all ASCII codes in ASCII mode, so PLC will convert the feedback data into hex data and
store them in D1050 ~ D1055. D1050 ~ D1055 is invalid in RTU mode.
7. If peripheral device receives a correct record (data) from PLC after M1140/M1141 = ON, the peripheral device
will send out feedback data and PLC will reset M1140/M1141 after the validity of data is confirmed.
8. Flags: M1120 ~ M1129, M1140 ~ M1143.
Program Example 1:
Communication between DVP-PM and VFD-B series AC motor drive (ASCII mode, M1143 = OFF)
MOV
D1120
H87
M1002
SET
M1120
M1127
Receiving
completed
Set communication protocol as 9600, 8, E, 1
Retain communication protocol
Set receiving time-out as 100ms
Processing received data
Reset M1127
Sending request
X1
X0
MODRD
K1
H2101
K6
Set communication instruction:
D
Data address: H2101
D
ata length: 6 words
evice address: 01
PLC converts the received ASCII data in
D1070~D1085 into Hex data and stores them
into D1050~D1055
MOV
D1129
K100
SET
M1122
RST
M1127
Summary of Contents for DVP-10PM
Page 1: ......
Page 45: ...2 Hardware Specifications and Wiring DVP PM Application Manual 2 30 MEMO...
Page 125: ...3 Functions of Devices in DVP PM DVP PM Application Manual 3 80 MEMO...
Page 341: ...8 Application Examples DVP PM Application Manual 8 2 Trajectory 3 Trajectory 4...
Page 427: ...9 Electrical CAM DVP PM Application Manual 9 74...
Page 437: ...10 Encrypting User Program DVP PM Application Manual 10 10 MEMO...
Page 458: ...11 G code Application DVP PM Application Manual 11 21 B O100 main program...
Page 561: ...14 Appendix DVP PM Application Manual 14 4 MEMO...