Ethernet Communication Module DVPEN01-SL
6.3Setting up IP and Communicating through WPLSoft
Application | Setting up network parameters of | |
|
|
|
Network | (1) | IP of |
requirement | (2) | Subnet mask: 255.255.255.0; Gateway: 192.168.0.1 |
(3)If
(4)
1.The connection
DVPEN01
PC
2. See 6.1 for how to set up the communication. Download the program to PLC.
M1002
MOV K0 D0
MOV H4 D1
MOV HC0A8 D2
MOV HFF00 D3
MOV HFFF D4
MOV H1 D5
MOV HC0A8 D6
T0 | K100 | K69 | D0 | K7 |
END
Explanations:
•Use M1002 to trigger all the settings. When
•The IP address is to be set as 192.168.0.4. Therefore, write H’0004 into D1 and H’C0A8 into D2. (K192 = H’C0, K168 = H’A8, K0 = H’00, K2 = H’02)
•The subnet mask is to be set as 255.255.255.0. Therefore, write H’FF00 into D3 and H’FFFF into D4. (K255 = H’FF)
•The gateway is to be set as 192.168.0.1. Therefore, write H’0001 into D5 and H’C0A8 into D6. (K1 = H’1)
36 |