DVP-PLC Application Manual (Programming)
DVP-PLC Application Manual (Programming)
Program Example 4:
Use COM2 on the PLC to carry out RS-485 communication.
Connect PLC to VFD-B series AC motor drives (AC motor drive in RTU Mode; PLC in 16-bit mode and M1161 = On).
Write in H12 to parameter address H2000 in VFD-B in advance as the data to be transmitted.
M1002
MOV H86 D1120 Set up communication protocol 9600,7,E,1
D V P - P L C A P P L I C AT I O N MA N U A L 7-99
7 Application Instructions API 50-88
Length = 4
Length = 7
7-100 D V P - P L C A P P L I C AT I O N MA N U A L
7 Application Instructions API 50-88
Length = 4
D V P - P L C A P P L I C AT I O N MA N U A L 7-101
7 Application Instructions API 50-88
Length = 7
Remarks:
1. PLC COM1 RS-232: Associated flags (Auxiliary relays) and special registers (Special D) for communication
instructions RS / MODRD
Flag Function Action
COM1 retain communication settings. Communication settings will be reset
(changed) according to the content in D1036 after every scan cycle. Users can
set ON M1138 if the communication protocol requires to be retained. When User sets and
M1138
M1138 = ON, communication settings will not be reset (changed) when resets
communication instructions are being processed, even if the content in D1036
is changed.
User sets and
M1139 COM1 ASCII / RTU mode selection, ON: RTU mode, OFF: ASCII mode.
resets
COM1 sending request. Before executing communication instructions, users
need to set M1312 to ON by trigger pulse, so that the data sending and User sets and
M1312
receiving will be started. When the communication is completed, PLC will reset system resets
M1312 automatically.
COM1 data receiving ready. When M1313 is ON, PLC is ready for data
M1313 System
receiving
System sets
M1314 COM1 Data receiving completed.
and user resets
COM1 receiving error. M1315 will be set ON when errors occur and the error System sets and
M1315
code will be stored in D1250. user resets
7-102 D V P - P L C A P P L I C AT I O N MA N U A L