35 from rosbridge_msgs.msg
import ConnectedClient, ConnectedClients
36 from std_msgs.msg
import Int32
43 'client_count', Int32, queue_size=10, latch=
True)
46 'connected_clients', ConnectedClients, queue_size=10, latch=
True)
53 msg = ConnectedClients()
54 msg.clients = list(self._clients.values())
55 self._conn_clients_pub.publish(msg)
56 self._client_count_pub.publish(len(msg.clients))
60 client = ConnectedClient()
61 client.ip_address = ip_address
62 client.connection_time = rospy.Time.now()
68 self._clients.pop(client_id,
None)
def add_client(self, client_id, ip_address)
def remove_client(self, client_id, ip_address)