EasyManuals Logo

Campbell CR310 User Manual

Campbell CR310
321 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #135 background imageLoading...
Page #135 background image
19.2.8.1 Error codes
Modbus defines several error codes, which are reported back to a client from a server.
ModbusClient() displays these codes as a negative number. A positive result code indicates
no response was received.
Result code -01: illegal function
The illegal function error is reported back by a Modbus server when either it does not support
the function at all, or does not support that function code on the requested registers. Different
devices support different functions (consult the device documentation). If the function code is
supported, make sure you are not trying to write to a register labeled as read-only. It is common
for devices to have holding registers where read-only and read/write registers are mapped next
to each other.
An uncommon cause for the -01 result is a device with an incomplete implementation of
Modbus. Some devices do not fully implement parsing Modbus commands. Instead, they are
hardcoded to respond to certain Modbus messages. The result is that the device will report an
error when you try selectively polling registers. Try requesting all of the registers together.
Result code -02: illegal data address
The illegal data address error occurs if the server rejects the combination of starting register and
length used. One possibility, is a mistake in your program on the starting register number. Refer
to the earlier section about register number and consult the device documentation for support
information. Also, too long of a length can trigger this error. The ModbusClient() instruction
uses length as the number of values to poll. With 32-bit data types, it requests twice as many
registers as the length.
An uncommon cause for the -02 result is a device with an incomplete implementation of
Modbus. Some devices do not fully implement parsing Modbus commands. Instead, they are
hard coded to respond to certain Modbus messages. The result is that the device will report an
error when you try selectively polling registers. Try requesting all of the registers together.
Result code -11: COM port error
Result code -11 occurs when the data logger is unable to open the COM port specified. For serial
connections, this error may indicate an invalid COM port number. For Modbus TCP, it indicates a
failed socket connection.
19. Communications protocols119

Table of Contents

Other manuals for Campbell CR310

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Campbell CR310 and is the answer not in the manual?

Campbell CR310 Specifications

General IconGeneral
BrandCampbell
ModelCR310
CategoryData Loggers
LanguageEnglish

Related product manuals