rs2gprs en
rs2gprs en
JAVA applet for Siemens TC65 / Cinterion TC65T modems and compatible modules
Build 120523 and later
User manual
2012
1 Purpose
rs2gprs Java applet for Siemens TC65 / Cinterion TC65T modems and compatible modules is
intended for making a wireless connection over GPRS to equipment having RS-232/RS-485
serial interface. It can be used e.g. For retrieving data like energy (water, gas)consumption from
remote locations, or equipment remote control (including "smart home" solutions). To use the
applet you will need an active GPRS connection. Equipment being connected must have either
RS-232 serial interface or other interface that can be converted to RS-232 (e.g.RS-485 and RS-
485/RS-232 converter), 8 bits in byte, no parity, 1, 1.5 or 2 stop bits (parameters are limited by
modem capabilities).
Applet allows using Modbus/RTU protocol that restricts time interval between neighbour bytes.
GPRS connection does not guarantee this parameter so the applet fills internal buffer with data
arriving over GPRS and sends incoming packet to device after adjustable period of silence (this
option can be set up or turned off using menu).
6 Setup
6.1 Server setup
There are several possible types of server setup. One type is used when user application can
connect to remote devices over TCP/IP. In this case you do not need to create or use virtual
COM ports in setup. Usually the program can connect to one or several devices by their IP
address and port number, in this case rs2gprs applets are set up as servers and accept
connections from user software. A less common example is when user application processes
incoming connections from one or multiple modems (in this case, each modem must be set up as
a client and must connect to a different port number).
Since rs2gprs is transparent for data flow between COM port of modem and TCP port of user
application, it can be compatible with 3rd party servers or clients. For example, the applet worked
with software by Moxa.
In the case when user application cannot work with TCP/IP it must work with serial port to be
used together with rs2gprs. Physical or virtual COM port setup will be required in this case.
The easiest one is setup of serial connection with a physical PC serial port as an endpoint. More
complicated but more useful is virtual COM port as an endpoint. Both types of setup are
described below.
In both cases one PC can provide several connection channels to different modems at the same
time. These channels must have different port numbers for rs2gprs instances connection.
To set up your server you will need to download and install appropriate software from
http://com0com.sourceforge.net/ .
Please do not forget to set up rs2gprs client before doing actual connection!
6.1.1 Comm channel with physical serial port as an endpoint
When this type of setup is running, PC's physical serial port will be visible for connected
equipment as a physical serial port of remote device (excluding RTS and DTR signals) that is
actually connected to a TC65 modem, as shown on figure below.
Run com2tcp.exe program with required parameters on your server PC. E.g. running
com2tcp.exe --baud 115200 --ignore-dsr \\.\COM1 1234
Will create a transparent data communication channel between serial port СОМ1 with baud rate
115200 bps and ТСР port 1234. The --ignore-dsr option allows ignoring flow control lines,
which might be useful when using 3-wire serial cable or when working with some types of
terminating equipment.
To test the setup connect your modem to port COM1 with a modem(straight) cable and run the
following from command prompt:
com2tcp.exe --baud 115200 --ignore-dsr --telnet \\.\COM1 1234
(--telnet option provides correct telnet software operation)
From another command prompt window run
telnet localhost 1234
(connect to TCP port 1234 of your PC):
To set up a data channel with a virtual COM port you will need to install com0com software.
During default setup new virtual serial ports will appear among devices present on your PC
(visible in Device Manager):
Typing letters in one window will show them in another, and vice versa.
For normal operation run
com2tcp.exe --baud 115200 --ignore-dsr \\.\CNCA0 1234
or something similar depending on your equipment settings and user software capabilities.