Package rospy :: Package impl :: Module tcpros_base :: Class TCPROSServer

Class TCPROSServer

source code

object --+
         |
        TCPROSServer

ROS Protocol handler for TCPROS. Accepts both TCPROS topic connections as well as ROS service connections over TCP. TCP server socket is run once start_server() is called -- this is implicitly called during init_publisher().

Instance Methods
 
__init__(self)
ctor.
source code
 
start_server(self, port=0)
Starts the TCP socket server if one is not already running
source code
str, int
get_address(self)
Returns: address and port of TCP server socket for accepting inbound connections
source code
 
shutdown(self, reason='')
stops the TCP/IP server responsible for receiving inbound connections
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Instance Variables
  tcp_ros_server
server for receiving tcp conn
Properties

Inherited from object: __class__

Method Details

__init__(self)
(Constructor)

source code 

ctor.

Overrides: object.__init__

start_server(self, port=0)

source code 

Starts the TCP socket server if one is not already running

Parameters:
  • port (int) - port number to bind to (default 0/any)

get_address(self)

source code 
Returns: str, int
address and port of TCP server socket for accepting inbound connections