How To Use ModbusTCP Client To Query Raw Data From WISE-2460 Through WISE-4051 Over ModbusTCP
How To Use ModbusTCP Client To Query Raw Data From WISE-2460 Through WISE-4051 Over ModbusTCP
WISE-2460 supports user to export Acceleration raw data. User can query WISE-2460 through
Modbus/RTU. It also supports using Modbus/TCP client to query raw data from WISE-2460
through WISE-4051 over Modbus/TCP.
1
◼ Solution:
Section 1. Method1: How to use Modbus/RTU client to query raw data from WISE-2460
through Modbus/RTU?
This section will introduce how to use Modbus/RTU client to query raw data from WISE-2460
through Modbus/RTU. The topology is illustrated in Figure1 (a). A Modbus/RTU Client transmits a
raw data request command to the WISE-2460 device. The WISE-2460 then responds the raw data
The steps of querying WISE-2460 raw data through Modbus/RTU shows in Figure 1 (b) and the
User needs to write Modbus coil address 0x0002 to 1 to start collect raw data. In this step,
WISE-2460 collects the vibration raw data first, the raw data contains 32768 samples of Z-axis
2
32-bit raw data. In other words, the total data length is 65536 records (or “words”). Then,
WISE-2460 firmware will save these data into file number 1 which can be queried by user for
[Notice] WISE-2460 triggers raw data recording only once when the Modbus coil address 0x0002
is set to 1. This recorded data remains unchanged unless the Modbus coil address 0x0002 is
triggered again.
Step 2. Confirm the raw data had been prepared and can be queried by another device.
User needs to read Modbus coil address 0x0001, which indicates the Raw data ready status, to
⚫ The value of Modbus coil address 0x0001 = 0: WISE-2460 raw data are not ready.
⚫ The value of Modbus coil address 0x0001 = 1: WISE-2460 raw data are ready, user can start to
When the value of Modbus coil address 0x0001 turns to 1, user can start to query the raw data from
WISE-2460. WISE-2460 allow user to use the Modbus Function Code 20 (0x14): Read File
Record to query raw data. Here is the information about this function code below.
1. Server ID: The WISE-2460 Device ID. In this case, set to “0x01”.
2. Function Code: 1 byte, in this case, set to “0x14” for using “Read File Record” function.
3. Byte Count: 1 byte, the total combined count of bytes in all Sub-Req and not included CRC.
5. File number: 2 bytes, in this case, it must be set to “0x0001” for querying raw data from file
number 1.
3
6. Record Number: 2 bytes, the starting record number within the file.
7. Record Length: 2 bytes, it defines the maximum amount of data transferred in a single
The raw data contains a total of 65,536 records. However, each request can retrieve a
maximum of 0x7C (124 records) due to the length limitation of each request. Consequently,
8. CRC Check: Calculate the Modbus/RTU CRC and swap to Little-Endian format.
Take the first Modbus/RTU request as example, the CRC Calculate of 0x01 0x14 0x07 0x06
0x00 0x01 0x00 0x00 0x00 0x7C is 0x05 0xC5. Swap to Little-Endian format will be 0xC5
0x05.
4
◆ Modbus/RTU Response Data List
Request Server Byte Resp. Ref. CRC
Function Record Data
# ID Count length Type Check
1 0x01 0x14 0xF9 0xF8 0x06 … 0x----
2 0x01 0x14 0xF9 0xF8 0x06 … 0x----
…
81 0x01 0x14 0xF9 0xF8 0x06 … 0x----
82 0x01 0x14 0xF9 0xF8 0x06 … 0x----
…
528 0x01 0x14 0xF9 0xF8 0x06 … 0x----
529 0x01 0x14 0x81 0x80 0x06 … 0x----
✓ Result
Here is the result for sending the first request for querying the raw data through Modbus/RTU.
➢ Request Command
Figure 2. Result of using Modbus/RTU client to query raw data from WISE-2460
5
Section 2. Method2: How to use Modbus/TCP client to query raw data from WISE-2460
This section will introduce how to use Modbus/TCP client to query raw data from WISE-2460
⚫ WISE-2460 processes the request and sends a raw data response back to WISE-4051 (via
Modbus/RTU).
⚫ WISE-4051 receives the response, translates it back to the original format, and sends it back to
[Notice] Currently, WISE-4051 transparent transmission to retrieve Raw Data only supports
Figure 3. Query raw data from WISE-2460 through WISE-4051 over Modbus/TCP
6
The steps of querying WISE-2460 raw data through WISE-4051 over Modbus/TCP shows in Figure
3 (b) and the detailed explanation of each step will be provided below. Be aware that the Modbus
User needs to write Modbus coil address 0x9902 of WISE-4051 to 1 for asking WISE-2460 to
start collect raw data. In this step, WISE-2460 collects the vibration raw data first, the raw data
contains 32768 samples of Z-axis 32-bit raw data. In other words, the total data length is 65536
records (or “words”). Then, WISE-2460 firmware will save these data into file number 1 which can
[Notice] WISE-2460 triggers raw data recording only once when the Modbus coil address 0x9902
of WISE-4051 is set to 1. This recorded data remains unchanged unless the Modbus coil address
Step 2. Confirm the raw data had been prepared and can be queried by another device.
User needs to read Modbus coil address 0x9901, which indicates the Raw data ready status, to
⚫ The value of Modbus coil address 0x9901 = 0: WISE-2460 raw data are not ready.
⚫ The value of Modbus coil address 0x9901 = 1: WISE-2460 raw data are ready, user can start to
When the value of Modbus coil address 0x9901 of WISE-4051 turns to 1, user can start to query the
raw data from WISE-2460 through WISE-4051 over Modbus/TCP. WISE-2460 allow user to use
the Modbus Function Code 20 (0x14): Read File Record to query raw data. Here is the
7
information about this function code below.
1. Server ID: The WISE-2460 Device ID. In this case, set to “0x01”.
2. Function Code: 1 byte, in this case, set to “0x14” for using “Read File Record” function.
3. Byte Count: 1 byte, the total combined count of bytes in all Sub-Req and not included CRC.
5. File number: 2 bytes, in this case, it must be set to “0x0001” for querying raw data from file
number 1.
6. Record Number: 2 bytes, the starting record number within the file.
7. Record Length: 2 bytes, it defines the maximum amount of data transferred in a single
8
✓ Result
Here is the result for sending the first request for querying the raw data through Modbus/RTU.
➢ Request Command
Request Transaction Protocol Server Byte Ref. File Record Record
Length Function
# ID ID ID Count Type NO. Number Length
1 0x0001 0x0000 0x000A 0x01 0x14 0x07 0x06 0x0001 0x0000 0x007C
➢ Get the response data from WISE-2460 through WISE-4051 over Modbus/TCP.
Figure 4. Result of using Modbus/TCP client to query raw data from WISE-2460 through