Omron CPM1 - PROGRAMING MANUAL 02-2001 Programming Manual page 279

Hide thumbs Also See for CPM1 - PROGRAMING MANUAL 02-2001:
Table of Contents

Advertisement

CPM2A/CPM2C Communications Functions
(@)RXD(47)
No-protocol Data Reception
RXD(47) is used to receive data from RS-232C devices.
D: Leading address for storing reception data
S
C
C: Control data
N: Number of bytes to receive (BCD: 0001 to 0256)
N
The following program example is for no-protocol communications conducted
through a RS-232C port using TXD(48) and RXD(47) instructions.
If AR 0805 (the RS-232C Transmit Ready Flag) is ON when 00100 turns ON,
then data from DM 0100 to DM 0104 is transmitted from leftmost bytes to right-
most bytes. When AR 0806 (the Reception Completed Flag) turns ON, 256 by-
tes of received data are read and written to DM 0200 from leftmost bytes to right-
most bytes.
00100
00101
AR 0805
AR 0806
Storage order
0: Leftmost bytes first 1: Rightmost bytes first
Communications port
0: RS-232C port 1: Peripheral port
DIFU(13)
No-protocol communications start
00101
@TXD(48)
DM 0100
First word holding send data.
Use the RS-232C port; transmit
#0000
data from leftmost bytes to right-
#0010
most bytes.
Transmit 10 bytes.
RXD(47)
DM 0200
First word to store received data.
Use the RS-232C port; store trans-
#0000
mitted data from leftmost bytes to
rightmost bytes.
#0256
Receive 256 bytes.
Section
4-3
259

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the CPM1 - PROGRAMING MANUAL 02-2001 and is the answer not in the manual?

Subscribe to Our Youtube Channel

Table of Contents