Technical Note #632

Technical Note #632
Remote Access to MITSUBISHI MELSEC PLC Using a VT-MODEM
Abstract: This document explains the procedure for dialing and establishing communications with an
MITSUBISHI MELSEC “A-Series” A1SJCPU PLC using a SIXNET industrial modem (VT-MODEM#).
A model A1SJCPU PLC from MITSUBISHI can be controlled remotely via an analogue dial-up
telephone line using a SIXNET industrial modem. The A1SJCPU can be programmed to perform
its poll of I/O modules or other devices through the phone connection.
Software Used:
·
·
·
·
MELSEC MEDOC v2.30
SIXNET VT-MODEM Setup Wizard v1.15
Hilgraeve HyperTerminal for Windows
Windows 2000 OS
Hardware Used:
·
·
·
·
·
·
·
(1) PC with a serial port connection to a VT-MODEM-1 via the VT-CABLE-MDM
(1) MITSUBISHI MELSEC A1SJCPU PLC
(1) MITSUBISHI MELSEC A1SJ71UC24-R2 RS232 DB9 Female adapter port
(1) VT-MODEM-2
(1) DB9 gender changer (straight-wired DB9 female-to-male)
(2) VT-CABLE-MDM (straight wired DB9 male to female)
(2) RJ11 telephone cables
Cable Pin-outs:
VT-CABLE-MDM
DB9 Female to PC or Male (with gender changer) to PLC
(DTE)
DCD in
1
RD in
2
TD out
3
DTR out
4
GND
5
DSR in
6
RTS out
7
CTS in
8
RI in
9
DB9 Male to modem (DCE)
ç
ç
è
è
ç
è
ç
ç
1
2
3
4
5
6
7
8
9
DCD out
RD out
TD in
DTR in
GND
DSR out
RTS in
CTS out
RI out
SIXNET • Box 767 • Clifton Park, NY 12065 USA • +1 (518) 877-5173 • FAX +1 (518) 877-8346 • [email protected]
TN632.DOC
PAGE 1 OF 8
REV : NOV 2002
PC and VT-MODEM-1 Windows Setup:
Note: A SIXNET VT-MODEM-1 was used during testing on the local PC running MEDOC software.
However, most internal PC modem cards will function properly as the dialing modem in this
application.
To configure Windows to recognize the VT-MODEM-1, go to Start à Settings à Control Panel à
Phone and Modem options. Next, go to the Modems tab in the Phone and Modem options window, and
then click on Add… Next, check the “Don’t detect my modem; I will select it from list” box and
manually select “Standard 28800 bps Modem” from the modem type list. Refer to screen shots 1 and 2
below for details of how the modems were configured.
Screen Shot 1
Screen Shot 2
Configuring the Hardware and Software:
· A1SJ PLC- Set the three-position toggle switch on the front of the PLC to the “STOP” mode. In the
MELSEC MEDOC v2.30 software, choose the A1S PLC from the PLC option list when creating
your project (See Screen Shot 3). Next, go to Transfer à Setup, and set the port settings as
displayed in Screen Shot 4. Finally, the Interface option in the PLC transfer Menu, shown in the
work area under the Transfer option in the main menu, must be changed to C24. Press F2 and use
the Space Bar to toggle the “Interface” option to C24 (See Screen Shot 5). Save this configuration to
a disk.
· A1SJ71UC24-R2 adapter port- Configure the DIP switches on the port to the configuration shown
in table 1. Set the 15-position (0-F) mode setting switch to position 1.
SIXNET • Box 767 • Clifton Park, NY 12065 USA • +1 (518) 877-5173 • FAX +1 (518) 877-8346 • [email protected]
TN632.DOC
PAGE 2 OF 9
SW03
SW04
SW05
SW06
SW07
SW08
SW09
SW10
SW11
SW12
Write during run
Baud Rate
9600 BPS
Data Bits
Parity
Parity Even/Odd
Stop Bits
Checksum
Table 1
OFF
ON
ON
OFF
ON
ON 8 bits
OFF
OFF
OFF 1bit
ON
Screen Shot 3
Screen Shot 4
SIXNET • Box 767 • Clifton Park, NY 12065 USA • +1 (518) 877-5173 • FAX +1 (518) 877-8346 • [email protected]
TN632.DOC
PAGE 3 OF 9
Screen Shot 5
·
VT-MODEM-1 – Connect the VT-MODEM-1 to the PC via the VT-CABLE-MDM. Using the
SIXNET VT-Modem Setup Wizard choose VT-MODEM-1 in the first window. Select the
appropriate communications port (in this case COM 2) with Hardware flow control. Configure the
Baud Rate for 9600 with 8 data bits, None Parity, and 1 stop bit (See Screen Shot 6).
(Note: The connections in this technical note can also be established using the following port
parameters: 8 data bits, Odd Parity, and 1 stop bit.)
Screen Shot 6
In the “Modem Parameters” setup window, leave all the settings at defaults. Finally, write the
configuration to the modem by clicking on the “Write Configuration to the Modem” button (See
Screen Shots 7 and 8). (Note: Write this configuration to the VT-MODEM-1 only.)
SIXNET • Box 767 • Clifton Park, NY 12065 USA • +1 (518) 877-5173 • FAX +1 (518) 877-8346 • [email protected]
TN632.DOC
PAGE 4 OF 9
Screen Shot 7
·
Screen Shot 8
VT-MODEM-2- Configure the VT-MODEM-2 the same as the VT-MODEM-1, or use the VTMODEM configuration file a1sj_c24_vt2.6ms (if available on your CD). To enable the Self-Dialing
feature in the VT-MODEM-2, check the “Enable Self-Dial” check box in the “Self-Dialing
Parameters” window in the VT-MODEM Setup Wizard and enter the phone number of your
answering modem in the “First Phone #” text box (in this case 24). Use of the other features are
optional, but in this case the ID message “VT-MODEM-2” was used to demonstrate the ID message
feature (See Screen Shot 9). Load the configuration to the modem.
Screen Shot 9
Connecting the Hardware:
· Phone Connections- The two modems were connected to an internal analog phone system through
their Line RJ11 jacks using standard RJ11 telephone cable.
SIXNET • Box 767 • Clifton Park, NY 12065 USA • +1 (518) 877-5173 • FAX +1 (518) 877-8346 • [email protected]
TN632.DOC
PAGE 5 OF 9
·
Connecting the modems to the devices- Connect the VT-MODEM-1 to the computer’s
communications port (COM 2 in this test) via the VT-CABLE-MDM. Connect the VT-MODEM-2 to
the DB9 female connector on the MITSUBISHI MELSEC A1SJ71UC24-R2 RS232 adapter port via the
VT-CABLE-MDM and DB9 gender changer. If using the Self-Dial feature connect a discrete output (1030 VDC) to the “From PLC” (screw terminal 4) input on the VT-MODEM-2. Connection status can be
monitored by linking the “To PLC” (screw terminal 5) output to a discrete input on the “A-Series” PLC.
Establishing the connection through HyperTerminal:
To establish remote communication between the PLC and MEDOC software, a dial-up connection must
be initiated by the VT-MODEM-1. The windows program HyperTerminal was be used to do this.
(Note: To perform this step successfully, MELSEC MEDOC v2.30 and the VT-MODEM setup Wizard
must be closed completely.) Start HyperTerminal, and enter a name (In this case the name is
MITSUBISHI_PLC). In the “Connect To” drop down list select the COM port that the VT-MODEM-1
is connected to on your PC (in this case COM 2). In the “COM 2 Properties” window, configure the
Baud Rate for 9600 with 8 data bits, No Parity, and 1 stop bit (See Screen Shots 9 and 10).
Screen Shot 9
Screen Shot 10
In HyperTerminal’s main window, issue an AT command to verify that the PC and Modem are
communicating. The Modem should send back an “OK”. Then issue an ATDT# command where #
represents the phone number of the VT-MODEM-2 connected to the PLC. When the modems connect
HyperTerminal will display a “Connect 9600” message (See Screen Shot 11). Save the session and
close HyperTerminal completely.
SIXNET • Box 767 • Clifton Park, NY 12065 USA • +1 (518) 877-5173 • FAX +1 (518) 877-8346 • [email protected]
TN632.DOC
PAGE 6 OF 9
Screen Shot 11
Run MELSEC MEDOC v2.30 and open the file that matches the configuration in the “Configuring the
Hardware” section of this technical note. To test that a program can be loaded to the MITSUBISHI
MELSEC A1SJCPU PLC from the PC, go to Transfer à PLC à Medoc>PLC, press enter, and answer
yes to the following questions. When the program has been transferred, MEDOC will display a Transfer
Completed message (See Screen Shot 12).
Screen Shot 12
To disconnect the phone connection, close MEDOC completely, and open the saved session of
HyperTerminal. Type “+ + +” (three plus signs), wait for the modem to send an “OK”, type “ATH”,
SIXNET • Box 767 • Clifton Park, NY 12065 USA • +1 (518) 877-5173 • FAX +1 (518) 877-8346 • [email protected]
TN632.DOC
PAGE 7 OF 9
and then press the Enter button. When the modem sends back an “OK” then the modems have
disconnected (See Screen Shot 13).
Screen Shot 13
Establishing a connection using the Self-Dialing feature:
To establish remote communication between the PLC and MEDOC software using the Self-Dialing
feature, a dial-up connection must be initiated by the remote VT-MODEM-2. The feature is initiated by
activating a discrete input to the “From PLC” input on the VT-MODEM-2. To verify that the
connection is established and the ID message is sent successfully, use HyperTerminal to monitor the
incoming data at the destination modem. In this case, the VT-MODEM-1 was used as the answering
modem. To prepare for the connection, start Windows HyperTerminal (see previous section). To
initiate the Self-Dialing sequence, apply a continuous supply of 10-30 VDC to the “From PLC” input
on the VT-MODEM-2. When the Self-Dialing feature is enabled, the Power LED on the modem
should blink rapidly. You should see the following messages in your HyperTerminal window: Ring,
Connect 9600, and ID String (See Screen Shot 14). To hang-up the connection, disconnect the 10-30
VDC on the “From PLC” input on the modem, and the modem will hang-up automatically.
SIXNET • Box 767 • Clifton Park, NY 12065 USA • +1 (518) 877-5173 • FAX +1 (518) 877-8346 • [email protected]
TN632.DOC
PAGE 8 OF 9
Screen Shot 14
Conclusion:
This test successfully established communications between a PC and A1SJ via SIXNET industrial
modems.
SIXNET • Box 767 • Clifton Park, NY 12065 USA • +1 (518) 877-5173 • FAX +1 (518) 877-8346 • [email protected]
TN632.DOC
PAGE 9 OF 9