D1-N Series Servo Drive User Manual Modbus Communication
HIWIN MIKROSYSTEM Corp. 14-3
Table14.2.2
Request Data Length Value
Function Code 1 Byte 03h
Starting Address 2 Bytes 0x0000~0xFFFF
Register Number 2 Bytes 1~125
Response Data Length Value
Function Code 1 Byte 03h
Byte Count 1 Byte 2 x N
Register Value 2 x N Bytes
Error Data Length Value
Error Code 1 Byte 83h
Exception Code 1 Byte 01h, 02h, 03h, 04h
Note:
N is the number of registers.
Table14.2.3
Exception Code Definition Description
01h Illegal function The function code is not supported.
02h Illegal data address Try to read an illegal register.
03h Illegal data value The number of registers is over 125.
04h Servo device failure
The request contains incomplete data.
For instance, the controller only
requests 16 bits of a 32-bit parameter.
Table 14.2.4 is an example of reading registers 0x006B ~ 0x006D. The content of register 0x006B is
2 bytes. Its value is 02 2Bh. The content of 0x006C is 2 bytes. Its value is 00 00h. The content of
0x006D is 2 bytes. Its value is 00 64h.
Table14.2.4
Command Response Error
Starting
address
Register 0x006B
CRC
Register
number
Register 0x006C
CRC
Register 0x006D
CRC