MANUEL STA46 Modbus TCP
JP Viskovic 30/08/2005 OEE-F 10
1-4-4 I/O memory area Write Single Coil
[Function]
Writes single coil.
[Request]
Length Data
Function Code 1 Byte
0x05
Output Address 2 Bytes 0x0000-0xFFFF
Output Value 2 Bytes 0x0000(OFF) or
0xFF00(ON)
[Response]
Length Data
Function Code 1 Byte
0x05
Output Address 2 Bytes 0x0000-0xFFFF
Output Value 2 Bytes 0x0000 or 0xFF00
Example: write 1 coil. (CIO 0002.02 ON)
Request Response
Data
Data
Function Code 0x05 Function Code 0x05
Output Address(H) 0x00 Output Address(H) 0x00
Output Address(L) 0x22 Output Address(L) 0x22
Output Value(H) 0xFF Output Value(H) 0xFF
Output Value(L) 0x00 Output Value(L) 0x00
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
0CH 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
1CH
31
1
30
0
29
1
28
1
27
1
26
1
25
0
24
0
23
1
22
1
21
0
20
1
19 18 17 16
2CH 47 46 45 44 43 42 41 40 39
38
1
37
0
36
1
35
0
34
1
33
1
32
0
3CH 63 62 61 60 59 58 57 56 55 54 53 52 51 50 49 48
Italic characters show the ON/OFF(1/0) status of its bit condition.