Composition of message, 2 composition of message – Dwyer UXF3 User Manual
Page 13
- 9 -
5.2
Composition of Message
Command message and response message consist of 4 fields ; Station No., Function code, Data and Error check
code. And these are sent in this order.
Station No. (1 byte)
Function code (1 byte)
Data (2 to 133 bytes)
Error check code (CRC-16) (2 bytes)
Fig. 5-1 Composition of message
In the following, each field is explained.
(1) Station No.
Station No. is the number specifying a slave station. When RS-485 interface is used, the command message
is received and operated only by the slave station (FSV) whose station No. matches with the No. set in “Station
No.”
For details of setting the parameter “Station No.,” refer to Chapter 4.
(2) Function code
This is a code to designate the function executed at a slave station.
For details, refer to Section 5.4.
(3) Data
Data are the data required for executing function codes. The composition of data varies with function codes.
For details, refer to Chapter 6.
A register number is assigned to each data in the flowmeter. For reading/writing
the data by communication, designate the register number.
Note that the register number transmitted on message is expressed as its relative address.
The relative address is calculated by the following expression.
Relative address
=
©
¨
§
¹
¸
·
The lower 4 digits of the register
number
−1
For example, when the resister number designated by a function code is 40003,
Relative address = (lower 4 digits of 40003) – 1
=
0002
is used on the message.
(4) Error check code
This is the code to detect message errors (change in bit) in the signal transmission.
On the MODUBUS protocol (RTU mode), CRC-16 (Cycric Redundancy Check) is applied.
For CRC calculation method, refer to Section 5.5.