Omron SYSMAC C200H-ASC02 Operation Manual page 96

Ascii unit
Hide thumbs Also See for SYSMAC C200H-ASC02:
Table of Contents

Advertisement

Example Programs
Example 11
PC Program
SW1
SW1
Start
10300
ASCII busy
Remarks:
Two lot size areas, stored in PC DM words 0000 and 0001, are retrieved and
printed.
Connect the printer to port 2 and set the baud rate to 4,800 bps.
Purpose:
To use PC interrupts to direct execution of the ASCII Unit
ASCII Unit Program
10
OPEN #2,"LPRT:(47)"
MOV
20
PC READ "2I4" ;X,Y
30
PC GET I, J
#0100
40
IF J = 1 THEN GOTO 100
100
50
IF J = 2 THEN GOTO 200
60
GOTO 30
MOV
100
PRINT #2,"DATA1 = ";X
#0200
100
200
PRINT #2,"DATA2 = ";Y
MOV
#0002
101
MOV
#0000
102
10001
WRITE flag
Section 6-1
87

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents