Parametros Modbus
Parametros Modbus
Section 2.1
Modbus Functions
Modbus Functions
16 NVE41308 04/2016
Basics
Modbus Protocol
Introduction
The transmission mode used is RTU. The frame does not contain message header and end of message
bytes.
Principle
The Modbus protocol is a master/slave protocol
Addresses
Address specification:
The drive Modbus address can be configured from 1 to 247.
Address 0 coded in a request sent by the master is reserved for broadcasting. Drives take account of
the request, but do not respond to it.
NVE41308 04/2016 17
Basics
Introduction
The drive supports the following Modbus functions:
Response
Request
For example:
This function can be used to read all drive words, both input words and output words.
Request
Response
Slave no. 03 Number of bytes read First word value Last word value CRC16
Hi Lo Hi Lo Lo Hi
1 byte 1 byte 1 byte 2 bytes 2 bytes 2 bytes
Hi = high-order byte, Lo = low-order byte.
18 NVE41308 04/2016
Basics
For example: read 4 words W3102...W3105 (0C1E...0C21 hex) in slave 2, using function 3, where:
SFr = Switching frequency = 4 kHz (W3102 = 0028 hex)
tFr = Maximum output frequency = 60 Hz (W3103 = 0258 hex)
HSP = High speed = 50 Hz (W3104 = 01F4 hex)
LSP = Low speed = 0 Hz (W3105 = 0000 hex)
Request
Response
Response
Detected error
For example
Request and response(the frame format is identical)
For example: write value 000D hex in word W9001 (2329 hex) in slave 2 (ACC = 1.3 s).
NVE41308 04/2016 19
Basics
Slave no. 10 No. of first word Number of words Number of Value of first word CRC16
bytes
Hi Lo Hi Lo Hi Lo Lo Hi
1 byte 1 byte 2 bytes 2 bytes 1 byte 2 bytes 2 bytes
Response
For example
Write values 20 and 30 to words W9001 and W9002 on slave 2 (acceleration time = 2 s and deceleration
time = 3 s)
Request
Slave Request No. of Number of Number Value of first Value of Second CRC16
no. code first word words of bytes word word
Hi Lo Hi Lo Hi Lo Hi Lo Lo Hi
02 hex 10 hex 23 29 00 hex 02 hex 04 hex 00 hex 14 hex 00 hex 1E hex 73 hex A4 hex
hex hex
Response
Slave no. Response code No. of first word No. of words CRC16
Hi Lo Hi Lo Lo Hi
02 hex 10 hex 23 hex 29 hex 00 hex 02 hex 9B hex B7 hex
For example
20 NVE41308 04/2016
Basics
For example
Default value to be detailed
Request
Response
CRC16
Lo Hi
1 byte 1 byte
NVE41308 04/2016 21
Basics
Diagnostics
Subcode 00 hex: Echo
This function asks the slave being interrogated to echo (return) the message sent by the master in its
entirety.
Subcode 0 A hex: Counter reset
This function resets all the counters responsible for monitoring a slave exchanges.
Subcode 0C hex: Read message counter responsible for counting messages received with checksum
errors.
Subcode 0E hex: Read message counter responsible for counting messages addressed to slave. Read a
word indicating the total number of messages addressed to the slave, regardless of type (excluding
broadcast messages).
Request and response
22 NVE41308 04/2016