![Mitsubishi Programmable Controllers FX-232ADP Скачать руководство пользователя страница 6](http://html1.mh-extra.com/html/mitsubishi-programmable-controllers/fx-232adp/fx-232adp_user-manual_1812267006.webp)
PROGRAM EXAMPLES
• Receive data
FX, FX
2C
series PC
Send
• Send data
●
Connecting 232ADP and a printer,and printing out the data sent from the PC.
Common pin out for printer communication
Sequencer program
Operation
X000,ON
X000,ON
Power on
RS instruction
drive
Data send
Turn on the power of the PC and
printer, check the printer is on line
and switch the PC to RUN.
Turn on X000, and drive RS
instruction.
Every time X001 is turned on, the
contents of D200 to D210 are
sent to the printer, and
"test line" is printed.
●
In this example, CR (H000D) and LF
(H000A) are written at the end of the
message.The printer moves down
one line for each message.
CR: Carriage Return
LF: Line Feed
Note:It may be necessary to set the
DIP switches of your printer.
Check your printer manual for how to
configure the serial communications.
●
The communication format of the serial printer is as follows.
POWER
RUN
BATT¥V
L
SG
24+
RUN
COM
COM
N
PROG E
CPU E
SD
RD
POWER
M8000
M8002
X000
X001
M 0
[ MOV H0067 D8120 ]
Setting of communication format
②
RS instruction drive
③
[ RS D200 K11 D500 K0 ]
[ PLS M0 ]
Handled by 8-bit data
①
[ MOV H0074 D200 ]
Writing of send data
④
Herein, "test line" is sent.
[ MOV H0065 D201 ]
[ MOV H006E D207 ]
[ MOV H0065 D208 ]
[ MOV H000D D209 ]
[ MOV H000A D210 ]
[ SET M8122 ]
[ END ]
0
3
9
19
22
Send request
⑤
80
M8161
…
…
…
…