BTECH RS232 Serial To TCP IP Ethernet Converter User Manual

June 14, 2024
BTECH

BTECH RS232 Serial To TCP IP Ethernet Converter

Get Started

Product link: 875-000072 Serial to Ethernet Converter

Application Diagram

Figure 2 Application diagram
Application Diagram

Hardware Design

Hardware Dimensions

Figure 3 Hardware dimensions
. Hardware Design

DB9 Pin definition

Pin 2 3 5 1, 4, 6, 7, 8 9
Definition RXD TXD GND NC Default NC, can be used as power pin

**Figure 4 DB9 Pin

**

RS422/RS485 Pin definition

**Figure 5 RS422/RS485 pin definition

RS422: R+/R- are RS422 RXD pins and T+/T- are RS422 TXD pins. RS485: A/B are RS485 RXD/TXD pins.
**

LED
Figure 6 LED

Indicator Status
PWR On: Power on

Off: Power off
WORK| Flash a period every one second: Working normally
Flash a period every 200ms: Upgrading status
Off: Not working
LINK| LED for Link function. Link function can only work in TCP Client/Server mode. TCP connection established, LINK on; TCP connection disconnect normally, LINK off immediately; TCP connection disconnect abnormally, Link off with about 40 seconds delay.Enable Link function in UDP mode, LINK on.
TX| On: Sending data to serial
Off: No data sending to serial
RX| On: Receiving data from serial
Off: No data receiving from serial

Product Functions

This chapter introduces the functions of USR-SERIAL DEVICE SERVER as the following diagram shown, you can get an overall knowledge of it

Figure 7 Product Functions diagram
Product Functions

Basic Functions

Static IP/DHCP

There are two ways for module to getIP address: Static IP andDHCP.
Static IP: Default setting of module is Static IP and defaultIP is 192.168.0.7. When user set 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 connect directly to PC, module can’t be set in DHCP mode. Because common computer does not have the ability to assign IP addresses. User can change Static IP/DHCP by setup software. Setting diagram as follow:

Figure 8 Static IP/DHCP
Static IP/DHCP

Restore default settings

Hardware: User can press Reload over 5 seconds and less than 15 seconds then release to restore default settings.
Software: User can use setup software to restore default settings.
AT command: User can enter AT command mode and use AT+RELD to restore default settings.

Upgrade Firmware Version

User can contactto salespersons for needed firmware version and upgrade by setup software as follow:

Figure 9 Upgrade firmware version
Upgrade Firmware Version

Socketfunctions

SERIAL DEVICE SERVER socket support TCP Server, TCP Client, UDP Server, UDP Client andHTTPDClient.

TCP 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 and server. According to the TCP protocol, TCP Client has connection/disconnection status differences to ensure reliable data transmission.
TCP Client mode support Keep-Alive function: After connection is established, module will send Keep-Alive packets about every 15 seconds to check the connection and will disconnect then reconnect to TCP server if abnormal connection is been checked by Keep-Alive packets. TCP Client mode also support non-persistent function. SERIAL DEVICE SERVER work in TCP Client mode need connect to TCP Server and need set the parameters:
Remote Server Addr and Remote Port Number. SERIAL DEVICE SERVER work in TCP Client won’t accept other connection request except target server and will access server with random local port if user set local port to zero.
User can set SERIAL DEVICE SERVER in TCP Client mode and related parameters by setup software or web server as follows:
Figure 10 TCP Client
TCP Client
TCP Client

TCP Server

TCP Server will listen network connections and build network connections, commonly 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.
TCP Server mode also support Keep-Alive function.
SERIAL DEVICE SERVER work 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 SERIAL DEVICE SERVER in TCP Server mode simultaneously.
SERIAL DEVICE SERVER work in TCP Server support 16 client connections at most and will kick off oldest connection beyond maximum connections(User can enable/disable this function by web server).
User can set SERIAL DEVICE SERVER in TCP Server mode and related parameters by setup software or web server as follows:
Figure 11 TCP Server
TCP Server
TCP Server
UDP Client

UDP transport protocol provides simple and unreliable communication services. No connection connected /disconnected.
In UDP Client mode, SERIAL DEVICE SERVER will only communicate with target IP/Port. If data not from target IP/Port, it won’t be received by SERIAL DEVICE SERVER.
In UDP Client mode, if user set remote IP as 255.255.255.255, SERIAL DEVICE SERVER can broadcast to entire network segment and receive broadcast data. After firmware version 4015, 306 support broadcasting in same network segment.(Such like xxx.xxx.xxx.255 broadcasting way).
User can set SERIAL DEVICE SERVER in UDP Client mode and related parameters by setup software or web server as follows:
Figure 12 UDP Client
UDP Client
UDP Client

UDP Server In UDP Server mode, SERIAL DEVICE SERVER will change target IP every time after receiving UDP data from a new IP/Port and will send data to latest communication IP/Port.
User can set SERIAL DEVICE SERVER inUDP Server mode and related parameters by setup software orweb
server as follows:

Figure 13 UDP Server

UDP Server
UDP Server

HTTPD Client

In HTTPD Client mode, SERIAL DEVICE SERVER can achieve data transmission between serial port device and HTTP server. User just need set SERIAL DEVICE SERVER in HTTPD Client and set the HTTPD 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.
User can set SERIAL DEVICE SERVER inHTTPDClient mode and related parameters by web server as follow:
Figure 14 HTTPD Client
HTTPD Client

Serial port

