
Chapter 8 Communication Functions
8-64
2) Example program 1
It’s supposed that MASTER-K120S main unit is the master and it reads Coil Status of the station no. 17, a Modicon product.
The master reads status of the Coil 00020 ~ 00056 of the slave station no. 17. The Coil of the slave station is supposed to
be as follows and the data that are read is saved in D1000
Coil
59 58 57 56 55 54
53
52
51
50
49
48
47
46
45 44 43 42 41
40
Status
X X X 1
1
0
1
1
0
0
0
0
1
1
1
0
1
0
1
1
Hex
1 B 0 E B
Coil
39 38 37 36 35 34
33
32
31
30
29
28
27
26
25 24 23 22 21
20
Status
0
0
1
0
0
1
1
0
1
0
1
1
1
1
0
0
1
1
0
1
Hex
2
6
B
C
D
•
The status of Coil 57, 58, 59 are redundancy.
•
Data is sent starting from the low bit by byte unit. If the deficient bit of a byte is filled with 0. An example of sending the
above data is as Following example 1.
Example 1) CD B2 0E 1B
①
It designates slave station and function code (No. of station : h11(17) , function code : h01)
②
Address setting
- Address ‘0’ at MODBUS protocol means address ‘1’ actually .So if you want to designate address ‘20’ , write
address ‘19’
③
Reading number setting ( Reading number is 37 from 20 to 56.)
④
This is MODBUS Communication instruction.
- Data is sent starting from the low bit by byte unit. If the deficient bit of a byte is filled with 0. An example of sending
the above data is as follows.
- The data transmission starts lower byte. The remnant part of byte is filled with ‘0’
⑤
Stored data at D1000,D1001,D1002 are :
Device
Stored data
D1000
h CD 6B
D1001
h B2 CE
D1002
h 00 1B
③
④
②
①
Содержание MASTER-K 120S Series
Страница 26: ...Chapter 4 Names of Parts 4 3 2 K7M DRT60U 3 K7M DT60U 4 1 2 40 points main unit Standard 1 K7M DR40U ...
Страница 27: ...Chapter 4 Names of Parts 4 4 2 K7M DRT40U 3 K7M DT40U 4 1 3 30 points main unit Standard 1 K7M DR30U ...
Страница 28: ...Chapter 4 Names of Parts 4 5 2 K7M DRT30U 3 K7M DT30U 4 1 4 20 points main unit Standard 1 K7M DR20U ...
Страница 29: ...Chapter 4 Names of Parts 4 6 2 K7M DRT20U 3 K7M DT20U 4 1 5 30 points main unit Economic 1 K7M DR30UE ...
Страница 138: ...Chapter 7 Usage of Various Functions 7 54 c Program ...
Страница 306: ...Appendix 3 External Dimensions App3 2 2 Slim type G7E DC08A G7E RY08A G7F ADHB G7F DA2V G7F RD2A ...