skip to navigation
skip to content

Not Logged In

serial2tcp 0.5

Convert serial device to tcp socket.

Latest Version: 0.5.1

Instalation

You can install from pip:

# pip install serial2tcp

or manual:

git clone git://github.com/mosquito/serial2tcp.git cd serial2tcp python setup.py install

Redirect USB-Serial

For redirect /dev/ttyUSB0 with baudrate 9600 bps and 192.168.2.1 can connect to that:

# serial2tcp -p /dev/ttyUSB0 -b 9600 -l 0.0.0.0 –allow-list=‘192.168.2.1’

Help

Usage: serial2tcp [options]

Simple Serial to Network (TCP/IP) redirector.

WARNING: You have to allow connections only from the addresses in the “–allow-list” option. e.g. –allow-list=‘10.0.0.1, 172.16.0.1, 192.168.0.1’ NOTICE: This service supports only one tcp connection per instance.

Options:
<kbd>--version</kbd> show program’s version number and exit
<kbd>-h, --help</kbd> show this help message and exit
<kbd>-p <var>SERIAL</var>, --port=<var>SERIAL</var></kbd>
 Serial port, a number, defualt = ‘/dev/tty0’
<kbd>-b <var>BAUDRATE</var>, --baud=<var>BAUDRATE</var></kbd>
 Baudrate, default 115200
<kbd>-r, --rtscts</kbd> Enable RTS/CTS flow control (default off)
<kbd>-x, --xonxoff</kbd> Enable software flow control (default off)
<kbd>-P <var>PORT</var>, --localport=<var>PORT</var></kbd>
 TCP/IP port on which to run the server (default 9100)
<kbd>-l <var>LISTEN</var>, --listen=<var>LISTEN</var></kbd>
 Listen address on which to run the server (default ‘127.0.0.1’)
<kbd>--access-list=<var>ACL</var></kbd>
 List of IP addresses e.g ‘127.0.0.1, 192.168.0.2’

Based on: http://www.cs.earlham.edu/~charliep/ecoi/serial/pyserial-2.2/examples/tcp_serial_redirect.py

 
File Type Py Version Uploaded on Size
serial2tcp-0.5.tar.gz (md5) Source 2014-03-28 3KB
  • Downloads (All Versions):
  • 3 downloads in the last day
  • 32 downloads in the last week
  • 117 downloads in the last month