SERIAL DEVICE SERVER support RS232/RS485/RS422. User can refer to 1.2.2. DB9 Pin definition 1.2.3.
RS422/RS485 Pin definition to connect and RS232/RS485/RS422 can’t be used simultaneously.

Serial port basic parameters

Figure 15 Serial port parameters

Parameters Default Range
Baud rate 115200 600~230.4Kbps
Data bits 8 5~8
Stop bits 1 1~2
Parity None None, Odd, Even, Mark, Space

Serial Package Methods

For network speed is faster than serial. Module will put serial data in buffer before sending it to network. The data will be sent to Network as Package. There are 2 ways to end the package and send package to network – Time Trigger Mode and Length Trigger Mode.
SERIAL DEVICE SERVER adopt fixed Package time (four bytes sending time) and fixed Package length (400 bytes).

Baud Rate Synchronization

When module works with USR devices or software, serial parameter will change dynamically according to network protocol. Customer can modify serial parameter by sending data conformed to specific protocol via network. It is temporary, when restart module, the parameters back to original parameters.
User can adopt Baud Rate Synchronization function by setup software as follows:

Figure 16 Baud Rate Synchronization
Baud Rate Synchronization

Features

Identity Packet Function

Figure 17 Identity Packet application diagram

Features

Identity packetis used for identify the device when module works as TCP client/UDP client. There are two sending methods for identity packet.

  •  Identity data will be sent when connection is established.
  • Identity data will be add on the front of every data packet.
    Identity packet can be MAC address or user editable data (User editable data at most 40 bytes). User can set SERIAL DEVICE SERVER with Identity Packet function by web server as follow:

Figure 18 Identity Packet
Features

Heartbeat Packet Function

Heartbeat packet: Module will output heartbeat data to serial or network periodic. User can configure the heartbeat data and time interval. Serial heartbeat data can be used for polling Modbus data. Network heartbeat data can be used for showing connection status and keep the connection (only take effect in TCP/UDP Client mode). Heartbeat packet allow 40 bytes at most.
User can set SERIAL DEVICE SERVER with Heartbeat Packet function by web server as follow:

Figure 19 Heartbeat Packet
Heartbeat Packet Function

Editable Web server

SERIAL DEVICE SERVER support user modify the web server based on template according to needs, then use related tool to upgrade. If user have this demand can contact to our salespersons for web server source and tool.

Resetfunction

When 306 work in TCP Client mode, 306 will connect to TCP Server. When user open Reset function, 306 will restart after trying connecting to TCP Server 30 times but still can’t connect to.
User can enable/disable the Reset function by setup software as follow:

Figure 20 Reset function
Resetfunction

Index function

Index function: Used in situation when 306 work in TCP Server mode and establish more than one connection to TCP Client. After open Index function, 306 will mark every TCP Client to distinguish them. User can send/receive data to/from different TCP Client according to their unique mark.
User can enable/disable the Index function by setup software as follow:

Figure 21 Index function
Index function

TCP Server setting

306 work in TCP Server mode allow at most 16 TCP Clients connection. Default is 4 TCP Clients and user can change maximum TCP Clients connection by web server. When TCP Clients more than 4, user need make every
connection data less than 200 bytes/s.
If TCP Clients connected to 306 exceed maximum TCP Clients, user can enable/disable kick off old connection function by web server.
User can set above TCP Server settings by web server as follow:

Figure 22 TCP Server setting
TCP Server setting
TCP Server setting

Non-persistent Connection

SERIAL DEVICE SERVER support non-persistent connection function in TCP Client mode. When SERIAL DEVICE SERVER adopt this function, SERIAL DEVICE SERVER will connect to server and send data after receiving data from serial port side and will disconnect to server after sending all the data to server and no data from serial port side or network side over a fixed time. This fixed time can be 2~255s, default is 3s. User can set SERIAL DEVICE SERVER with non- persistent connecti on function by web server as follow:

**Figure 23 Non-persistent Connection

**

Timeout Reset function

Timeout reset function(no data reset): If network side no data transmission beyond a fixed time(User can set this fixed time between 60~65535s, default is 3600s. If user set a time less than 60s, this function will be disable), 306 will reset. User can set the Timeout Reset function by web server as follow:

Figure 24 Timeout Reset function

Parameter Setting

There are three ways to configure USR-SERIAL DEVICE SERVER. They are setup software configuration, web server configuration and AT command configuration.

Setup software Configuration

User can download setup software from https://www.b-tek.com/images/Documents/USR-M0-V2.2.3.286.zip When user want to configure the SERIAL DEVICE SERVER by setup software, user can run setup software, search SERIAL DEVICE SERVER in same LAN and configure the SERIAL DEVICE SERVER as follow:
Figure 25 Setup software
Parameter Setting

After researching SERIAL DEVICE SERVER and clicking SERIAL DEVICE SERVER 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.

Web Server Configuration

User can connect PC to SERIAL DEVICE SERVER through LAN port and enter web server to configure. Web server default parameters as follow:

Figure 26Web server default parameters

Parameter Default settings
Web server IP address 192.168.0.7
User name admin
Password admin

After firstly connecting PC to SERIAL DEVICE SERVER, user can open browser and enter default IP 192.168.0.7 into address bar, then log in user name and password, user will enter into web server. Web server screenshot as    follow:

Figure 27Web Server
Parameter Setting

Parameter Setting

This document provides the information of USR-SERIAL DEVICE SERVER 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 merchantability 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.

Update History

2022-10-10 V1.0 Established

Logo

References

Read User Manual Online (PDF format)

Read User Manual Online (PDF format)  >>

Download This Manual (PDF format)

Download this manual  >>

Related Manuals