determine topic established port number for transport control
Hello,
I would like to use transport control, tc, to prioritize data on certain topic connections. How do I determine the port number for the topic connection between two nodes on different computers? rostopic info and rosnode info do not appear to give me this information.
For example, this test shows connections between two nodes, ladybug_server and ladybug_viewer. The viewer is located on the "terminal" computer and the server is located on "robot" computer. The terminal and server computers are connected via wifi. In the below example the terminal is 10.42.43.237.
the topics:
username@terminal:~/tc_test$ rostopic list
/joy_tablet
/ladybug_server/config
/ladybug_server/frame_ack
/ladybug_server/info
/ladybug_server/realtime_video
/ladybug_server/rsync_done
/ladybug_server/snapshot_request
/ladybug_server/snapshot_taken
/map_pose_updater/pose_announce
/rosout
/rosout_agg
for example, trying to find the realtime video port
username@robot:~$ rostopic info /ladybug_server/realtime_video
Type: ladybug/ladybugRealtimeVideo
Publishers:
* /ladybug_server (http://robot:59560/)
Subscribers:
* /ladybug_viewer (http://10.42.43.237:49643/)
Now trying to determine the established connections:
username@terminal:~/tc_test$ sudo netstat -anp | grep ladybug
tcp 0 0 0.0.0.0:35060 0.0.0.0:* LISTEN 14359/ladybug_viewe
tcp 0 0 0.0.0.0:49643 0.0.0.0:* LISTEN 14359/ladybug_viewe
tcp 0 0 10.42.43.237:35060 10.42.43.1:50960 ESTABLISHED 14359/ladybug_viewe
tcp 0 0 10.42.43.237:35060 10.42.43.1:50957 ESTABLISHED 14359/ladybug_viewe
tcp 0 0 10.42.43.237:40618 10.42.43.1:49016 ESTABLISHED 14359/ladybug_viewe
tcp 0 0 10.42.43.237:35060 10.42.43.1:50959 ESTABLISHED 14359/ladybug_viewe
tcp 0 0 10.42.43.237:37043 10.42.43.1:11311 CLOSE_WAIT 14359/ladybug_viewe
tcp 0 0 10.42.43.237:35060 10.42.43.1:50961 ESTABLISHED 14359/ladybug_viewe
udp 0 0 0.0.0.0:49045 0.0.0.0:* 14359/ladybug_viewe
unix 3 [ ] STREAM CONNECTED 102562 14359/ladybug_viewe
username@robot:~$ sudo netstat -anp | grep ladybug_ser
tcp 0 0 0.0.0.0:49016 0.0.0.0:* LISTEN 12220/ladybug_serve
tcp 0 0 0.0.0.0:59560 0.0.0.0:* LISTEN 12220/ladybug_serve
tcp 0 0 10.42.43.1:50959 10.42.43.237:35060 ESTABLISHED 12220/ladybug_serve
tcp 0 0 127.0.0.1:49016 127.0.0.1:38779 ESTABLISHED 12220/ladybug_serve
tcp 0 0 10.42.43.1:50960 10.42.43.237:35060 ESTABLISHED 12220/ladybug_serve
tcp 0 0 10.42.43.1:49016 10.42.43.237:40618 ESTABLISHED 12220/ladybug_serve
tcp 1 0 10.42.43.1:53324 10.42.43.1:11311 CLOSE_WAIT 12220/ladybug_serve
tcp 0 0 10.42.43.1:50961 10.42.43.237:35060 ESTABLISHED 12220/ladybug_serve
udp 0 0 0.0.0.0:40540 0.0.0.0:* 12220/ladybug_serve
The question is, which one of these ports is the connected realtime_video topic between the server and terminal? By monitoring the netstat output queued data for a while I can "guess" that the realtime video port is 49016/40618 because ...
may I know how you are getting the images from the ladybug in the first place? I have a ladybug3 that I'd like to setup.