Download fx-232adp communication adapter user manual

Transcript
AMITSUBISHI
loll1
I
INSTALLATION NOTES AND USAGE
PerformancesDeciflcatlon
PROGRAMMABLE CONTROLLERS
mmf
1
[Transmlss~on
standardlbnformlng
t o RS232C, 25p1n D-SUB, connector used
lsolatlon method
IPhoto
coupler lsolatlon
Tranalsslon distancell5m or less (shielded cable recarmended
Cur rent consurpt lon DC 5V 20Cd f ran base u n t~
M8121:Send wait f l a g
D8120:Cmn1cat1on format
M122:Send flag
D8122:Rema1nder of send data
Related f l a g
D8123:Nunberrecelved
of
data
and data registers 118123:Recelve ampletton
M8124:Carrler detectlon
D8124:Header byte
18161:8 b 1 t s / l 6 b l t s changeover
D8125:Term1nator byte
General sDeclfication
~~~~
~~
The connectlons of RS232C devlces vanes wlth each devlce belng used
Check the speclflcatlon 01 the devlce. and connect
Connection examDles
0 Termlnal spectflcatlon devtce
Modem speclflcatlon devlce
When RS232C dewce
When RS232C devlce
When RS232C devlce
When RS232C devlce
uses pms 6,20
uses pms 4,5
uses plns 6,20
uses pms 4 3
FX-232
RS232C
FX-232
RS232C
FX-232
RS232C
FX-232
RS232C
ADP
devlce
ADP
devlce
devm
ADP
ADP
devlce
0-0
8x8 8x8
@----@
General spsclflcatlons (excluding following) ]Sameas those for the FX or FX2C base unlt
Between 25-pln D-SUB and base
Dlelectrlc W I thstand
voltage
1500V AC,lmln
unl t
Megger
1500'4byDC, IMR
lnsulatlon resistance
JY992D48801B
0-0
I
0
For data transmlsslon to be effectwe It IS necessary to match the communlcatlon format between the product and the
RS232C devlce, such as baud rate and panty
1ji 1
Comrnunlcation format D8120 (bit maDmnq)
The FX-232ADP type RS232C adapter (heremafter called 232ADP)
IS connected to the FX(V3 07 or later),FXnc serles PC to exchange serlal
data wlth a personal computer, barcode reader, pnnter, and other varlous
RS232C devlces
Only one 232ADP unit can be connected to one base unlt to the serlal
port provlded at the left slde
Stcp
ransmlt andlor recelve
The buffer slze and locatlon are speclfled by an RS lnstructlon In the PC
Baud r a t e
(bps)
Thls product cannot be comblned wlth speclal adapters such as
FX-8AV,FXz-40AP/AW, or the hke
1blt
I
(0011) :
2blt
300
:
:
:
600
2,400
:
4.800
(0100)
(01 01)
( 0110 )
(0111)
(1000)
(1 0 0 1 )
I
/POWER LED
Common pln out for prlnter communlcatlon
0-0
8x8
b14
b 15
1,200
: 9,600
:19,200
Not used
---
___
%1 The default value IS STX (02H changeable)
%2 The default value IS ETX (03H. changeable)
The comrnunrcatlon format IS set by speclal data reglster D8120
Settlng the communlcatlon format uslng D8120 IS effectwe only at the tlme the RS lnstructlon IS driven, and therefore
If changed after dnvlng, It IS not actually accepted.
*
Recelve data
Send data
The communlcatlon format of the serlal prlnter IS as follows
Datalengrn
uata
length
8 bit
Par I t y
Stop b l t
1 blt
Baud r a t e
2400bps
Even
Sequence Droaram
M8000
Handled by 8-blt data
the DC 5 V power supplted from the base unlt
0
+ [MOV
Used for connectlon wlth FX or FXzc PC
DIN
rad
wldth
0 2 kgdlmenslons
lol1I
0
Baud rate
2 blt
9,600
Terrntnator
19
-1 -L
T
T
[MOV H O T 02011
[MOV H006E D2071
i Wrttlng of send data @
7
Herem, "test Ilne" IS sent
The control h e IS set by b12
b12=0 :No hardware hand shakmg Send and recelve are controlled by software protocol.
b12=1 :Hardware hand shakmg Slgnal lmes ER(DTR)and DR(DSR)are used to control send and recelve of data
Send request @
80
mm (Inch)
The connector ISa 25-pm D-SUB type, and the plnconflguratlon IS as shown below
3
ER (DTR) Send request (Data Terminal Ready)
4
-
6
7
I
IWhen sendlngl
f=JpZJ
u /w
5
I
recelvlng
When
I
Operatlon
@
OSD(TXD)
Frame ground
Send data (232ADp t o S232 devlce)
Recelve
data
( 6 2 3 2 devlce t o 232ADp)
1
2
FG Frame ground
4ettlng of communlcatlon format
[MOV H0065 D2081
35
TERMINAL LAYOUTS
RS (RTS) Send request
*
H138F D81201
lnplt
bO
H138F= 0001 0011 1000 l l l l ( b ~ n a r y )
The settmgs for the above program are as rlght
Llt when transmlttlng data to the RS232C device
connected to the product
RS232C connector
Used for connectlon between the product and RS-232C
devlce
(' 77)
Settlng
0
Par 1 t y
ME002
I
Connection cable
Welghtapprox
[MOV H0067 DE31201 -
An example of settlng DE120 IS shown below
Llt when recelvlng data from the RS232C devlce
connected to the product
I
PROGRAM EXAMPLES
Connectmg 232ADP and a prmter,and prlntlng out the data sent from the PC
FX,FXzc serles PC
I
0
lol1I
0
RS232C devlce
L
0-0
0-0
0-0
@-@
@-@
Thls manual contams text,dlagrams and explanatlons whlch wlll gulde the reader Inthe correct Installation and operatlon
of the FX-232ADP and should be read and understood before attemptmg to Install or use the unlt
Further lnformatlon can be found In FX
theSERIES PROGRAMMING MANUAL and FX SERIES HARDWARE MANUAL
INTRODUCTION
0-0
0--0
0-0
8-8
0--0
ORD(RXD)
Turn on the power of the PC and
pnnter, check the prlnter IS on h e
and swltch the PC to RUN.
XOOO.ON
Not used
Shows RS232C devlce I S ready to recelve
Slgnal
ground
ON whm carrler I S d e t e c t e d for data
recept Ion
Slgnalrequestlng preparatlon for data
send~ngto 6232C devlce.
0
In thls example, CR (HOOOD) and LF
(HOOOA) are wntten at the end of the
message.The prmter moves down
one lme for eachmessage
CR Carnage Return
LF Llne Feed
Turn on XOOO, and drlve RS
lnstructlon
H/W.
ORD(RXD)
X001.ON
Every tlme X001 IS turned on,
the contents of D200 to D210
are sent to the printer, and
"test Ilne" IS prlnted
Note It may be necessary to set the
DIP swltches of your prlnter
Check your prlnter manual for how to
conflgure the serlal communlcatlons
0
Connect 232ADP and apersonal computer,and exchangedata wlththe PC
Preparat Ion of software
Personal computer
0
FX,FX2c s.er1e.s PC
Use ordinary communlcatlon software (termlnal
emulator) or dedlcated program In thepersonal
computer
La1I
0
0
If data transfer does not perform correctly when uslng
the 232ADP, check the operatlon using the following
programs
0
Program when sendlng
0
The communlcatlon formatof the PC for this example
IS as follows
. Send data
Recelve data
Send data
0
Recelve data
Use the communcatlon cable sulted to the connector pln
conflguratlon of the personal computer
(For representatlve wlrlng see sectlon 4 )
H**W
[MOV
I
(
Seauence Droaram
start
[MOV H S S W
D81201
*
0 set themmmunlcabonformaiaccordlng
to tne external d e v m io be used
Is M8123
Oneaderandierminatorarenotatlached
KO1
M8000
0
to D 1 9 before cperatlng
[RS D l 0 0
KO
DO
completion
K201
NO
*
-
Check connectlon wlththe PC
Check power source of PC
Reset M8070, M8071, and
reset power source
89
D500
[MOV
x002
::
[PLS M l ]
M I
::
92
K4YOOO]
Output ofdata
recelve
devlces can be connected
to the communlcatlons port
on the leftof the PC
FX-aAV, FX2-40AW,
FX2-40AP, FX-232ADP
*
I
-
[RST M81231
Check the wmngof control h e .
Check the startt m n g of send, receive
No send orrecelve error
*
There IS a possibility of send crosstalk Check the send and recewe
t m n g wlth the external RS232C devlce
The recelve data length may exceed the recelve data area
*
Check the recelve data lengthand timlng of recelve start
Check that the program
IS not set so that M8122 may be always
on
E
#
Turn on the power of the PC and prmter, check the prlnter
lme and switch the PC to RUN
Power on
XOOO.ON
IS
on
\
S lnstructlon
drive
Turn on XOOO, and drwe RS lnstructlon
\
XOOl.ON--
V
Data send
Personal
computer
Every time X001 ISturned on, the contents of D200 to D210 are
sent to the personal computer,and "test data"IS dlsplayed
\
After recelvmg andstoring datafrom personal computerIn D500,
it IS output to YO00 to YO17 When Input X002 IS turned on, the
recelve completlon flagIS reset
\
1.
@
No
[WhenMa123 IS reset,the PC returns to the Walt state.
1
Guidelines for the safety of the user and protection of the FX.232ADP
This manual has been wrltten to
be used by trained andcompetent personnel Thls IS defined by the
European dlrectlves formachlnery, low voltage and EMC
If In doubt at any stage durlng the lnstallatlonof the FX-232ADP alwaysconsult a professtonal electrlcal
englneer who IS qualified and tramedto the local and natlonal standards
If In doubtabout the operatlonor
use of the FX-232ADP please consultthe nearest Mftsubshl Electrlcdlstrlbutor
Under no clrcumstances WIII Mltsublshl Electrlcbe llable or responslble for anyconsequentlal damage that
may arlse asa result of the lnstallatlonor use of thls equlpment
All example anddlagrams shown Inthls manual are Intended only as an ald to understandlng the text, not
to guarantee operatlon Mltsublshl Electrlcw~llaccept no responslblllty foractual use of the product based
on these lllustratlve examples
Owmg to the very great varlety Inpossible appllcatlonof thls equlpment, you must satlsfy yourselfas to Its
sultablllty foryour speclflc appllcatlon
-
- Check wlrlng of control llne
E
NO
s
Check t m n g of send, recelve
Change RS lnstructlon from OFFto ON
Make sure the recewed data length matches wlth the recelve
area
data
length
I
-
0
Data send
1.
@
3.
I
- Match the communlcatlon format
8
[END]
ODeratlon
Monltor dataIn hexadecmal notatlon(HEX)
Check on/off of M8161
Conflrm send dataformat of the sendlngdevtce
I
Normal
Recelve completlon reset0
96
Check If the send data length
IS not zero when dnving
RS Instmctloq
.
NO
I:
Match the communlcatlon format
.Check the t m n g of control llne
When uslng header
Make sure the external sendlng devlceIS sendlng the header
When usmg termmator
Send request @
M8123
sendlng
[END]
Elimmate VRRD VRSC
lnstructlon andreset power source
D2001
D2011
IS
the termmator
Make sure the termmator value matches
If not operatmg normally when usmgthese programs,
elmmate the cause usmg the flow diagrams shown
followmg
]
*
81
(Monnonng
D8123)
~ e c e ~ vcomplebon
e
reset
Check If receive data length IS exceeding the data
arid iinyih
When usmg termmator
* sure
Make external
the
sendlng
devlce
AII data IS
Recelve
Y ES
completlon
-1
Send request
* Wnte the data to be sent to D 0
Make sure the external sendlng devlce IS normal
*
M8002
D81201
[PLS M01
If the communlcatlon formatof the software cannot be
adjusted to thls setting, adjust the PCand the software
to be the same
[MOVH0074
[MOVH0065
-
Check w m g of RS232C cable
Is RD LED
Program when recelvlng
0 Set the communication format accordlng
!o !he external devtce to be used
p!
Stop bl t
Baud rate
If sendlng and recelvmg uslng these programs
IS
successful, rt IS consldered that the operation fallure
was due to sequence program or communlcatlon
protocol error
M8002
pE [RS DO K 2 0D l 0 0
Par I ty
I
DIAGNOSTICS
O,
*
I
Check wlring of RS232C cable
Check wmng of control llne
Make sure the recelvmg external devlce IS normal
Check the voltage levelof RS232C slgnal (+9 V)
Make sure content of send data and communlcatton format
are establlshed before drlvlng R S lnstructlon
1
Manualnumber
JY992D48801
Manual revlslon B
DECEMBER
Date
2,
* Check the timing of control line
1996
A MITSUBISHI ELECTRIC CORPORATION
HEAD OFFICE MlTSUBlSHl DENKl BLDG MARUNOUCHITOKYO 100 TELEX J24532 CABLE MELCO TOKYO
-
Check the wiringof control line
Match the communlcatlonformat.
Make sure the recelvlng external devlce IS normal
(CR, LF may be needed In some printers.)
Check the data format of sendmg devlce
HlMEJl WORKS 840, CHIYODA CHO, HIMEJI. JAPAN
JY992D48801B
Effectwe DEC 1996
Speclflcatlons are subject
to change without notice