DL06 Micro PLC User Manual, 3rd Edition, Rev. E
5-209
Chapter 5: Standard RLL Instructions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
A
B
C
D
MWX Example
DL06 port 2 has two Special Relay contacts associated with it (see Appendix D for comm port
special relays). One indicates “Port busy”(SP116), and the other indicates ”Port Communication
Error”(SP117). The “Port Busy” bit is on while the PLC communicates with the slave. When
the bit is off, the program can initiate the next network request. The “Port Communication
Error” bit turns on when the PLC has detected an error. Use of this bit is optional. When used,
it should be ahead of any network instruction boxes since the error bit is reset when an MRX
or MWX instruction is executed.
Typically, network communications will last longer than 1 CPU scan. The program must wait
for the communications to finish before starting the next transaction.
NOTE: See Chapter 4, page 4-21, for an RLL example using multiple Read and Write interlocks with
MRX/MWX instructions.
Instruction Interlock bit
C100
MWX
Port Number:
K2
Slave Address:
K6
Function Code:
06-Preset Single Register
Start Slave Memory Address:
40001
Start Master Memory Address:
V2000
Number of Elements:
n/a
Modbus Data type:
584/984 Mode
Exception Response Buffer:
V400
SP116
C100
This rung does a MODBUS write to the first holding register 40001 of slave address
number six. It will write the values over that reside in V2000. This particular function
code only writes to 1 register. Use Function Code 16 to write to multiple registers.
Only one Network instruction (WX, RX, MWX, MRX) can be enabled in one scan.
That is the reason for the interlock bits.
3
Port 2 busy bit Instruction Interlock bit
2
RST
X1
C100
SET