WaveShare RS232-RS485 To Ethernet
WaveShare RS232-RS485 To Ethernet
WaveShare RS232-RS485 To Ethernet
RS232/485 TO ETH
User Manual
5/22/19 www.waveshare.com/wiki 1 / 21
RS232/485 TO ETH User Manual
CONTENTS
Features............................................................................................................................................... 4
1. Get Start ........................................................................................................................... 5
1.1. Application Diagram ................................................................................................... 5
1.2. Hardware Design ......................................................................................................... 5
1.2.1. Hardware Dimensions ................................................................................... 5
1.2.2. LED ........................................................................................................................ 6
2. Product Functions........................................................................................................ 7
2.1. Basic Functions ............................................................................................................. 8
2.1.1. Static IP/DHCP .................................................................................................. 8
2.1.2. Reset to default settings ................................................................................ 8
2.2. Socket functions ........................................................................................................... 9
2.2.1. TCP Client ........................................................................................................... 9
2.2.2. TCP Server .......................................................................................................... 9
2.2.3. UDP Client.........................................................................................................10
2.2.4. UDP Server .......................................................................................................11
2.2.5. HTTP Client ......................................................................................................11
2.2.6. WebSocket........................................................................................................12
2.3. Serial port ..................................................................................................................... 13
2.3.1. Serial port basic parameters .....................................................................13
2.3.2. VCOM Application .......................................................................................... 13
2.3.3. Flow Control ....................................................................................................13
2.3.4. Serial package methods ..............................................................................13
2.3.5. Baud rate synchronization .........................................................................13
2.4. Features ......................................................................................................................... 14
2.4.1. Identity packet function ..............................................................................14
2.4.2. Heartbeat packet function .........................................................................14
2.4.3. Non-persistent connection .........................................................................14
2.4.4. Modbus gateway ............................................................................................ 14
2.4.5. Network printing ........................................................................................... 15
2.4.6. Editable Web Server ..................................................................................... 15
3. Parameter Setting ......................................................................................................16
3.1. Setup software ............................................................................................................16
3.2. Web Server ...................................................................................................................17
3.3. AT command ................................................................................................................17
3.3.1. Serial AT command ....................................................................................... 17
5/22/19 www.waveshare.com/wiki 2 / 21
RS232/485 TO ETH User Manual
5/22/19 www.waveshare.com/wiki 3 / 21
RS232/485 TO ETH User Manual
FEATURES
⚫ Support TCP Server, TCP Client, UDP Client, UDP Server, HTTP Client.
⚫ Support RTS/CTS hardware flow control and Xon/Xoff software flow control.
⚫ Support USR-VCOM.
⚫ Support serial port baud rate 600bps~230.4K bps; support None, Odd, Even, Mark, Space
parity way.
⚫ Support Keep-alive.
5/22/19 www.waveshare.com/wiki 4 / 21
RS232/485 TO ETH User Manual
1. GET START
Product link: https://www.waveshare.com/wiki/RS232/485_TO_ETH
5/22/19 www.waveshare.com/wiki 5 / 21
RS232/485 TO ETH User Manual
1.2.2. LED
Table 1 LED
LED Status
POWER Light: Power on
Off: Power off
WORK Blink: Working normally
Off or light: Not working normally
232TX Blink: Sending data to serial(RS232)
Off: No data sending to serial(RS232)
232RX Blink: Receiving data from serial(RS232)
Off: No data receiving from serial(RS232)
485TX Blink: Sending data to serial(RS485)
Off: No data sending to serial(RS485)
485RX Blink: Receiving data from serial(RS485)
Off: No data receiving from serial(RS485)
5/22/19 www.waveshare.com/wiki 6 / 21
RS232/485 TO ETH User Manual
2. PRODUCT FUNCTIONS
This chapter introduces the functions of USR-TCP232-RS232/485 TO ETH as the following
diagram shown, you can get an overall knowledge of it.
Serial Port
USR Identity
Keep-Alive
CLOUD Packet
Packaging
Socket B TCPC/UDPC
Serial Port
Serial Port
Network data Network
Device Serial Port Packaging Webserver Transmission
Websocket
AT Command Mode
ModbusTCP Gateway
Mobus Gateway
5/22/19 www.waveshare.com/wiki 7 / 21
RS232/485 TO ETH User Manual
Static IP: Default setting of module is Static IP and default IP is 192.168.0.7. When user
configures module in Static IP mode, user need set IP, subnet mask and gateway and must pay
attention to the relation among IP, subnet mask and gateway.
DHCP: Module in DHCP mode can dynamically get IP, Gateway, and DNS server address
from Gateway Host. When user connects RS232/485 TO ETH directly to PC, module can’t be set
in DHCP mode. Because common computer does not have the ability to assign IP addresses.
Software: User can also reset to default settings through setup software for RS232/485 TO
ETH.
5/22/19 www.waveshare.com/wiki 8 / 21
RS232/485 TO ETH User Manual
RS232/485 TO ETH supports dual sockets mode. Socket A supports TCP Server, TCP Client, UDP
Server, UDP Client and HTTP Client. Socket B supports TCP Client and UDP Client.
TCP Client provides Client connections for TCP network services. TCP Client device will
connect to server to realize data transmission between the serial port device and server.
According to the TCP protocol, TCP Client has connection/disconnection status differences to
ensure reliable data transmission.
TCP Client mode supports Keep-Alive function: After establishing connection, RS232/485 TO
ETH will send Keep-Alive package in every 15 second to check TCP connection and RS232/485 TO
ETH will disconnect and reconnect to server if any connection exception occurs. TCP Client mode
also supports baud rate synchronization, USR Cloud and Modbus gateway.
RS232/485 TO ETH works in TCP Client mode needs connect to TCP Server and needs set the
parameter: Remote IP/Port. RS232/485 TO ETH works in TCP Client won’t accept other
connection request except target server and will access server with random local port if
configuring local port to 0.
5/22/19 www.waveshare.com/wiki 9 / 21
RS232/485 TO ETH User Manual
RS232/485 TO ETH works in TCP Server mode will listen network connections and build
network connections, commonly be used for communication with TCP clients on a LAN.
According to the TCP protocol, TCP Server has connection/disconnection status differences to
ensure reliable data transmission.
RS232/485 TO ETH works in TCP Server mode will listen local port which user set and build
connection after receiving connection request. Serial data will be sent to all TCP Client devices
connected to RS232/485 TO ETH in TCP Server mode simultaneously.
RS232/485 TO ETH works in TCP Server mode supports 8 client connections at most.
RS232/485 TO ETH also supports Keep-Alive function, baud rate synchronization and Modbus
gateway.
/disconnected. User only needs to configure Remote IP/Port then can realize data transmission.
In UDP Client mode, RS232/485 TO ETH will only communicate with Remote IP/Port. If data
don’t from Remote IP/Port, it won’t be received by RS232/485 TO ETH.
In UDP Client mode, if user configure Remote IP to 255.255.255.255, RS232/485 TO ETH can
achieve UDP broadcast to all network segment and receive broadcast data. User can also
configure Remote IP to xxx.xxx.xxx.255 to realize UDP broadcast in same network segment.
5/22/19 www.waveshare.com/wiki 10 / 21
RS232/485 TO ETH User Manual
In UDP Server mode, RS232/485 TO ETH will change Remote IP every time after receiving
UDP data from a new IP/Port and will send data to latest communication IP/Port.
GET/1.php?data=ABC HTTP/1.1
RS232/485
Serial Device HTTP Server
TO ETH HTTP/1.1 200 OK
Cache-Control: max-age=31104000
Expires: Fri, 18 Aug 2017 03:25:47
GMT Content-Length: 3
ABC
5/22/19 www.waveshare.com/wiki 11 / 21
RS232/485 TO ETH User Manual
In HTTP Client mode, RS232/485 TO ETH can achieve data transmission between serial port
device and HTTP server. User just needs to configure RS232/485 TO ETH in HTTP Client and
configure the HTTP header, URL and some other related parameters, then can achieve data
transmission between serial port device and HTTP server and don’t need care about the HTTP
format of data.
2.2.6. WEBSOCKET
Figure 10 WebSocket
WebSocket function can achieve real-time interaction between RS232 interface and Web
Server and display user data on Web Server.
5/22/19 www.waveshare.com/wiki 12 / 21
RS232/485 TO ETH User Manual
Through this software user can set up connection between RS232/485 TO ETH and virtual
serial to solve the problem that traditional equipment PC software used in serial port
communication way.
⚫ RS232/485 TO ETH serial package time: Default is 4 bytes sending time, range from 0 to 255.
⚫ RS232/485 TO ETH serial package length: Default is 1460 bytes, range from 0 to 1460.
2.4. FEATURES
Identity packet is used for identifying the device when RS232/485 TO ETH works as TCP
client/UDP client. There are two methods to send identity packet.
Identity packet can be MAC address or user editable identity packet. User editable identity
packet should less than 40 bytes.
5/22/19 www.waveshare.com/wiki 14 / 21
RS232/485 TO ETH User Manual
Modbus RTU<=>Modbus TCP: Set RS232/485 TO ETH in TCP Server or TCP Client mode, then
user can set RS232/485 TO ETH with Modbus
5/22/19 www.waveshare.com/wiki 15 / 21
RS232/485 TO ETH User Manual
3. PARAMETER SETTING
There are three ways to configure RS232/485 TO ETH. They are setup software, Web Server
and AT command.
When user want to configure the RS232/485 TO ETH by setup software, user can run setup
software, search RS232/485 TO ETH in same LAN and configure the RS232/485 TO ETH as follow:
After researching RS232/485 TO ETH and clicking RS232/485 TO ETH to configure, user need log
in with user name and password. Default user name and password both are admin. If user keep
the default parameters, it is not necessary to log in.
5/22/19 www.waveshare.com/wiki 16 / 21
RS232/485 TO ETH User Manual
User can connect PC to RS232/485 TO ETH through LAN port and enter Web Server to
configure. Web Server default parameters as follow:
3.3. AT COMMAND
5/22/19 www.waveshare.com/wiki 17 / 21
RS232/485 TO ETH User Manual
network AT command must in same network segment). If user enter network AT command
mode but don’t send any command over 30 seconds, module will exit network AT command
mode. User can enter network AT command mode as follow way:
5/22/19 www.waveshare.com/wiki 18 / 21
RS232/485 TO ETH User Manual
4. CONTACT US
Email:
(order/shipment) sales@waveshare.com
(complaint) complaint@waveshare.com
Skype:
(order/shipment) sales@waveshare
Whatsapp: 86-13148830755
Phone: 86-755-82807524
Fax: 86-755-83042572
Address: Waveshare Electronics 10F, International Science & Technology Building, Fuhong
Rd, Futian District, Shenzhen, China
Website: www.waveshare.com
5/22/19 www.waveshare.com/wiki 19 / 21
RS232/485 TO ETH User Manual
5. DISCLAIMER
This document provides the information of USR-TCP232-RS232/485 TO ETH products, it
hasn’t been granted any intellectual property license by forbidding speak or other ways either
explicitly or implicitly. Except the duty declared in sales terms and conditions, we don’t take any
other responsibilities. We don’t warrant the products sales and use explicitly or implicitly,
including particular purpose merchant-ability and marketability, the tort liability of any other
patent right, copyright, intellectual property right. We may modify specification and description
at any time without prior notice.
5/22/19 www.waveshare.com/wiki 20 / 21
RS232/485 TO ETH User Manual
6. UPDATE HISTORY
⚫ 2019-05-06 V1.0.0 Established.
5/22/19 www.waveshare.com/wiki 21 / 21