10: U
SER
C
OMMUNICATION
I
NSTRUCTIONS
10-24
S
MART
AXIS P
RO
/L
ITE
U
SER
'
S
M
ANUAL
FT9Y-B1378
Sample Program – User Communication TXD
This example demonstrates a program to send data to a printer using the user communication TXD2 (transmit) instruction, with the
optional RS232C communication cartridge installed on the port 2 connector of the 24-I/O type SmartAXIS.
System Setup
Cable Connection and Pinouts
The name of BUSY terminal differs depending on printers, such as DTR. The function of this terminal is to send a signal to remote
equipment whether the printer is ready to print data or not. Since the operation of this signal may differ depending on printers,
confirm the operation before connecting the cable.
The SmartAXIS monitors the DSR signal to prevent the receive buffer of the printer from overflowing. For the DSR signal, see "DSR
Input Control Signal Option D8105" on page 10-12.
To Port 2 (RS232C)
RS232C Communication
Cartridge
FT1A-KP1C
Printer
To RS232C Port
Attach a proper connector to the open
end of the cable referring to the cable
connector pinouts shown below.
User Communication Cable 1C
FC2A-KP1C
2.4m (7.87 ft.) long
s
t
u
o
n
i
P
r
o
t
c
e
n
n
o
C
n
i
p
-
9
b
u
s
-
D
s
t
u
o
n
i
P
r
o
t
c
e
n
n
o
C
N
I
D
i
n
i
M
Description
Color
Pin
Pin
Description
Shield
—
Cover
1
NC
No Connection
NC
No Connection
Black
2
1
NC
No Connection
NC
No Connection
Yellow
3
2
DATA
Receive Data
TXD
Transmit Data
Blue
4
3
NC
No Connection
NC
No Connection
Green
5
4
GND
Ground
DSR
Data Set Ready
Brown
6
5
NC
No Connection
NC
No Connection
Gray
7
6
NC
No Connection
SG
Signal Ground
Red
8
7
BUSY
Busy Signal
NC
No Connection
White
9
8
NC
No Connection
•
Do not connect any wiring to the NC (no connection) pins; otherwise, the SmartAXIS and the printer may not work
correctly and may be damaged.
Caution
Description of Operation
Printout Example
The data of counter C2 and data register D30 are printed every minute. A printout
example is shown on the right.
Programming Special Data Register
Special data register D8105 is used to monitor the BUSY signal and to control the
transmission of print data.
Special DR
Value
Description
D8105
3
(011)
While DSR is on (not busy), the SmartAXIS sends data.
While DSR is off (busy), the SmartAXIS stops data transmission.
If the off duration exceeds a limit (approx. 5 sec), a transmission busy
timeout error will occur, and the remaining data is not sent. The
transmit status data register stores an error code 2.
--- PRINT TEST ---
11H 00M
CNT2...0050
D030...3854
--- PRINT TEST ---
11H 01M
CNT2...0110
D030...2124
Содержание FT1A-B12RA
Страница 1: ...FT9Y B1378 5 ...
Страница 2: ......
Страница 208: ...7 DEVICE ADDRESSES 7 16 SMARTAXIS PRO LITE USER S MANUAL FT9Y B1378 ...
Страница 226: ...8 INSTRUCTIONS FUNCTION BLOCKS REFERENCE 8 18 SMARTAXIS PRO LITE USER S MANUAL FT9Y B1378 ...
Страница 340: ...13 SCRIPTS 13 36 SMARTAXIS PRO LITE USER S MANUAL FT9Y B1378 ...
Страница 384: ...APPENDIX A 18 SMARTAXIS PRO LITE USER S MANUAL FT9Y B1378 European Font ISO 8859 1 Cyrillic Font ANSI 1251 ...
Страница 385: ...SMARTAXIS PRO LITE USER S MANUAL FT9Y B1378 A 19 APPENDIX Japanese Font JIS X0201 ...
Страница 386: ...APPENDIX A 20 SMARTAXIS PRO LITE USER S MANUAL FT9Y B1378 ...