Modbus – IAI America ROBO Cylinder Series User Manual

Page 197

Advertising
background image

6. Modbus

ASCII

189

Modbus

(5) Sample query

A sample query that reads addresses 9000

H

to 9009

H

in a RC controller of axis No. 0 is shown

below:

Query: 01039000000A62 [CR][LF]

Field

ASCII mode

fixed character string

Converted ASCII code

data [H]

Header

‘:’

3A

Slave address [H]

‘0’, ‘1’

3031

Function code [H]

‘0’, ‘3’

3033

Start address [H]

‘9’, ‘0’, ‘0’, ‘0’

39303030

Number of registers [H] ‘0’, ‘0’, ‘0’, ‘A’

30303041

Error check [H]

‘6’, ‘2’ (in accordance

with LRC calculation)

3632

Trailer

‘CR’, ‘LF’

0D0A

The response to the query is as follows.

Response: 010314000000000000B80162002000800031C7000800111C [CR][LF]

Field

ASCII mode

fixed character string

Converted ASCII code data [H]

Header

‘:’

3A

Slave address [H]

‘0’, ‘1’

3031

Function code [H]

‘0’, ‘3’

3033

Number of data bytes [H] ‘1’, ‘4’ (20 bytes = 10 registers) 3134

Data 1 [H]

‘0’, ‘0’, ‘0’, ‘0’, ‘0’, ‘0’, ‘0’, ‘0’

3030303030303030

Data 2 [H]

‘0’, ‘0’, ‘0’, ‘0’

30303030

Data 3 [H]

‘B’, ‘8’, ‘0’, ‘1’

42383031

Data 4 [H]

‘6’, ‘2’, ‘0’, ‘0’

36323030

Data 5 [H]

‘2’, ‘0’, ‘0’, ‘0’

32303030

Data 6 [H]

‘8’, ‘0’, ‘0’, ‘0’

38303030

Data 7 [H]

‘3’, ‘1’, ‘C’, ‘7’

33314337

Data 8 [H]

‘0’, ‘0’, ‘0’, ‘8’, ‘0’, ‘0’, ‘1’, ‘1’

3030303830303131

Error check [H]

‘1’, ‘C’ (in accordance with LRC

calculation)

3143

Trailer

‘CR’, ‘LF’

0D0A

Note The data of the response example is simply an example and will vary depending on

various conditions.

Advertising