Download Atop Serial-Ethernet Server GW51E

Transcript
Atop ABLELink® Single Port
Serial Server GW51E-MINI
User Manual
Version 1.0
2004/07/01
Tel: 886-3-5508137
Fax: 886-3-5508131
www.atop.com.tw
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
IMPORTANT ANNOUNCEMENT
The information contained in this document is the property of Atop Technologies, Inc. and is supplied for
the sole purpose of the operation and maintenance of products of Atop Technologies, Inc. No part of this
publication is to be used for any other purposes, and it is not to be reproduced, copied, disclosed,
transmitted, stored in a retrieval system, or translated into any human or computer language, in any form,
by any means, in whole or in part, without the prior express written consent of Atop Technologies, Inc.
Published by
Atop Technologies, Inc.
2F, No. 146, Sec. 1, Tung-Hsing Rd.
Jubei City, Hsinchu 302
Taiwan, R.O.C.
Tel: 886-3-5508137
Fax: 886-3-5508131
www.atop.com.tw
Copyright © 2003 Atop Technologies, Inc. All rights reserved.
All other product names referenced herein are registered trademarks of their respective companies.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
1 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
Contents
1. INTRODUCTION .........................................................................................3
1.1 PACKAGING ........................................................................................................................................... 3
1.2 APPLICATION CONNECTIVITY................................................................................................................... 4
2. HARDWARE INSTALLATION ....................................................................4
3. SOFTWARE CONFIGURATION .................................................................4
3.1 DEFAULT SETTINGS ................................................................................................................................ 4
3.2 TCP/IP PORT NUMBER .......................................................................................................................... 5
3.3 CONFIGURATION SET BY MONITOR.EXE UTILITY ........................................................................................ 5
3.4 CONFIGURATION SET BY WEB BROWSER .................................................................................................. 5
3.5 CONFIGURATION SET BY HYPER TERMINAL CONSOLE UTILITY ................................................................... 8
3.6 VIRTUAL COM MODE............................................................................................................................. 9
3.6.1 Setup of a virtual COM driver ...........................................................................................................9
3.6.2 Virtual COM communication ...........................................................................................................10
4. START WRITING YOUR OWN APPLICATIONS......................................12
4.1 PREPARING THE SYSTEM ..................................................................................................................... 12
4.2 RUNNING THE SAMPLE PROGRAM ........................................................................................................ 13
5. DIAGNOSTICS .........................................................................................15
5.1 USE STANDARD TCP/IP UTILITY PING COMMAND .................................................................................. 15
5.2 USE MONITOR.EXE CONFIGURATION UTILITY PROGRAM ......................................................................... 15
5.3 USE TCPTEST.EXE OR TCPTEST2.EXE SAMPLE PROGRAM ............................................................. 16
APPENDIX A: GW51E-MINI SINGLE PORT SERIAL SERVER
SPECIFICATIONS.........................................................................................17
A.1 HARDWARE SPECIFICATIONS ................................................................................................................ 17
A.2 SOFTWARE SPECIFICATIONS ................................................................................................................ 18
APPENDIX B: GW51E-MINI CONNECTION PIN ASSIGNMENT ................19
B.1 Ethernet Port (RJ-45) ........................................................................................................................19
B.2 RS-232 DB9 Connector Pin Assignment...........................................................................................19
B.3 DB9 Male to male adapter pin out.....................................................................................................20
APPENDIX C CONFIGURATION UTILITY...................................................21
C.1 RUN THE UTILITY ................................................................................................................................. 21
C.2 DETECT OPERATIONAL DEVICES .......................................................................................................... 21
C.3 CONFIGURE DEVICES .......................................................................................................................... 22
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
2 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
1. Introduction
Atop GW51E-MINI Single Port Serial Server is a gateway between Ethernet (TCP/IP) and RS-232
communications. It allows almost any serial device to be connected to a new or existing Ethernet network.
The information transmitted by GW51E-MINI is transparent to both host computers (Ethernet) and devices
(RS-232). Data coming from the Ethernet (TCP/IP) is sent to the designated RS-232 port and data being
received from RS-232 port is sent to the Ethernet (TCP/IP) transparently.
In the computer integration manufacturing or industrial automation area, the Atop GW51E-MINI Single
Port Serial Server is used for field devices to direct connect to Ethernet network. Terminal Server (main
control program run in GW51E-MINI) transforms whatever data received from RS-232 to TCP port then
connects devices to the Ethernet network via a single application program or multiple application
programs.
Many control devices provide the ability to communicate with hosts through RS-232, however, RS-232
serial communication has its limitations. For one, it is hard to transfer data through a long distance. With
Atop GW51E-MINI, it is possible to communicate with a remote device in the Intranet environment or even
in the Internet and thus, increases the communication distance dramatically.
Flexible configuration options enable this unit to be setup remotely over Ethernet web browser, or Window
utility.
1.1 Packaging
Atop Ethernet-Serial Server x 1
Atop Ethernet-Serial Server quick start guide x 1
Power adapter AC 100-240 to DC 5V x 1
Product CD containing configuration utility and sample programs x 1
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
3 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
1.2 Application Connectivity
GW51E-MINI supports two connection modes, i.e. TCP server mode and Virtual Com server mode. Each
link mode is fit to deferent applications.
2. Hardware Installation
Plug in DC 5V 200mA, and the RUN LED will blink if GW51E-MINI functions normally.
Prepare necessary cables, hub, power cord and RS-232 connector.
Connect a serial device to a serial port of GW51E-MINI, make sure the right connection of RS-232.
Use monitor.exe configuration utility in the product CD or diskette to diagnose GW51E-MINI. If it
starts up successfully, you are able to find the IP and MAC addresses of GW51E--MINI. You can
change the network parameters of GW51E-MINI to join your LAN by changing its IP address,
gateway IP address and subnet mask.
3. Software Configuration
3.1 Default Settings
Atop GW51E-MINI Single Port Serial Server is shipped with default settings shown in the Following
table:
Property
Default Value
IP Address
10.0.50.100
Gateway
10.0.0.254
Subnet Mask
255.255.0.0
User Name
Admin
Password
Null
COM 1
9600,None,8,1,No flow control, buffer disabled, packet delimiter timer 2ms
Link 1
Type: TCP Server, Listen port 4660, Filter=0.0.0.0, Virtual COM disabled
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
4 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
NOTE: Atop provides a default button to restore system settings including IP address, gateway IP
address and subnet mask etc. to the defaults. Press and hold the default button for 5 seconds till
the server reboots.
3.2 TCP/IP Port Number
Port number 4660 is default of GW51E-MINI and is associated with serial port COM1. After your
application program connects to the TCP port 4660 of GW51E-MINI, data being sent to this TCP
connection from your application program are transparent to the COM1 of GW51E-MINI. Vice versa is
also true.
3.3 Configuration set by monitor.exe utility
Use monitor.exe that comes with the product CD or diskette to configure the network parameters of
GW51E-MINI. As you can see from the following picture, you can change IP address, gateway IP
address, subnet mask, user ID and password of GW51E-MINI from the utility. For more details of the
utility please refer to Appendix-C Configuration Utility.
3.4 Configuration set by web browser
It is also possible to modify various settings through the web server interface. To do so, please follow
the steps below.
Log in to the system
1.From web browser, type in the IP address of GW51E-MINI in the URL.
Example: http://10.0.50.100
2.The following authentication screen appears. Please type in user name and password then click on OK.
The user name is admin and password is null by default.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
5 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
3.The following overview page appears.
Networking setup
Click on the “Networking” link and the following screen appears.
This page indicates the default static IP address, gateway IP address, subnet mask information of
GW51E-MINI. Please note that any setting change made on this page will not take effect until you restart
device.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
6 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
Change the password
1.Click on the “Security” link and the following screen appears.
2.Please input the old password in the “Old Password” field, input the new password in the “New
Password” and the “Verified Password” fields. Then click on “Save Configuration” to update the
password.
Note: You can press the default button of product to reset password to the default value.
COM1 Setup
Click on the “COM1” link and the following screen appears. Fill in COM1 parameter information under
COM1 field then click on “Save Configuration” button to save the changes.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
7 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
3.5 Configuration set by Hyper Terminal console utility
1. Power off GW51E-MINI.
2. Set the switch from ‘NORMAL’ to ‘CONSOLE’.
3. Use a PC to connect to GW51E-MINI RS-232 port
4. Power on GW51E-MINI.
5. Open a Hyper Terminal program from your computer Start menu -> Programs -> Accessories ->
Communication -> Hyper Terminal, set COM2 parameters as follows.
-
Baud rate: 9600 bps
-
Data bit: 8 bits
-
Parity: None
-
Stop bit: 1bit
-
Flow control: None
Note:
At present time baud rate is fixed at 9600 bps for console port communication, RS-232C parameters
of your computer COM port and GW51E-MINI must be the same.
6. Once Hyper Terminal is connected, type in username and password then the following Hyper Terminal
window appears. The default username and password are ‘ atop03’ and ‘admin800’.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
8 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
3.6 Virtual COM Mode
Virtual COM driver mode for windows converts COM data to LAN data to control the RS-232 port on a
GW51E-MINI via the LAN. By creating virtual COM ports on the PC, Atop Virtual COM redirects the
communications from the virtual COM ports to an IP address and port number on a GW51E-MINI that
connects the serial line device to the network. The following figure is Atop Virtual COM connection
diagram.
PC
Serial Line
HUB
Serial Device 1
Serial Line
Physical COM1
Serial Device 2
Physical COM2
Serial Line
COM3
(Virtual COM Port)
COM4
(Virtual COM Port)
COM5
(Virtual COM Port)
COM6
(Virtual COM Port)
OS Driver Level
Serial Device 3
Serial Line
Serial Device 4
TCP/IP Network
:
:
GW51E-MINI
COM256
(Virtual COM Port)
3.6.1 Setup of a virtual COM driver
Correspondence OS
Atop Virtual COM driver can be used on Windows XP, Windows 2000, Windows NT 4.0 SP5 or later,
Windows Me or Windows 98, Microsoft NT/2000 Terminal Server.
Installation
Make sure you have turned off all anti-virus software before beginning the installation. Run
AtopVcom.exe program included in the CD to install Atop Virtual COM for your operating system.
Uninstalling
1.
From Windows Start menu select Setting, Control Panel, Add/Remove Programs.
2.
Select Serial IP for ATOP in the list of installed software.
3.
Click the Add/Remove button to remove the program, or from Windows start menu select
programs, Serial IP for ATOP, Uninstall Serial IP for ATOP to remove the program.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
9 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
3.6.2 Virtual COM communication
3.6.2.1 Enable virtual COM on GW51E-MINI
From web browser access to GW51E-MINI by typing its IP address, click on COM1 link to access COM
page, on the top half of the page click on “TCP Server” and enable virtual COM by putting a check in front
of the “Enable” button, then type in the local port number in the “Local Port” field as indicated in the
following figure:
3.6.2.2 Run Serial/IP for ATOP program on monitoring PC
In the Window Start Menu, select the Serial/IP for ATOP program group and select Serial/IP for ATOP
Configuration. The configuration window is shown as following:
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
10 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
At right is a sample Virtual COM Control Panel window. At the left is the list of the COM ports that you
have selected (in the Select Ports window) for use by the Virtual COM Redirector. If you wish to change
ports appeared in this list, use the Select Ports button.
Each COM port has its own settings. When you click on a COM port, the Control Panel display changes
to reflect the settings for that COM port.
Note: When you change settings for a COM port, the changes are effective immediately. There is no
separate confirmation dialog to confirm or cancel your changes.
Configuring Virtual COM Ports
You configure each Serial/IP COM port as follows:
1.
Select a COM port in the list.
2.
For IP Address of Server, enter a numeric IP address for the serial server.
3.
For Port Number, enter the TCP port number that the serial server uses to provide its serial
ports to the network.
4.
For Server Credentials, the default is No Login Required. If your serial server does require a
login by the Virtual COM Redirector, the Virtual COM Redirector needs to provide a username
and/or password every time an application tries to use the serial server.
5.
Click the Configuration Wizard button and then click the Start button that appears in the wizard
window. This important step verifies that the Virtual COM Redirector can communicate with the
serial server using the settings you have provided. If the Log display does not show errors, click
the Use Settings button in the wizard, which makes the recommended settings effective and
returns you to the Control Panel to continue with the following steps.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
11 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
6.
For Connection Protocol, the setting must match the TCP/IP protocol that the serial server
supports. The Configuration Wizard is usually able to determine the correct setting.
For COM Port Options, the settings must match the COM port behavior expected by the PC
application that will use this COM port. The Configuration Wizard will recommend a combination of
settings.
4. Start Writing Your Own Applications
Before you start writing your host applications or programs to interact with GW51E-MINI, please make
sure you have done the following.
4.1 Preparing The System
1. Properly connect GW51E-MINI hardware including power, Ethernet and RS-232 cables.
2. Properly configure the parameters of GW51E-MINI including connection type, IP address, gateway
IP address, and network mask accordingly (see chapter 2 Hardware Installation section).
3. Configure GW51E-MINI as TCP Server using default TCP port number 4660.
4. The host (PC) application program must be configured as a TCP client and connects to
GW51E-MINI with designated TCP port number 4660 for COM1.
5. Make sure GW51E-MINI is running by checking the running status through monitor.exe
configuration utility.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
12 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
4.2 Running The Sample Program
Sample programs written in VB and VC++ included in package are provided for your reference, source
codes are also included. Test program can be found in the product CD or diskette under the directory of
\sample\vb_ap\ and \sample\vc_ap respectively.
There are two test programs, TCPTEST written in Visual Basic and TCPTEST2 written in Visual C++.
TCPTEST in Visual Basic
This sample program is written in Visual Basic 5.0 with Winsock Controls. It shows you how to send and
receive data between host (PC) and GW51E-MINI via Ethernet in two socket ports.
Run Visual Basic and open sample program tcptest.vbp, after the program is started successfully, you can
start testing functions. For more information, please press Help in the program to get detail explanation.
Note: Please be sure the Microsoft visual studio family software is installed on the computer. Otherwise
the sample program will not run.
1
2
3
4
Status
Status
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
13 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
TCPTEST2 in Visual C
To start the program, please type in the following command in the command line prompt:
TCPTEST2 IP_Address Port_Number
The command tcptest2 10.0.50.100 4660 brings you to connect to a TCP server of IP address
10.0.50.100 and port number 4660, the received data is displayed on the screen and the data typed in is
sent to the TCP server of the designated port number. You can also send binary data in hex format with a
leading character “\”. For example, “\00” and “\FF” represent ASCII code 0 and 255 respectively.
You can also use modem to connect to the serial server. Command "AT\Od" sends standard AT command
to the modem which in return responds with "OK\0D\0A" message to the host application.
Always use '=' then Enter key to exit the program.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
14 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
5. Diagnostics
There are several ways you can check on the status and availability of GW51E-MINI.
5.1 Use Standard TCP/IP Utility ping Command
From Windows Start menu, select Run and type in “ping <serial Server IP address>”.
If the connection is established, the Reply messages are displayed, otherwise it will indicate Request
timed out.
5.2 Use monitor.exe Configuration Utility Program
Use monitor.exe configuration program that comes with the product CD or diskette to check on the status
of GW51E-MINI. The status can be read from “AP version” column of the tool.
Status
Descriptions
S
The system is configured as a TCP Server and not yet connected.
A
The TCP Server and is connected.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
15 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
For example, ‘s’ means that COM1 is server mode and is not connected.
5.3 Use TCPTEST.EXE or TCPTEST2.EXE Sample Program
Use sample programs TCPTEST.EXE and TCPTEST2.EXE that comes with the product CD or diskette to
check on the status of GW51E-MINI. Please refer to chapter 4.2 to run the sample programs.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
16 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
Appendix A: GW51E-MINI Single Port Serial Server specifications
A.1 Hardware Specifications
Specifications
CPU
8-bit Embedded CPU
50MHz
Flash Memory
128K Bytes
SRAM
16K Bytes
EEPROM
512 Bytes
Watch Dog Timer
1.02 second hardware auto reset
Serial Port
Communication
One serial port
Connector: DB9 Female cable
TxD+, RxD+, RTS-, CTS-, GND
Parameters
1) Baud-rate: 1200 bps ~ 115000 bps
2) Parity: None, Even, Odd, Mark, Space
3) Data bits: 7,8
4) Stop bits: 1,2
5) Flow Control: Hardware CTS/RTS, Software Xon/Xoff
Please note the communication will not be established if parameters are
set as:
1.) Parity: None
2.) Data bits: 7
3.)
Stop bits: 1
Power Requirement
5.0 Vdc , 200mA
Temperature
Operation range:
Storage range:
Humidity
20%~90% non-condensing
Dimension
40.0mm X 77.6 X 23.0 mm
Material
Metal housing
0℃ to 60℃
-20℃ to 85℃
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
17 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
A.2 Software Specifications
Item
Protocol
Configuration
Specifications
TCP/IP, HTTP, ICMP, BOOTP
Configuration information for both TCP/IP and serial ports is kept in the
EEPROM.
Configuration utilities of Windows 95/98/NT are provided for configuring
settings.
Ethernet web browser
Virtual com driver mode
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
18 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
Appendix B: GW51E-MINI Connection Pin Assignment
B.1 Ethernet Port (RJ-45)
1. Category 5 UTP cable, 8 core wire.
2. RJ45 Connector.
3. RJ45 Pin Assignment
Pin Assignment
568A Definition
568B Definition
Pin1
Green-White
Orange-White
Pin2
Green
Orange
Pin3
Orange-White
Green-White
Pin4
Blue
Blue
Pin5
Blue-White
Blue-White
Pin6
Orange
Green
Pin7
Brown-White
Brown-White
Pin8
Brown
Brown
You can choose either 568A or 568B definition. If you want to make a crossover cable, you should use
568A and 568B definition respectively in each terminal of a UTP cable.
B.2 RS-232 DB9 Connector Pin Assignment
Pin#
RS-232 Female
Full Duplex
2
TXD
3
RXD
5
SG (Signal Ground)
7
CTS
8
RTS
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
19 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
B.3 DB9 Male to male adapter pin out
P1
P2
1
2
3
4
5
6
7
8
9
1
2
3
4
5
6
7
8
9
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
20 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
Appendix C Configuration Utility
The configuration utility monitor.exe comes with the product CD or diskette is the main utility program to
demonstrate and configure GW51E-MINI’s settings.
C.1 Run the utility
Start the program under Windows 95/98/NT/2000 environment and the following window appears.
Figure C1. Main window of monitor.exe utility program
C.2 Detect Operational Devices
You may do the following steps to detect devices currently available on the network.
1. Start monitor.exe utility program.
2. Select an item from the Broadcast IP list.
3. Specify a number in the Wishes box.
4. Click on the Invite button. This will display all the devices information you have requested.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
21 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
C.3 Configure Devices
You may use monitor.exe configuration utility to configure the settings of devices on the network. To do
so, please follow the steps below.
1. Repeat the steps in the section of C.2 to bring up the devices information.
2. Select the device you want to configure from the IP Address column, click on the Config button, a
configuration window will popup as shown in Figure C2:
Figure C2. Configuration dialog box
3. After you click the “Configure Now” button, the target device will return an ACK message indicating
the modification is successful as shown in the following:
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
22 / 24
User manual Version 1.0
ABLELink® Single Port Serial Server GW51E-MINI
Please note monitor.exe version 2.4 and above requires gw21le.dll library to function properly.
The following table lists the functional descriptions for all the fields.
Field Name
Field Descriptions
Broadcast IP
Except for the default IP 255.255.255.255, other items (IPs) are read from the file
“seg.cfg”. This field specifies a detecting IP range. It may be a designated IP or a
broadcast IP.
Wishes
Specifies minimum number of the devices you wish to get reply from after sending
an Invite request. If there is not as many as devices responding to your invitation,
the system repeatedly sends invitation until your request is fulfilled.
Reply
Indicates the actual number of devices this utility program detected.
Retry
Specify the number of times that an Invite request is re-sent.
Locate
Locate the specified device.
Reset
Reset the selected device.
Config
Configure the selected device.
Exit
Exit this utility.
IP Address
Indicate the IP address of the device that replied to your request.
Leading tag “!” stands for IP address collision, possibly caused by duplicated
IP addresses on the network.
Leading tag “?” stands for Mac address collision, possibly caused by
duplicated Mac addresses on the network.
MAC Address
Indicates the MAC address of responding device.
Gateway
Indicates the IP address of the gateway.
Subnet Mask
Indicates the TCP/IP network mask.
OS
Indicates the OS version of the responding device.
AP Version
Indicates the AP version of the responding device.
Model
Indicates the model number of the responding device. This field is only available for
monitor.exe version 2.0 and above.
Copyright © 2003 Atop Technologies, Inc.
All rights reserved. Designed in Taiwan.
23 / 24