<< Click to Display Table of Contents >> Navigation: Humidity & Temperature Devices > Transmitter > HF3A > MODBUS - Protocol |
The transmitter can be directly addressed using the MODBUS protocol to request measured temperature values. Parameters highlighted in yellow should be selected according to the table provided below.
Important: In order to communicate directly with the digital signaling of the Transmitter HF3A Advanced is necessary to connect the RXTX+ , RXTX- and the S-GND.
|
Specification RS-485 MODBUS RTU1
Default Settings |
|
Baud rate |
19'200 |
Parity |
None |
Data bits |
8 |
Stop Bits |
1 |
Slave ID |
247 (per default) |
1The values listed in the table represent the default settings. However, these values can be adjusted by the user as needed to suit specific requirements
Probe address |
Command ID |
|
Start address |
|
Number of records |
MODBUS CRC |
0x00 |
0x04 |
0x00 |
0x00 |
0x00 |
0x00 |
0x0000 |
Probe address
0…255, if '0' then all probes respond regardless of the address.The default probe address is 247.
Register |
Protocol |
Name |
Description |
Data type |
30’001 |
30'000 |
Serial Number |
•Serial number of the device (part 1) |
Int. 32-bit |
30’002 |
30'001 |
•Serial number of the device (part 2) |
||
30’003 |
30'002 |
Vendor Name |
•Rotronic (Asci characters)
|
Char |
30’004 |
30'003 |
|||
30’005 |
30'004 |
|||
30’006 |
30'005 |
|||
30’007 |
30'006 |
Product Type |
•HF3A |
Char |
30’008 |
30'007 |
|||
30'009 |
30'008 |
|||
30'010 |
30'009 |
Register |
Protocol |
Name |
Description |
Data type |
30’101 |
30'100 |
Device Flags |
•See amp |
Int. 16-bit |
30’105 |
30'104 |
Measurement flags Value 1 |
•humidity |
Int. 16-bit |
30’106 |
30'105 |
Measurement flags Value 2 |
•temperature |
Int. 16-bit |
30’107 |
30'106 |
Next calibration date |
•unix timestap (part 1) |
Int. 32-bit |
30’108 |
30'107 |
•unix timestap (part 2) |
Current values in 32-bit IEEE754 float format.
Note: These values are changing every measurement cycle, so always read the two corresponding registers in one Modbus command. |
Register |
Protocol |
Name |
Description |
Data type |
31’001 |
31'000 |
Relative Humidity %rH |
•Current humidity value (part 1) |
Float 32-bit |
31’002 |
31'001 |
•Current humidity value (part 2) |
||
31’003 |
31'002 |
Temperature °C |
•Current temperature value (part 1) |
Float 32-bit |
31’004 |
31'003 |
•Current temperature value (part 2) |
||
31’005 |
31'004 |
Dew Point Temperature
|
•Current calculation value (part 1) |
Float 32-bit |
31’006 |
31'005 |
•Current calculation value (part 2) |
||
31'007 |
31'006 |
Frost Point Temperature |
•Current calculation value (part 1) |
Float 32-bit |
31'008 |
31'007 |
•Current calculation value (part 2) |
||
31'009 |
31'008 |
Wet-Bulb Temperature |
•Current calculation value (part 1) |
Float 32-bit |
31'010 |
31'009 |
•Current calculation value (part 2) |
||
31'011 |
31'010 |
Enthalpy |
•Current calculation value (part 1) |
Float 32-bit |
31'012 |
31'011 |
•Current calculation value (part 2) |
||
31'013 |
31'012 |
Psychometric Difference |
•Current calculation value (part 1) |
Float 32-bit |
31'014 |
31'013 |
•Current calculation value (part 2) |
||
31'015 |
31'014 |
Vapour Concentration |
•Current calculation value (part 1) |
Float 32-bit |
31'016 |
31'015 |
•Current calculation value (part 2) |
||
31'017 |
31'016 |
Saturation Vapour Concentration |
•Current calculation value (part 1) |
Float 32-bit |
31'018 |
31'017 |
•Current calculation value (part 2) |
||
31'019 |
31'018 |
Specific Humidity |
•Current calculation value (part 1) |
Float 32-bit |
31'020 |
31'019 |
•Current calculation value (part 2) |
||
31'021 |
31'020 |
Mixing Ratio |
•Current calculation value (part 1) |
Float 32-bit |
31'022 |
31'021 |
•Current calculation value (part 2) |
||
31'023 |
31'022 |
Vapour Partial Pressure |
•Current calculation value (part 1) |
Float 32-bit |
31'024 |
31'023 |
•Current calculation value (part 2) |
||
31'025 |
31'024 |
Vapour Saturation Pressure |
•Current calculation value (part 1) |
Float 32-bit |
31'026 |
31'025 |
•Current calculation value (part 2) |
||
31'027 |
31'026 |
Volume Mixing Ratio |
•Current calculation value (part 1) |
Float 32-bit |
31'028 |
31'027 |
•Current calculation value (part 2) |
Current values in 32-bit IEEE754 float format.
Note: These values are changing every measurement cycle, so always read the two corresponding registers in one Modbus command. |
Register |
Protocol |
Name |
Description |
Data type |
31’101 |
31'100 |
Relative Humidity %rH |
•Current humidity value (part 1) |
Float 32-bit |
31’102 |
31’101 |
•Current humidity value (part 2) |
||
31’103 |
31’102 |
Temperature °F |
•Current temperature value (part 1) |
Float 32-bit |
31’104 |
31’103 |
•Current temperature value (part 2) |
||
31’105 |
31’104 |
Dew Point Temperature
|
•Current calculation value (part 1) |
Float 32-bit |
31’106 |
31’105 |
•Current calculation value (part 2) |
||
31'107 |
31’106 |
Frost Point Temperature |
•Current calculation value (part 1) |
Float 32-bit |
31'108 |
31'107 |
•Current calculation value (part 2) |
||
31'109 |
31'108 |
Wet-Bulb Temperature |
•Current calculation value (part 1) |
Float 32-bit |
31'110 |
31'109 |
•Current calculation value (part 2) |
||
31'111 |
31'110 |
Enthalpy |
•Current calculation value (part 1) |
Float 32-bit |
31'112 |
31'111 |
•Current calculation value (part 2) |
||
31'113 |
31'112 |
Psychometric Difference |
•Current calculation value (part 1) |
Float 32-bit |
31114 |
31'113 |
•Current calculation value (part 2) |
||
31'115 |
31114 |
Vapour Concentration |
•Current calculation value (part 1) |
Float 32-bit |
31'116 |
31'115 |
•Current calculation value (part 2) |
||
31'117 |
31'116 |
Saturation Vapour Concentration |
•Current calculation value (part 1) |
Float 32-bit |
31'118 |
31'117 |
•Current calculation value (part 2) |
||
31'119 |
31'118 |
Specific Humidity |
•Current calculation value (part 1) |
Float 32-bit |
31'120 |
31'119 |
•Current calculation value (part 2) |
||
31'121 |
31'120 |
Mixing Ratio |
•Current calculation value (part 1) |
Float 32-bit |
31'122 |
31'121 |
•Current calculation value (part 2) |
||
31'123 |
31'122 |
Vapour Partial Pressure |
•Current calculation value (part 1) |
Float 32-bit |
31'124 |
31'123 |
•Current calculation value (part 2) |
||
31'125 |
31'124 |
Vapour Saturation Pressure |
•Current calculation value (part 1) |
Float 32-bit |
31'126 |
31'125 |
•Current calculation value (part 2) |
||
31'127 |
31'126 |
Volume Mixing Ratio |
•Current calculation value (part 1) |
Float 32-bit |
31'128 |
31'127 |
•Current calculation value (part 2) |
Example:
Transmit |
F7 04 79 18 00 08 7C 01 |
Receive |
F7 04 10 41 DD EB 15 41 C1 C0 4E 40 8E 29 C0 40 8E 29 C0 E1 91 |
Field |
Bytes |
Value |
Description |
Checksum |
2 |
CRC |
CRC Checksum |
|
|
|
|
RTU number |
1 |
0xF7 |
Modbus RTU Address |
Function code |
1 |
0x04 |
Read Discret Inputs |
Starting address |
2 |
0x7918 |
= 31'000 ( Attention! register number – 1 ) |
Quantity of input registers |
2 |
0x0008 |
= 8, means read 8 registers |
Answer |
|||
Byte count |
1 |
0x10 |
= 16 = 2 * N, means numbers of returned bytes |
Input registers
|
2 * N |
0x41ddeb15 |
= 27.74 %rh Humidity |
0x41c1c04e |
= 24.22 °C Temperature |
||
0x408e29c0 |
= 4.44 °C Dew Point |
||
0x408e29c0 |
= 4.44 °C Frost Point |
For detailed information about Modbus protocol Read Discrete Inputs see:
(http://modbus.org/docs/Modbus_Application_Protocol_V1_1b3.pdf).
Via the Modbus Holding Registers you can read and write device specific data of the TF5A-Digital.
Assisted Modbus commands are Read Holding Registers (0x03), Write Single Register (0x06)
Function 03/06 – Read/Write Single register
Register |
Protocol |
Name |
Description |
Data type |
40'001 |
40'000 |
Device adress |
•Device address (Default 0x00F7) |
Int. 16-bit |
40'002 |
40'001 |
Byte Order |
•Swap modes / Byte Order (Default 0x0000 - No swap) |
Example:
Note: the device answers to address 0. This can be used to get the current device address
Transmit |
00 03 9c 40 00 01 aa 5f |
Receive |
01 03 02 00 01 79 84 |
Field |
Bytes |
Value |
Description |
Checksum |
2 |
CRC |
CRC Checksum |
|
|
|
|
RTU number |
1 |
0x01 |
Modbus RTU Address |
Function code |
1 |
0x03 |
Read Holding Register |
Starting address |
2 |
0x9c40 |
= 40001 ( Attention! register number – 1 ) |
Quantity of Holding registers |
2 |
0x0001 |
= 1, means read 1 register |
|
|||
Byte count |
1 |
0x02 |
= 2 2 * N, means numbers of returned bytes |
Holding register
|
N |
0x0001 |
= 1, current address |
Example:
Note: The device answers with the current Modbus RTU Address, afterward's the address is changed.
Transmit |
F7 06 9C 40 00 01 73 18 |
---|---|
Receive |
F7 06 9C 40 00 01 73 18 |
Field |
Bytes |
Value |
Description |
Checksum |
2 |
CRC |
CRC Checksum |
|
|
|
|
RTU number |
1 |
0x01 |
Modbus RTU Address |
Function code |
1 |
0x03 |
Read Holding Register |
Starting address |
2 |
0x9c40 |
= 40001 ( Attention! register number – 1 ) |
Value |
2 |
0x0001 |
= 1, new Modbus address |
Selectable Swap Modes for Rotronic Devices
Selectable swap modes only for 32-bit Float and 32-bit Integer values based on Little Endian memory organisation.
Value |
Swap Mode |
Source Bytes |
Target Bytes |
0x0000 |
Big endian - No Swap |
[ a b ] [ c d ] |
[ a b c d ] |
0x0001 |
Little endian - byte and word swap |
[ a b ] [ c d ] |
[ d c b a ] |
0x0002 |
Mid-big endian - byte swap |
[ a b ] [ c d ] |
[ b a d c ] |
0x0003 |
Mid-little endian - word swap |
[ a b ] [ c d ] |
[ c d a b ] |
Example:
Transmit |
01 03 9c 41 00 01 fa 4e |
Receive |
01 03 02 00 02 39 85 |
Field |
Bytes |
Value |
Description |
Checksum |
2 |
CRC |
CRC Checksum |
|
|
|
|
RTU number |
1 |
0x01 |
Modbus RTU Address |
Function code |
1 |
0x03 |
Read Holding Register |
Starting address |
2 |
0x9c41 |
= 40002 ( Attention! register number – 1 ) |
Quantity of Holding registers |
2 |
0x0001 |
= 1, means read 1 register |
|
|||
Byte count |
1 |
0x02 |
= 2 = 2 * N, means numbers of returned bytes |
Holding register
|
N |
0x0002 |
= 2, Mid-big endian - byte swap |
Set Swap Mode “Mid-big endian - byte swap”
Transmit |
01 06 9c 41 00 02 76 4f |
Receive |
01 06 9c 41 00 02 76 4f |
Field |
Bytes |
Value |
Description |
Checksum |
2 |
CRC |
CRC Checksum |
|
|
|
|
RTU number |
1 |
0x01 |
Modbus RTU Address |
Function code |
1 |
0x06 |
Write Holding Register |
Starting address |
2 |
0x9c41 |
= 40002 ( Attention! register number – 1 ) |
Value |
2 |
0x0002 |
= 2, Mid-big endian - byte swap |
|
•Serial number (unsigned int): 0…232-1
•Temperature (signed int): -4000…+8500 corresponding to -40.00…+85.00 °C
Probe address |
|
Error code |
MODBUS CRC |
---|---|---|---|
0x00 |
0x84 |
0x00 |
0x0000 |
Error codes |
|
---|---|
0x02 |
Start address and number of records invalid |
0x03 |
Number of records invalid |