17: USER COMMUNICATION INSTRUCTIONS
17-22 OPENNET CONTROLLER USER’S MANUAL
Programming RXD Instruction Using WindLDR
The following example demonstrates how to program a RXD instruction including a start delimiter, skip, BCC, and end
delimiter using WindLDR. Converted data is stored to data registers D20 and D21. Internal relay M20 is used as destination
D1 for the receive completion output. Data register D200 is used as destination D2 for the receive status, and data register
D201 is used to store the receive data byte count.
Receive data example:
RXD sample program:
1. Start to program a RXD instruction. Move the cursor where you want to insert the RXD instruction, and type RXD.
You can also insert the RXD instruction by clicking the User Communication icon in the menu bar and clicking where
you want to insert the RXD instruction in the program edit area, then the Transmit dialog box appears. Click RXD to
change the dialog box to the Receive dialog box.
The Receive instruction dialog box appears.
2. Check that RXD is selected in the Type box and click Port 1 in the Port box. Then, click Insert.
The Data Type Selection dialog box appears. You will program source operand S1 using this dialog box.
3. Click Constant (Hexadecimal) in the Type box and click OK. Next, in the Constant (Hexadecimal) dialog box, type
02 to program the start delimiter STX (02h). When finished, click OK.
STX
(02h)
Skip
“1”
(31h)
“2”
(32h)
“3”
(33h)
“4”
(34h)
“5”
(35h)
“8”
(38h)
BCC
(39h)
ETX
(03h)
BCC
“6”
(36h)
“7”
(37h)
BCC calculation range
Start Stored to D20 End
(H)
BCC
(32h)
(L)
“9”
(39h)
“B”
(42h)
“0”
(30h)
“A”
(41h)
Stored to D21
DelimiterDelimiter
S1
16
D1
M20
I0
SOTU
RXD
1
D2
D200
Communication port: RS232C port 1
Receive completion output: M20
Receive status register: D200
Receive data byte count: D201
Phone: 800.894.0412 - Fax: 888.723.4773 - Web: www.clrwtr.com - Email: info@clrwtr.com